forked from admb-project/admb
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
362 lines (349 loc) · 10.6 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
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
#default targets depending on compiler
#DEBUG=yes
dist:
$(MAKE) $(CXX)-dist DEBUG=$(DEBUG)
@echo ADMB build dist completed.
@echo Check README.txt for usage and installation information.
all:
$(MAKE) $(CXX)-all DEBUG=$(DEBUG)
@echo ADMB build all completed.
@echo Check README.txt for usage and installation information.
core:
$(MAKE) $(CXX)-core DEBUG=$(DEBUG)
@echo ADMB build core completed.
debug:
$(MAKE) $(CXX)-all DEBUG=yes
@echo ADMB build debug completed.
contribs:
$(MAKE) $(CXX)-contribs DEBUG=$(DEBUG)
@echo ADMB build contribs completed.
test: verify
gtests:
$(MAKE) $(CXX)-gtests DEBUG=$(DEBUG)
verify:
$(MAKE) $(CXX)-verify DEBUG=$(DEBUG)
doc: $(CXX)-docs
shared: $(CXX)-shared
$(MAKE) $(CXX)-shared DEBUG=$(DEBUG)
@echo ADMB build shared completed.
install: $(CXX)-install
check: $(CXX)-check
@echo "SHELL: $(SHELL)"
@echo "PATH: $(PATH)"
@echo "TERM: $(TERM)"
@echo "MAKE: $(MAKE)"
@echo "CXX: $(CXX)"
clean: $(CXX)-clean
coverage:
$(MAKE) $(CXX)-coverage DEBUG=$(DEBUG)
help:
@echo Read INSTALL.txt for installation help.
installer: zip
zip: $(CXX)-zip
#Microsoft Visual C++
cl: cl-all
cl-all:
nmake /nologo cl-dist
nmake /nologo cl-shared
pushd src& nmake /nologo copy
cl-dist:
nmake /nologo cl-contribs
cl-debug:
pushd src& nmake /nologo DEBUG=!DEBUG! all
pushd contrib& nmake /nologo DEBUG=yes all
cl-core:
pushd src& nmake /nologo all
cl-contribs: cl-core
pushd contrib& nmake /nologo all
cl-docs:
pushd docs& nmake /nologo all
cl-gtests:
pushd tests & nmake /nologo test-gtests
cl-verify:
pushd tests& nmake /nologo verify
cl-shared:
pushd src& nmake /nologo shared
pushd contrib& nmake /nologo shared
cl-install:
pushd src& nmake /nologo install
cl-check:
pushd src& nmake /nologo check
cl-clean:
pushd src& nmake /nologo clean
pushd contrib& nmake /nologo clean
pushd scripts& nmake /nologo clean
pushd tests& nmake /nologo clean
pushd examples& nmake /nologo clean
cl-zip:
pushd src& nmake /nologo zip
#GNU
g++: g++-all
g++-all:
$(MAKE) g++-dist
$(MAKE) g++-shared
$(MAKE) --directory=src CC=gcc CXX=g++ copy
g++-dist:
$(MAKE) g++-core
$(MAKE) g++-contribs
g++-debug:
$(MAKE) g++-all DEBUG=yes
g++-core:
$(MAKE) --directory=src CC=gcc CXX=g++ all
g++-contribs: g++-core
$(MAKE) --directory=contrib CC=gcc CXX=g++ all
g++-docs:
$(MAKE) --directory=docs CC=gcc CXX=g++ all
g++-gtests:
$(MAKE) --directory=tests CC=gcc CXX=g++ unit-gtests
g++-coverage:
$(MAKE) --directory=src CC=gcc CXX=g++ SAFE_ONLY=yes dist
$(MAKE) --directory=tests CC=gcc CXX=g++ coverage
g++-verify:
$(MAKE) --directory=tests CC=gcc CXX=g++ verify
g++-shared:
$(MAKE) --directory=src CC=gcc CXX=g++ SHARED=-shared shared
$(MAKE) --directory=contrib CC=gcc CXX=g++ SHARED=-shared shared
g++-install:
$(MAKE) --directory=src CC=gcc CXX=g++ install
g++-check:
$(MAKE) --directory=src CC=gcc CXX=g++ check
g++-clean:
$(MAKE) --directory=src CC=gcc CXX=g++ clean
$(MAKE) --directory=contrib CC=gcc CXX=g++ clean
$(MAKE) --directory=scripts CC=gcc CXX=g++ clean
$(MAKE) --directory=tests CC=gcc CXX=g++ clean
$(MAKE) --directory=examples CC=gcc CXX=g++ clean
g++-zip:
$(MAKE) --directory=src CC=gcc CXX=g++ zip
#clang
clang++: clang++-all
clang++-all:
$(MAKE) clang++-dist
$(MAKE) clang++-shared
$(MAKE) --directory=src CC=clang CXX=clang++ copy
clang++-dist:
$(MAKE) clang++-contribs
clang++-debug:
$(MAKE) clang++-all DEBUG=yes
clang++-core:
$(MAKE) --directory=src CC=clang CXX=clang++ all
clang++-contribs: clang++-core
$(MAKE) --directory=contrib CC=clang CXX=clang++ all
clang++-docs:
$(MAKE) --directory=docs CC=clang CXX=clang++ all
clang++-gtests:
$(MAKE) --directory=tests CC=clang CXX=clang++ unit-gtests
clang++-coverage:
$(MAKE) --directory=src CC=clang CXX=clang++ SAFE_ONLY=yes dist
$(MAKE) --directory=tests CC=clang CXX=clang++ coverage
clang++-verify:
$(MAKE) --directory=tests CC=clang CXX=clang++ verify
clang++-shared:
$(MAKE) --directory=src CC=clang CXX=clang++ SHARED=-shared shared
$(MAKE) --directory=contrib CC=clang CXX=clang++ SHARED=-shared shared
clang++-install:
$(MAKE) --directory=src CC=clang CXX=clang++ install
clang++-check:
$(MAKE) --directory=src CC=clang CXX=clang++ check
clang++-clean:
$(MAKE) --directory=src CC=clang CXX=clang++ clean
$(MAKE) --directory=contrib CC=clang CXX=clang++ clean
$(MAKE) --directory=scripts CC=clang CXX=clang++ clean
$(MAKE) --directory=tests CC=clang CXX=clang++ clean
$(MAKE) --directory=examples CC=clang CXX=clang++ clean
clang++-zip:
$(MAKE) --directory=src CC=clang CXX=clang++ zip
#default c++
c++: c++-all
c++-all:
$(MAKE) c++-dist
$(MAKE) c++-shared
$(MAKE) --directory=src CC=cc CXX=c++ copy
c++-dist:
$(MAKE) c++-contribs
c++-debug:
$(MAKE) c++-all DEBUG=yes
c++-core:
$(MAKE) --directory=src CC=cc CXX=c++ all
c++-contribs: c++-core
$(MAKE) --directory=contrib CC=cc CXX=c++ all
c++-docs:
$(MAKE) --directory=docs CC=cc CXX=c++ all
c++-coverage:
$(MAKE) --directory=src CC=cc CXX=c++ SAFE_ONLY=yes dist
$(MAKE) --directory=tests CC=cc CXX=c++ coverage
c++-gtests:
$(MAKE) --directory=tests CC=cc CXX=c++ unit-gtests
c++-verify:
$(MAKE) --directory=tests CC=cc CXX=c++ verify
c++-shared:
$(MAKE) --directory=src CC=cc CXX=c++ SHARED=-shared shared
$(MAKE) --directory=contrib CC=cc CXX=c++ SHARED=-shared shared
c++-install:
$(MAKE) --directory=src CC=cc CXX=c++ install
c++-check:
$(MAKE) --directory=src CC=cc CXX=c++ check
c++-clean:
$(MAKE) --directory=src CC=cc CXX=c++ clean
$(MAKE) --directory=contrib CC=cc CXX=c++ clean
$(MAKE) --directory=scripts CC=cc CXX=c++ clean
$(MAKE) --directory=tests CC=cc CXX=c++ clean
$(MAKE) --directory=examples CC=cc CXX=c++ clean
c++-zip:
$(MAKE) --directory=src CC=cc CXX=c++ zip
#Oracle Solaris Studio
CC: CC-all
CC-all:
$(MAKE) CC-dist
$(MAKE) CC-shared
$(MAKE) --directory=src CC=cc CXX=CC copy
CC-dist:
$(MAKE) CC-contribs
CC-debug:
$(MAKE) CC-all DEBUG=yes
CC-core:
$(MAKE) --directory=src CC=cc CXX=CC all
CC-contribs: CC-core
$(MAKE) --directory=contrib CC=cc CXX=CC all
CC-docs:
$(MAKE) --directory=docs CC=cc CXX=CC all
CC-gtests:
$(MAKE) --directory=tests CC=cc CXX=CC unit-gtests
CC-verify:
$(MAKE) --directory=tests CC=cc CXX=CC verify
CC-shared:
$(MAKE) --directory=src CC=cc CXX=CC SHARED=-shared shared
$(MAKE) --directory=contrib CC=cc CXX=CC SHARED=-shared shared
CC-install:
$(MAKE) --directory=src CC=cc CXX=CC install
CC-check:
$(MAKE) --directory=src CC=cc CXX=CC check
CC-clean:
$(MAKE) --directory=src CC=cc CXX=CC clean
$(MAKE) --directory=contrib CC=cc CXX=CC clean
$(MAKE) --directory=scripts CC=cc CXX=CC clean
$(MAKE) --directory=tests CC=cc CXX=CC clean
$(MAKE) --directory=examples CC=cc CXX=CC clean
CC-zip:
$(MAKE) --directory=src CC=cc CXX=CC zip
#Intel
icpc: icpc-all
icpc-all:
$(MAKE) icpc-dist
$(MAKE) icpc-shared
$(MAKE) --directory=src CC=icc CXX=icpc copy
icpc-dist:
$(MAKE) icpc-contribs
icpc-debug:
$(MAKE) icpc-all DEBUG=yes
icpc-core:
$(MAKE) --directory=src CC=icc CXX=icpc all
icpc-contribs: icpc-core
$(MAKE) --directory=contrib CC=icc CXX=icpc all
icpc-docs:
$(MAKE) --directory=docs CC=icc CXX=icpc all
icpc-gtests:
$(MAKE) --directory=tests CC=icc CXX=icpc unit-gtests
icpc-verify:
$(MAKE) --directory=tests CC=icc CXX=icpc verify
icpc-shared:
$(MAKE) --directory=src CC=icc CXX=icpc SHARED=-shared shared
$(MAKE) --directory=contrib CC=icc CXX=icpc SHARED=-shared shared
icpc-install:
$(MAKE) --directory=src CC=icc CXX=icpc install
icpc-check:
$(MAKE) --directory=src CC=icc CXX=icpc check
icpc-clean:
$(MAKE) --directory=src CC=icc CXX=icpc clean
$(MAKE) --directory=contrib CC=icc CXX=icpc clean
$(MAKE) --directory=scripts CC=icc CXX=icpc clean
$(MAKE) --directory=tests CC=icc CXX=icpc clean
$(MAKE) --directory=examples CC=icc CXX=icpc clean
icpc-zip:
$(MAKE) --directory=src CC=icc CXX=icpc zip
#AMD
openCC: openCC-all
openCC-all:
$(MAKE) openCC-dist
$(MAKE) openCC-shared
$(MAKE) --directory=src CC=opencc CXX=openCC copy
openCC-dist:
$(MAKE) openCC-contribs
openCC-debug:
$(MAKE) openCC-all DEBUG=yes
openCC-core:
$(MAKE) --directory=src CC=opencc CXX=openCC all
openCC-contribs: openCC-core
$(MAKE) --directory=contrib CC=opencc CXX=openCC all
openCC-docs:
$(MAKE) --directory=docs CC=opencc CXX=openCC all
openCC-gtests:
$(MAKE) --directory=tests CC=opencc CXX=openCC unit-gtests
openCC-verify:
$(MAKE) --directory=tests CC=opencc CXX=openCC verify
openCC-shared:
$(MAKE) --directory=src CC=opencc CXX=openCC SHARED=-shared shared
$(MAKE) --directory=contrib CC=opencc CXX=openCC SHARED=-shared shared
openCC-install:
$(MAKE) --directory=src CC=opencc CXX=openCC install
openCC-check:
$(MAKE) --directory=src CC=opencc CXX=openCC check
openCC-clean:
$(MAKE) --directory=src CC=opencc CXX=openCC clean
$(MAKE) --directory=contrib CC=opencc CXX=openCC clean
$(MAKE) --directory=scripts CC=opencc CXX=openCC clean
$(MAKE) --directory=tests CC=opencc CXX=openCC clean
$(MAKE) --directory=examples CC=opencc CXX=openCC clean
openCC-zip:
$(MAKE) --directory=src CC=opencc CXX=openCC zip
#scan-build
analyze-c++: analyze-c++-all
analyze-c++-all:
$(MAKE) analyze-c++-dist
$(MAKE) analyze-c++-shared
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ copy
analyze-c++-dist:
$(MAKE) analyze-c++-contribs
analyze-c++-debug:
$(MAKE) analyze-c++-all DEBUG=yes
analyze-c++-core:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ all
analyze-c++-contribs: analyze-c++-core
$(MAKE) --directory=contrib CC=analyze-cc CXX=analyze-c++ all
analyze-c++-docs:
$(MAKE) --directory=docs CC=analyze-cc CXX=analyze-c++ all
analyze-c++-coverage:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ SAFE_ONLY=yes dist
$(MAKE) --directory=tests CC=analyze-cc CXX=analyze-c++ coverage
analyze-c++-gtests:
$(MAKE) --directory=tests CC=analyze-cc CXX=analyze-c++ unit-gtests
analyze-c++-verify:
$(MAKE) --directory=tests CC=analyze-cc CXX=analyze-c++ verify
analyze-c++-shared:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ SHARED=-shared shared
$(MAKE) --directory=contrib CC=analyze-cc CXX=analyze-c++ SHARED=-shared shared
analyze-c++-install:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ install
analyze-c++-check:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ check
analyze-c++-clean:
$(MAKE) --directory=src CC=analyze-cc CXX=analyze-c++ clean
$(MAKE) --directory=contrib CC=analyze-cc CXX=analyze-c++ clean
$(MAKE) --directory=scripts CC=analyze-cc CXX=analyze-c++ clean
$(MAKE) --directory=tests CC=analyze-cc CXX=analyze-c++ clean
$(MAKE) --directory=examples CC=analyze-cc CXX=analyze-c++ clean
analyze-c++-zip:
#Unsupported Borland 5.5
bcc: bcc-all
bcc-all: bcc-src
bcc-dist: bcc-src
bcc-src:
cd src& $(MAKE) -fbcc.mak all
bcc-debug:
bcc-verify:
cd src& $(MAKE) -fbcc.mak verify
bcc-gtests:
bcc-install:
cd src& $(MAKE) -fbcc.mak install
bcc-clean:
cd src& $(MAKE) -fbcc.mak clean