From: On behalf of John Marshall Date: Mon, 30 Nov 2009 15:53:02 +0000 (+0000) Subject: Put libraries at the end, so they can resolve references from libbam.a X-Git-Url: https://git.donarmstrong.com/?p=samtools.git;a=commitdiff_plain;h=4234ca876913410a3db043171d2fecb6f871bae2 Put libraries at the end, so they can resolve references from libbam.a as well, even with old-fashioned linkers. Also use libbam.a explicitly rather than "-L. -lbam" to ensure that we get the freshly built library, not some other libbam.a lying around the system. --- diff --git a/Makefile b/Makefile index afd3b16..2a7ab71 100644 --- a/Makefile +++ b/Makefile @@ -36,7 +36,7 @@ libbam.a:$(LOBJS) $(AR) -cru $@ $(LOBJS) samtools:lib $(AOBJS) - $(CC) $(CFLAGS) -o $@ $(AOBJS) -lm $(LIBPATH) $(LIBCURSES) -lz -L. -lbam + $(CC) $(CFLAGS) -o $@ $(AOBJS) libbam.a -lm $(LIBPATH) $(LIBCURSES) -lz razip:razip.o razf.o knetfile.o $(CC) $(CFLAGS) -o $@ razf.o razip.o knetfile.o -lz