9d7ad023de1fe5c42d386f3793fb87b80732d607
angie
  Tue Feb 8 11:48:18 2011 -0800
Feature #27 (table browser support for BAM): addition of BAM supportwithout enough #ifdef USE_BAM's led to compile errors without USE_BAM=1.
Fix: add stub routines to bamFile.c so that the compile won't break,
but informative error message will be printed if bamFile routines are
called.  I was hoping that this would obviate most of the #ifdef USE_BAM's
currently in the tree, but actually most of those prevent CGIs from
getting into trouble by offering BAM functionality when it isn't
compiled in.  So I left most current #ifdef USE_BAM's in place, but
when future new code doesn't #ifdef, at least the compile won't break.

diff --git src/hg/hgc/bamClick.c src/hg/hgc/bamClick.c
index 24cdd72..ef82b8e 100644
--- src/hg/hgc/bamClick.c
+++ src/hg/hgc/bamClick.c
@@ -1,28 +1,28 @@
 /* bamClick - handler for alignments in BAM format (produced by MAQ,
  * BWA and some other short-read alignment tools). */
 #ifdef USE_BAM
 
 #include "common.h"
 #include "hash.h"
 #include "hdb.h"
 #include "bamFile.h"
 #include "hgc.h"
-#ifdef KNETFILE_HOOKS
+#if (defined USE_BAM && defined KNETFILE_HOOKS)
 #include "knetUdc.h"
 #include "udc.h"
-#endif//def KNETFILE_HOOKS
+#endif//def USE_BAM && KNETFILE_HOOKS
 
 static char const rcsid[] = "$Id: bamClick.c,v 1.21 2010/05/11 01:43:28 kent Exp $";
 
 #include "bamFile.h"
 
 struct bamTrackData
     {
     int itemStart;
     char *itemName;
     struct hash *pairHash;
     };
 
 /* Maybe make this an option someday -- for now, I find it too confusing to deal with
  * CIGAR that is anchored to positive strand while showing rc'd sequence.  I think
  * to do it right, we would need to reverse the CIGAR string for display. */