ViewVC Help
View File | Revision Log | Show Annotations | View Changeset | Root Listing
root/gclib/cuffcompare/Makefile
Revision: 20
Committed: Mon Jul 18 21:08:36 2011 UTC (8 years, 3 months ago) by gpertea
File size: 1842 byte(s)
Log Message:
added cuffcompare sources

Line File contents
1 # Useful directories
2
3 THISCODEDIR := .
4 GCLDIR := ../gclib
5 # Directory where libz.a can be found
6 # (please build that first before making this package)
7 # ZDIR := ../zlib
8 # Directories to search for header files
9 #SEARCHDIRS := -I${ZDIR} -I${THISCODEDIR} -I${GCLDIR}
10 SEARCHDIRS := -I${THISCODEDIR} -I${GCLDIR}
11
12 SYSTYPE := $(shell uname)
13
14 # C compiler
15
16 MACHTYPE := $(shell uname -m)
17 ifeq ($(MACHTYPE), i686)
18 MARCH = -march=i686
19 else
20 MARCH =
21 endif
22
23 # CVS checked in
24 CC := g++
25 BASEFLAGS = -Wall -Wextra ${SEARCHDIRS} $(MARCH) -D_FILE_OFFSET_BITS=64 \
26 -D_LARGEFILE_SOURCE -fno-exceptions -fno-rtti \
27 -D_REENTRANT
28
29
30 ifeq ($(findstring debug,$(MAKECMDGOALS)),)
31 CFLAGS = -O2 -DNDEBUG $(BASEFLAGS)
32 LDFLAGS =
33 else
34 CFLAGS = -g -DDEBUG $(BASEFLAGS)
35 LDFLAGS = -g
36 endif
37
38 %.o : %.c
39 ${CC} ${CFLAGS} -c $< -o $@
40
41 %.o : %.cc
42 ${CC} ${CFLAGS} -c $< -o $@
43
44 %.o : %.C
45 ${CC} ${CFLAGS} -c $< -o $@
46
47 %.o : %.cpp
48 ${CC} ${CFLAGS} -c $< -o $@
49
50 %.o : %.cxx
51 ${CC} ${CFLAGS} -c $< -o $@
52
53 # C/C++ linker
54
55 LINKER := g++
56 LIBS =
57
58 OBJS = ${GCLDIR}/GFastaIndex.o ${GCLDIR}/GFaSeqGet.o ${GCLDIR}/gff.o \
59 ./gtf_tracking.o ${GCLDIR}/gdna.o ${GCLDIR}/codons.o ${GCLDIR}/GBase.o \
60 ${GCLDIR}/GStr.o ${GCLDIR}/GArgs.o
61
62 .PHONY : all
63 all: cuffcompare test_load
64 #all: test_load
65 debug: cuffcompare test_load
66 ${GCLDIR}/gff.o : ${GCLDIR}/gff.h
67 ./gtf_tracking.o : ./gtf_tracking.h
68 ./cuffcompare.o : ./gtf_tracking.h
69 cuffcompare: ${OBJS} ./cuffcompare.o
70 ${LINKER} ${LDFLAGS} -o $@ ${filter-out %.a %.so, $^} ${LIBS}
71 test_load: ${OBJS} ./test_load.o
72 ${LINKER} ${LDFLAGS} -o $@ ${filter-out %.a %.so, $^} ${LIBS}
73
74 testfai: ${OBJS} ./testfai.o
75 ${LINKER} ${LDFLAGS} -o $@ ${filter-out %.a %.so, $^} ${LIBS}
76 # target for removing all object files
77
78 .PHONY : clean
79 clean::
80 @${RM} core core.* testfai cuffcompare cuffcompare.exe ${OBJS} *.o*