Cleanup of old attributes. And addition of "top_tool" which is necessary for -clean...
[PsN.git] / Makefile
blobd110d4b7e37bab60ecbd3dfea71cb4407b9d8c82
1 DIAGRAMS=diagrams/llp.dia diagrams/tool.dia diagrams/model.dia diagrams/output.dia diagrams/data.dia diagrams/xrsl_file.dia diagrams/fcon.dia diagrams/nonmem.dia diagrams/moshog_client.dia
2 DOCUMENTS=html/bootstrap_synopsis.php html/bootstrap_description.php html/bootstrap_options.php html/bootstrap_examples.php \
3 html/cdd_synopsis.php html/cdd_description.php html/cdd_options.php html/cdd_examples.php \
4 html/execute_synopsis.php html/execute_description.php html/execute_options.php html/execute_examples.php \
5 html/llp_synopsis.php html/llp_description.php html/llp_options.php html/llp_examples.php \
6 html/scm_synopsis.php html/scm_description.php html/scm_options.php html/scm_examples.php
7 DIA2CODE=dia2code
8 FILLSCRIPT=perl ./bin/fill_diacode.pl
9 DIRPM=libgen/
10 DIRSUBS=lib/
11 PERLDIRS=-I/home/pontus/perl
12 PERLFILES=lib/debug.pm \
13 lib/ui.pm \
14 lib/status_bar.pm \
15 lib/nonmem.pm \
16 lib/moshog_client.pm \
17 lib/file.pm \
18 lib/data/individual.pm \
19 lib/data.pm \
20 lib/output/problem/subproblem.pm \
21 lib/output/problem.pm \
22 lib/output.pm \
23 lib/grid/nordugrid/xrsl_file.pm \
24 lib/fcon.pm \
25 lib/table_file.pm \
26 lib/extra_data.pm \
27 lib/model/problem/record/option.pm \
28 lib/model/problem/record/init_option.pm \
29 lib/model/problem/record/theta_option.pm \
30 lib/model/problem/record.pm \
31 lib/model/problem/code_record.pm \
32 lib/model/problem/init_record.pm \
33 lib/model/problem/abbreviated.pm \
34 lib/model/problem/aes.pm \
35 lib/model/problem/aesinit.pm \
36 lib/model/problem/contr.pm \
37 lib/model/problem/covariance.pm \
38 lib/model/problem/data.pm \
39 lib/model/problem/des.pm \
40 lib/model/problem/error.pm \
41 lib/model/problem/estimation.pm \
42 lib/model/problem/infn.pm \
43 lib/model/problem/input.pm \
44 lib/model/problem/msfi.pm \
45 lib/model/problem/mix.pm \
46 lib/model/problem/model.pm \
47 lib/model/problem/nonparametric.pm \
48 lib/model/problem/omega.pm \
49 lib/model/problem/pk.pm \
50 lib/model/problem/problem.pm \
51 lib/model/problem/pred.pm \
52 lib/model/problem/scatter.pm \
53 lib/model/problem/sigma.pm \
54 lib/model/problem/simulation.pm \
55 lib/model/problem/subroutine.pm \
56 lib/model/problem/table.pm \
57 lib/model/problem/theta.pm \
58 lib/model/problem/tol.pm \
59 lib/model/problem.pm \
60 lib/model/shrinkage_module.pm \
61 lib/model/nonparametric_module.pm \
62 lib/model.pm \
63 lib/tool.pm \
64 lib/tool/modelfit.pm \
65 lib/tool/llp.pm \
66 lib/tool/cdd.pm \
67 lib/tool/cdd/jackknife.pm \
68 lib/tool/mc.pm \
69 lib/tool/bootstrap.pm \
70 lib/tool/scm/config_file.pm \
71 lib/tool/scm.pm \
72 lib/tool/xv_step.pm \
73 lib/tool/xv.pm \
75 RELFILES=PsN-Source/lib/PsN_template.pm \
76 PsN-Source/lib/debug.pm \
77 PsN-Source/lib/ui.pm \
78 PsN-Source/lib/status_bar.pm \
79 PsN-Source/lib/nonmem.pm \
80 PsN-Source/lib/moshog_client.pm \
81 PsN-Source/lib/file.pm \
82 PsN-Source/lib/data/individual.pm \
83 PsN-Source/lib/data.pm \
84 PsN-Source/lib/output/problem/subproblem.pm \
85 PsN-Source/lib/output/problem.pm \
86 PsN-Source/lib/output.pm \
87 PsN-Source/lib/grid/nordugrid/xrsl_file.pm \
88 PsN-Source/lib/fcon.pm \
89 PsN-Source/lib/table_file.pm \
90 PsN-Source/lib/extra_data.pm \
91 PsN-Source/lib/model/problem/record/option.pm \
92 PsN-Source/lib/model/problem/record/init_option.pm \
93 PsN-Source/lib/model/problem/record/theta_option.pm \
94 PsN-Source/lib/model/problem/record.pm \
95 PsN-Source/lib/model/problem/code_record.pm \
96 PsN-Source/lib/model/problem/init_record.pm \
97 PsN-Source/lib/model/problem/abbreviated.pm \
98 PsN-Source/lib/model/problem/aes.pm \
99 PsN-Source/lib/model/problem/aesinit.pm \
100 PsN-Source/lib/model/problem/contr.pm \
101 PsN-Source/lib/model/problem/covariance.pm \
102 PsN-Source/lib/model/problem/data.pm \
103 PsN-Source/lib/model/problem/des.pm \
104 PsN-Source/lib/model/problem/error.pm \
105 PsN-Source/lib/model/problem/estimation.pm \
106 PsN-Source/lib/model/problem/infn.pm \
107 PsN-Source/lib/model/problem/input.pm \
108 PsN-Source/lib/model/problem/msfi.pm \
109 PsN-Source/lib/model/problem/mix.pm \
110 PsN-Source/lib/model/problem/model.pm \
111 PsN-Source/lib/model/problem/nonparametric.pm \
112 PsN-Source/lib/model/problem/omega.pm \
113 PsN-Source/lib/model/problem/pk.pm \
114 PsN-Source/lib/model/problem/problem.pm \
115 PsN-Source/lib/model/problem/pred.pm \
116 PsN-Source/lib/model/problem/scatter.pm \
117 PsN-Source/lib/model/problem/sigma.pm \
118 PsN-Source/lib/model/problem/simulation.pm \
119 PsN-Source/lib/model/problem/subroutine.pm \
120 PsN-Source/lib/model/problem/table.pm \
121 PsN-Source/lib/model/problem/theta.pm \
122 PsN-Source/lib/model/problem/tol.pm \
123 PsN-Source/lib/model/problem.pm \
124 PsN-Source/lib/model/shrinkage_module.pm \
125 PsN-Source/lib/model/nonparametric_module.pm \
126 PsN-Source/lib/model.pm \
127 PsN-Source/lib/tool.pm \
128 PsN-Source/lib/tool/modelfit.pm \
129 PsN-Source/lib/tool/llp.pm \
130 PsN-Source/lib/tool/cdd.pm \
131 PsN-Source/lib/tool/cdd/jackknife.pm \
132 PsN-Source/lib/tool/mc.pm \
133 PsN-Source/lib/tool/bootstrap.pm \
134 PsN-Source/lib/tool/scm/config_file.pm \
135 PsN-Source/lib/tool/scm.pm \
136 PsN-Source/lib/tool/xv_step.pm \
137 PsN-Source/lib/tool/xv.pm \
138 PsN-Source/lib/common_options.pm \
139 PsN-Source/lib/psn.conf \
140 PsN-Source/setup.pl \
141 PsN-Source/bin/execute \
142 PsN-Source/bin/cdd \
143 PsN-Source/bin/mc_cdd \
144 PsN-Source/bin/mcs \
145 PsN-Source/bin/llp \
146 PsN-Source/bin/scm \
147 PsN-Source/bin/bootstrap \
148 PsN-Source/bin/sumo \
149 PsN-Source/bin/single_valued_columns \
150 PsN-Source/bin/check_termination \
151 PsN-Source/bin/create_extra_data_model \
152 PsN-Source/bin/create_cont_model \
153 PsN-Source/bin/create_cont_data \
154 PsN-Source/bin/create_subsets \
155 PsN-Source/bin/unwrap_data \
156 PsN-Source/bin/data_stats \
157 PsN-Source/bin/gam42toconf \
158 PsN-Source/lib/OSspecific.pm \
159 PsN-Source/lib/hotkey.pm \
160 PsN-Source/README.txt \
161 PsN-Source/lib/ext/Math/SigFigs.pm \
162 PsN-Source/lib/ext/Math/MatrixReal.pm \
163 PsN-Source/lib/ext/Statistics/Distributions.pm \
164 PsN-Source/lib/ext/Parallel/ForkManager.pm \
165 PsN-Source/lib/ext/Config/Tiny.pm \
166 PsN-Source/lib/ext/Color/Output.pm \
167 PsN-Source/lib/ext/File/HomeDir.pm \
168 PsN-Source/lib/ext/IPC/Run3.pm \
169 PsN-Source/lib/matlab/bca.m \
170 PsN-Source/lib/matlab/histograms.m \
171 PsN-Source/lib/matlab/profiles.m \
172 PsN-Source/lib/R-scripts/llp.R \
173 PsN-Source/lib/R-scripts/cdd.R \
174 PsN-Source/lib/R-scripts/bootstrap.R
176 RELDIRS=PsN-Source \
177 PsN-Source/bin \
178 PsN-Source/lib \
179 PsN-Source/lib/data \
180 PsN-Source/lib/output/problem/ \
181 PsN-Source/lib/model/problem/record \
182 PsN-Source/lib/tool/scm \
183 PsN-Source/lib/tool/cdd \
184 PsN-Source/lib/grid/nordugrid \
185 PsN-Source/modules \
186 PsN-Source/lib/ext \
187 PsN-Source/lib/ext/Math \
188 PsN-Source/lib/ext/Statistics \
189 PsN-Source/lib/ext/Parallel \
190 PsN-Source/lib/ext/IPC \
191 PsN-Source/lib/ext/Config \
192 PsN-Source/lib/ext/File \
193 PsN-Source/lib/ext/Color \
194 PsN-Source/lib/matlab \
195 PsN-Source/lib/R-scripts
197 GENFILES=libgen/debug.pm \
198 libgen/ui.pm \
199 libgen/status_bar.pm \
200 libgen/nonmem.pm \
201 libgen/moshog_client.pm \
202 libgen/file.pm \
203 libgen/tool.pm \
204 libgen/tool/modelfit.pm \
205 libgen/tool/llp.pm \
206 libgen/tool/cdd.pm \
207 libgen/tool/cdd/jackknife.pm \
208 libgen/tool/mc.pm \
209 libgen/tool/bootstrap.pm \
210 libgen/tool/scm/config_file.pm \
211 libgen/tool/scm.pm \
212 libgen/tool/xv_step.pm \
213 libgen/tool/xv.pm \
214 libgen/model/problem/record/option.pm \
215 libgen/model/problem/record/init_option.pm \
216 libgen/model/problem/record/theta_option.pm \
217 libgen/model/problem/record.pm \
218 libgen/model/problem/code_record.pm \
219 libgen/model/problem/init_record.pm \
220 libgen/model/problem/abbreviated.pm \
221 libgen/model/problem/aes.pm \
222 libgen/model/problem/aesinit.pm \
223 libgen/model/problem/contr.pm \
224 libgen/model/problem/covariance.pm \
225 libgen/model/problem/data.pm \
226 libgen/model/problem/des.pm \
227 libgen/model/problem/error.pm \
228 libgen/model/problem/estimation.pm \
229 libgen/model/problem/infn.pm \
230 libgen/model/problem/input.pm \
231 libgen/model/problem/msfi.pm \
232 libgen/model/problem/mix.pm \
233 libgen/model/problem/model.pm \
234 libgen/model/problem/nonparametric.pm \
235 libgen/model/problem/omega.pm \
236 libgen/model/problem/pk.pm \
237 libgen/model/problem/problem.pm \
238 libgen/model/problem/pred.pm \
239 libgen/model/problem/scatter.pm \
240 libgen/model/problem/sigma.pm \
241 libgen/model/problem/simulation.pm \
242 libgen/model/problem/subroutine.pm \
243 libgen/model/problem/table.pm \
244 libgen/model/problem/theta.pm \
245 libgen/model/problem/tol.pm \
246 libgen/model/problem.pm \
247 libgen/model/shrinkage_module.pm \
248 libgen/model/nonparametric_module.pm \
249 libgen/model.pm \
250 libgen/data/individual.pm \
251 libgen/data.pm \
252 libgen/output/problem/subproblem.pm \
253 libgen/output/problem.pm \
254 libgen/output.pm \
255 libgen/table_file.pm \
256 libgen/extra_data.pm \
257 libgen/grid/nordugrid/xrsl_file.pm \
258 libgen/fcon.pm \
260 all: libgen $(PERLFILES)
262 .SECONDARY: $(GENFILES)
264 libgen:
265 @ mkdir -p libgen
267 lib/%.pm: libgen/%.pm lib/%_subs.pm
268 @ cp libgen/$*.pm libgen/$*_temp.pm
269 @ $(FILLSCRIPT) libgen/$*_temp.pm lib/$*_subs.pm
270 @ cp libgen/$*_temp.pm $@
271 @ perl $(PERLDIRS) -I./$(@D) -I./lib -c $@ -W -t -T|| (rm $@ && false)
273 .PHONY : clean
274 clean:
275 @-rm -rf $(PERLFILES) $(GENFILES) $(DOCUMENTS) libgen PsN-Source
277 libgen/debug.pm : diagrams/debug.dia
278 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/debug.dia
280 libgen/ui.pm : diagrams/ui.dia
281 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/ui.dia
283 libgen/status_bar.pm : diagrams/status_bar.dia
284 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/status_bar.dia
286 libgen/nonmem.pm : diagrams/nonmem.dia
287 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/nonmem.dia
289 libgen/moshog_client.pm : diagrams/moshog_client.dia
290 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/moshog_client.dia
292 libgen/file.pm : diagrams/file.dia
293 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/file.dia
295 libgen/tool/modelfit.pm : diagrams/modelfit.dia
296 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/modelfit.dia
298 libgen/tool/llp.pm : diagrams/llp.dia
299 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/llp.dia
301 libgen/tool/cdd/jackknife.pm libgen/tool/cdd.pm : diagrams/cdd.dia
302 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/cdd.dia
304 libgen/tool/mc.pm : diagrams/mc.dia
305 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/mc.dia
307 libgen/tool/bootstrap.pm : diagrams/bootstrap.dia
308 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/bootstrap.dia
310 libgen/tool/scm/config_file.pm libgen/tool/scm.pm : diagrams/scm.dia
311 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/scm.dia
313 libgen/tool/xv_step.pm libgen/tool/xv.pm : diagrams/xv.dia
314 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/xv.dia
316 libgen/tool.pm : diagrams/tool.dia
317 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/tool.dia
319 libgen/table_file.pm libgen/extra_data.pm libgen/model%.pm : diagrams/model.dia
320 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/model.dia
322 libgen/output%.pm : diagrams/output.dia
323 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/output.dia
325 libgen/data%.pm : diagrams/data.dia
326 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/data.dia
328 libgen/grid/nordugrid/xrsl_file.pm : diagrams/xrsl_file.dia
329 $(DIA2CODE) -t perl -d $(DIRPM) diagrams/xrsl_file.dia
331 libgen/fcon.pm : diagrams/fcon.dia
332 $(DIA2CODE) -nd -t perl -d $(DIRPM) diagrams/fcon.dia
334 documents: $(DOCUMENTS)
336 html/bootstrap_synopsis.php html/bootstrap_description.php html/bootstrap_options.php html/bootstrap_examples.php : bin/bootstrap lib/common_options.pm
337 $^ --help --html
339 html/cdd_synopsis.php html/cdd_description.php html/cdd_options.php html/cdd_examples.php : bin/cdd lib/common_options.pm
340 $^ --help --html
342 html/execute_synopsis.php html/execute_description.php html/execute_options.php html/execute_examples.php : bin/execute lib/common_options.pm
343 $^ --help --html
345 html/llp_synopsis.php html/llp_description.php html/llp_options.php html/llp_examples.php : bin/llp lib/common_options.pm
346 $^ --help --html
348 html/scm_synopsis.php html/scm_description.php html/scm_options.php html/scm_examples.php : bin/scm lib/common_options.pm
349 $^ --help --html
352 release: $(RELDIRS) $(RELFILES) documents
353 @ cp -ar modules/Math-Random \
354 modules/Math-Random-Win \
355 modules/Storable PsN-Source/modules
356 @ zip -r PsN-Source PsN-Source/
357 @ tar czf PsN-Source.tar.gz PsN-Source/
359 PsN-Source/setup.pl: bin/setup.pl
360 @ cp bin/setup.pl $@
362 PsN-Source/lib/matlab/% : matlab/%
363 @ cp matlab/$* $@
365 PsN-Source/lib/R-scripts/% : matlab/%
366 @ cp R-scripts/$* $@
368 PsN-Source/%: %
369 @ cp -ar $* $@
371 $(RELDIRS):
372 @ mkdir -p $@