forked from grenaud/schmutzi
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathMakefile
182 lines (115 loc) · 6.58 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
CXX = /usr/bin/g++ #-g -pg
BAMTOOLS= bamtools/
LIBGAB = libgab/
CXXFLAGS = -lm -O3 -Wall -I${LIBGAB} -I${LIBGAB}/gzstream/ -I${BAMTOOLS}/include/ -I${BAMTOOLS}/src/ -c
LDLIBS += ${BAMTOOLS}/build/src/utils/CMakeFiles/BamTools-utils.dir/*cpp.o ${BAMTOOLS}/build/src/api/libbamtools.a -lpthread -lm -lz
all: endoCaller mtCont damage2profile log2freq log2fasta contDeam msa2freq bam2prof insertSize splitEndoVsCont/poshap2splitbam logs2pos countRecords libgab/utils.o bamtools/build/src/api/libbamtools.a jointFreqDeaminated jointFreqDeaminatedDouble msa2log log2ConsensusLog logdiff logmask filterlog msa2singlefreq subSampleBAM addXACircular
splitEndoVsCont/poshap2splitbam:
make -C splitEndoVsCont/
libgab/utils.h:
rm -rf libgab/
git clone --recursive https://github.com/grenaud/libgab.git
libgab/utils.o: bamtools/build/src/api/libbamtools.a libgab/utils.h
make -C libgab
bamtools/src/api/BamAlignment.h:
rm -rf bamtools/
git clone --recursive https://github.com/pezmaster31/bamtools.git
bamtools/build/src/api/libbamtools.a: bamtools/src/api/BamAlignment.h
cd bamtools/ && mkdir -p build/ && cd build/ && cmake .. && make && cd ../..
miscfunc.o: libgab/utils.o miscfunc.cpp
${CXX} ${CXXFLAGS} miscfunc.cpp
insertSize.o: libgab/utils.o insertSize.cpp
${CXX} ${CXXFLAGS} insertSize.cpp
insertSize: insertSize.o ${LIBGAB}utils.o
${CXX} -o $@ $^ $(LDLIBS)
countRecords.o: libgab/utils.o countRecords.cpp
${CXX} ${CXXFLAGS} countRecords.cpp
countRecords: countRecords.o ${LIBGAB}utils.o
${CXX} -o $@ $^ $(LDLIBS)
jointFreqDeaminated.o: libgab/utils.o jointFreqDeaminated.cpp
${CXX} ${CXXFLAGS} jointFreqDeaminated.cpp
jointFreqDeaminatedDouble.o: libgab/utils.o jointFreqDeaminatedDouble.cpp
${CXX} ${CXXFLAGS} jointFreqDeaminatedDouble.cpp
jointFreqDeaminated: jointFreqDeaminated.o ${LIBGAB}utils.o ${LIBGAB}/ReconsReferenceBAM.o
${CXX} -o $@ $^ $(LDLIBS)
jointFreqDeaminatedDouble: jointFreqDeaminatedDouble.o ${LIBGAB}utils.o ${LIBGAB}/ReconsReferenceBAM.o
${CXX} -o $@ $^ $(LDLIBS)
mtCont.o: libgab/utils.o mtCont.cpp
${CXX} ${CXXFLAGS} mtCont.cpp
mtCont: libgab/utils.o miscfunc.o mtCont.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
bam2prof.o: libgab/utils.o bam2prof.cpp
${CXX} ${CXXFLAGS} bam2prof.cpp
bam2prof: libgab/utils.o miscfunc.o bam2prof.o ${LIBGAB}utils.o ${LIBGAB}/ReconsReferenceBAM.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
subSampleBAM.o: libgab/utils.o subSampleBAM.cpp
${CXX} ${CXXFLAGS} subSampleBAM.cpp
subSampleBAM: libgab/utils.o subSampleBAM.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
addXACircular.o: libgab/utils.o addXACircular.cpp
${CXX} ${CXXFLAGS} addXACircular.cpp
addXACircular: libgab/utils.o addXACircular.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
contDeam.o: libgab/utils.o contDeam.cpp
${CXX} ${CXXFLAGS} contDeam.cpp
contDeam: libgab/utils.o ${LIBGAB}/ReconsReferenceBAM.o miscfunc.o contDeam.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
endoCaller.o: libgab/utils.o endoCaller.cpp
${CXX} ${CXXFLAGS} endoCaller.cpp
endoCaller: libgab/utils.o ${LIBGAB}/ReconsReferenceBAM.o endoCaller.o miscfunc.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} $(LDFLAGS) -o $@ $^ $(LDLIBS)
log2freq.o: libgab/utils.o log2freq.cpp
${CXX} ${CXXFLAGS} log2freq.cpp
log2freq: libgab/utils.o log2freq.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
log2fasta.o: libgab/utils.o log2fasta.cpp
${CXX} ${CXXFLAGS} log2fasta.cpp
log2fasta: libgab/utils.o log2fasta.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
filterlog.o: libgab/utils.o filterlog.cpp
${CXX} ${CXXFLAGS} filterlog.cpp
filterlog: libgab/utils.o filterlog.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
logs2pos.o: libgab/utils.o logs2pos.cpp
${CXX} ${CXXFLAGS} logs2pos.cpp
logs2pos: libgab/utils.o logs2pos.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
log2ConsensusLog.o: libgab/utils.o log2ConsensusLog.cpp
${CXX} ${CXXFLAGS} log2ConsensusLog.cpp
log2ConsensusLog: libgab/utils.o log2ConsensusLog.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
logdiff.o: libgab/utils.o logdiff.cpp
${CXX} ${CXXFLAGS} logdiff.cpp
logdiff: libgab/utils.o logdiff.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
logmask.o: libgab/utils.o logmask.cpp
${CXX} ${CXXFLAGS} logmask.cpp
logmask: libgab/utils.o logmask.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
msa2freq.o: libgab/utils.o msa2freq.cpp
${CXX} ${CXXFLAGS} msa2freq.cpp
msa2freq: libgab/utils.o msa2freq.o ${LIBGAB}utils.o libgab/FastQParser.o libgab/FastQObj.o libgab/gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
msa2singlefreq.o: libgab/utils.o msa2singlefreq.cpp
${CXX} ${CXXFLAGS} msa2singlefreq.cpp
msa2singlefreq: libgab/utils.o msa2singlefreq.o ${LIBGAB}utils.o libgab/FastQParser.o libgab/FastQObj.o libgab/gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
msa2log.o: libgab/utils.o msa2log.cpp
${CXX} ${CXXFLAGS} msa2log.cpp
msa2log: libgab/utils.o msa2log.o ${LIBGAB}utils.o libgab/FastQParser.o libgab/FastQObj.o libgab/gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
damage2profile.o: libgab/utils.o damage2profile.cpp
${CXX} ${CXXFLAGS} damage2profile.cpp
damage2profile: libgab/utils.o damage2profile.o ${LIBGAB}utils.o ${LIBGAB}gzstream/libgzstream.a
${CXX} -o $@ $^ $(LDLIBS) $(LDFLAGS)
testdata: testdata/mezB9687.bam testdata/simulation.bam
testdata/mezB9687.bam:
wget -O testdata/mezB9687.bam https://bioinf.eva.mpg.de/schmutzi/testData/mezB9687.bam
wget -O testdata/mezB9687.bam.bai https://bioinf.eva.mpg.de/schmutzi/testData/mezB9687.bam.bai
testdata/simulation.bam:
wget -O testdata/simulation.bam https://bioinf.eva.mpg.de/schmutzi/testData/simulation.bam
wget -O testdata/simulation.bam.bai https://bioinf.eva.mpg.de/schmutzi/testData/simulation.bam.bai
clean :
rm -f *.o endoCaller mtCont damage2profile log2freq log2fasta contDeam msa2freq msa2log bam2prof subSampleBAM addXACircular insertSize splitEndoVsCont/poshap2splitbam logs2pos countRecords libgab/utils.o bamtools/lib/libbamtools.a jointFreqDeaminated jointFreqDeaminatedDouble log2ConsensusLog logdiff logmask filterlog msa2singlefreq
make -C splitEndoVsCont/ clean
make -C libgab/ clean