source: project/release/4/9ML-toolkit/tags/2.12/9ML-toolkit.setup @ 29980

Last change on this file since 29980 was 29980, checked in by Ivan Raikov, 8 years ago

9ML-toolkit release 2.12

File size: 9.0 KB
Line 
1;;;; -*- Hen -*-
2
3(define (dynld-name fn)         
4  (make-pathname #f fn ##sys#load-dynamic-extension))   
5
6(define version "2.12")
7
8(use make)
9
10
11(make (
12       ("NineML.grm.scm" ("NineML.grm")
13        (run (csi -s NineML.grm)))
14
15       ("NineML.l.scm" ("NineML.l")
16        (run (csi -n -R silex
17                  -e "'(lex \"NineML.l\" \"NineML.l.scm\" (quote counters) (quote line))'")))
18
19       ("expr.grm.scm" ("expr.grm")
20        (run (csi -s expr.grm)))
21
22       ((dynld-name "9ML-parse") ("parse.scm" "NineML.l.scm" "NineML.grm.scm" "expr.grm.scm" "expr-parser.scm")
23        (compile -O -d2 -S -s parse.scm -o ,(dynld-name "9ML-parse") -j 9ML-parse))
24
25       ((dynld-name "9ML-parse.import") ("9ML-parse.import.scm")
26        (compile  -s 9ML-parse.import.scm))
27
28       ((dynld-name "9ML-eval") ("eval.scm" "SXML.scm" "SXML-to-XML.scm" (dynld-name "9ML-parse") )
29        (compile -O -d2 -S -s eval.scm -o ,(dynld-name "9ML-eval") -j 9ML-eval))
30
31       ((dynld-name "9ML-eval.import") ("9ML-eval.import.scm")
32        (compile  -s 9ML-eval.import.scm))
33
34       ((dynld-name "9ML-plot") ("plot.scm" (dynld-name "9ML-eval") )
35        (compile -O -d2 -S -s plot.scm -o ,(dynld-name "9ML-plot") -j 9ML-plot))
36
37       ((dynld-name "9ML-plot.import") ("9ML-plot.import.scm")
38        (compile  -s 9ML-plot.import.scm))
39
40       ((dynld-name "9ML-ivp-octave") ("ivp-octave.scm" )
41        (compile -O -d2 -S -s ivp-octave.scm -o ,(dynld-name "9ML-ivp-octave") -j 9ML-ivp-octave))
42
43       ((dynld-name "9ML-ivp-octave.import") ( "9ML-ivp-octave.import.scm" )
44        (compile  -s 9ML-ivp-octave.import.scm))
45
46       ((dynld-name "9ML-ivp-chicken") ("ivp-chicken.scm" )
47        (compile -O -d2 -S -s ivp-chicken.scm -o ,(dynld-name "9ML-ivp-chicken") -j 9ML-ivp-chicken))
48
49       ((dynld-name "9ML-ivp-chicken.import") ( "9ML-ivp-chicken.import.scm" )
50        (compile  -s 9ML-ivp-chicken.import.scm))
51
52       ((dynld-name "9ML-ivp-mlton") ( "ivp-mlton.scm" )
53        (compile -O -d2 -S -s ivp-mlton.scm -o ,(dynld-name "9ML-ivp-mlton") -j 9ML-ivp-mlton))
54
55       ((dynld-name "9ML-ivp-mlton.import") ( "9ML-ivp-mlton.import.scm" )
56        (compile  -s 9ML-ivp-mlton.import.scm))
57
58       ((dynld-name "9ML-ivp-octave-mlton") ( "ivp-octave-mlton.scm" )
59        (compile -O -d2 -S -s ivp-octave-mlton.scm -o ,(dynld-name "9ML-ivp-octave-mlton") -j 9ML-ivp-octave-mlton))
60
61       ((dynld-name "9ML-ivp-octave-mlton.import") ("9ML-ivp-octave-mlton.import.scm")
62        (compile  -s 9ML-ivp-octave-mlton.import.scm))
63
64       ((dynld-name "9ML-ivp-lib" )
65        ("ivp-lib.scm" )
66        (compile -O -d2 -S -s ivp-lib.scm -o ,(dynld-name "9ML-ivp-lib") -j 9ML-ivp-lib))
67
68       ((dynld-name "9ML-ivp-lib.import") ("9ML-ivp-lib.import.scm")
69        (compile -s 9ML-ivp-lib.import.scm))
70
71       ((dynld-name "9ML-toolkit")
72        ("9ML-toolkit.scm" "NineMLcore.scm" "NineMLreal.scm" "NineMLsignal.scm" "NineMLdiagram.scm" "NineMLivp.scm"  )
73        (compile -O -d2 -S -s 9ML-toolkit.scm -o ,(dynld-name "9ML-toolkit") -j 9ML-toolkit))
74
75       ((dynld-name "9ML-toolkit.import") ("9ML-toolkit.import.scm")
76        (compile  -s 9ML-toolkit.import.scm))
77
78       )
79
80  (list (dynld-name "9ML-toolkit")     (dynld-name "9ML-toolkit.import")
81        (dynld-name "9ML-plot")        (dynld-name "9ML-plot.import")
82        (dynld-name "9ML-eval")        (dynld-name "9ML-eval.import")
83        (dynld-name "9ML-parse")       (dynld-name "9ML-parse.import")
84        (dynld-name "9ML-ivp-octave")  (dynld-name "9ML-ivp-octave.import")
85        (dynld-name "9ML-ivp-chicken") (dynld-name "9ML-ivp-chicken.import")
86        (dynld-name "9ML-ivp-mlton")   (dynld-name "9ML-ivp-mlton.import")
87        (dynld-name "9ML-ivp-octave-mlton") (dynld-name "9ML-ivp-octave-mlton.import")
88        (dynld-name "9ML-ivp-lib")     (dynld-name "9ML-ivp-lib.import")
89        )
90
91  )
92
93
94(install-extension
95
96  ; Name of your extension:
97  '9ML-ivp-lib
98
99  ; Files to install for your extension:
100  `(,(dynld-name "9ML-ivp-lib") ,(dynld-name "9ML-ivp-lib.import") )
101
102  ; Assoc list with properties for your extension:
103  `((version ,version)
104    ))
105
106(install-extension
107
108  ; Name of your extension:
109  '9ML-ivp-octave
110
111  ; Files to install for your extension:
112  `(,(dynld-name "9ML-ivp-octave") ,(dynld-name "9ML-ivp-octave.import") )
113
114  ; Assoc list with properties for your extension:
115  `((version ,version)
116    ))
117
118(install-extension
119
120  ; Name of your extension:
121  '9ML-ivp-chicken
122
123  ; Files to install for your extension:
124  `(,(dynld-name "9ML-ivp-chicken") ,(dynld-name "9ML-ivp-chicken.import") )
125
126  ; Assoc list with properties for your extension:
127  `((version ,version)
128    ))
129
130(install-extension
131
132  ; Name of your extension:
133  '9ML-ivp-mlton
134
135  ; Files to install for your extension:
136  `(,(dynld-name "9ML-ivp-mlton") ,(dynld-name "9ML-ivp-mlton.import") )
137
138  ; Assoc list with properties for your extension:
139  `((version ,version)
140    ))
141
142(install-extension
143
144  ; Name of your extension:
145  '9ML-ivp-octave-mlton
146
147  ; Files to install for your extension:
148  `(,(dynld-name "9ML-ivp-octave-mlton") ,(dynld-name "9ML-ivp-octave-mlton.import") )
149
150  ; Assoc list with properties for your extension:
151  `((version ,version)
152    ))
153
154(install-extension
155
156  ; Name of your extension:
157  '9ML-toolkit
158
159  ; Files to install for your extension:
160  `(,(dynld-name "9ML-toolkit") ,(dynld-name "9ML-toolkit.import") )
161
162  ; Assoc list with properties for your extension:
163  `((version ,version)
164    ))
165
166(install-extension
167
168  ; Name of your extension:
169  '9ML-eval
170
171  ; Files to install for your extension:
172  `(,(dynld-name "9ML-eval") ,(dynld-name "9ML-eval.import") )
173
174  ; Assoc list with properties for your extension:
175  `((version ,version)
176    ))
177
178
179(install-extension
180
181  ; Name of your extension:
182  '9ML-parse
183
184  ; Files to install for your extension:
185  `(,(dynld-name "9ML-parse") ,(dynld-name "9ML-parse.import") )
186
187  ; Assoc list with properties for your extension:
188  `((version ,version)
189    ))
190
191(install-extension
192
193  ; Name of your extension:
194  '9ML-plot
195
196  ; Files to install for your extension:
197  `(,(dynld-name "9ML-plot") ,(dynld-name "9ML-plot.import") )
198
199  ; Assoc list with properties for your extension:
200  `((version ,version)
201    ))
202
203
204(if (deployment-mode)
205
206    (compile -deploy -uses files -O -d2 report.scm
207             -o ,(make-pathname (installation-prefix) "bin/9ML-report"))
208
209    (begin
210      (make (
211             ("9ML-report"
212              ("NineMLcore.scm" "NineMLreal.scm" "NineMLrandom.scm" "NineMLsignal.scm" "NineMLdiagram.scm"
213               "report.scm" )
214              (compile -O -d2 -S report.scm -o 9ML-report ))
215             )
216        "9ML-report")
217
218      (install-program
219       '9ML-report
220       
221       `("9ML-report" )
222       
223       `((version ,version)))
224      )
225    )
226
227
228(if (deployment-mode)
229
230    (compile -deploy -uses files -O -d2 ivp.scm -verbose
231             -o ,(make-pathname (installation-prefix) "/bin/9ML-ivp"))
232
233    (begin
234      (make (
235             
236             ("9ML-ivp"
237              ("NineMLcore.scm" "NineMLreal.scm" "NineMLrandom.scm" "NineMLsignal.scm" "NineMLdiagram.scm"
238               "ivp.scm" )
239              (compile -O -d2 -S ivp.scm -o 9ML-ivp ))
240             )
241        "9ML-ivp")
242     
243      (install-program
244       '9ML-ivp
245       
246       `("9ML-ivp" )
247       
248       `((version ,version)))
249      )
250    )
251
252
253(if (deployment-mode)
254
255    (compile -deploy -uses files -O -d2 shell.scm
256             -o ,(make-pathname (installation-prefix) "/bin/9ML-shell"))
257
258    (begin
259      (make (
260             ("9ML-shell"
261              ("NineMLcore.scm" "NineMLreal.scm" "NineMLrandom.scm" "NineMLsignal.scm" "NineMLdiagram.scm"
262               "shell.scm" )
263              (compile -O -d2 -S shell.scm -o 9ML-shell ))
264             )
265        "9ML-shell")
266
267      (install-program
268       '9ML-shell
269       
270       `("9ML-shell" )
271       
272       `((version ,version)))
273      )
274    )
275
276
277(if (deployment-mode)
278
279    (compile -deploy -uses files -O -d2 network.scm
280             -o ,(make-pathname (installation-prefix) "/bin/9ML-network"))
281
282    (begin
283      (make (
284             ("9ML-network"
285              ("NineMLcore.scm" "NineMLreal.scm" "NineMLrandom.scm" "NineMLsignal.scm" "NineMLdiagram.scm"
286               "network.scm" )
287              (compile -O -d2 -S network.scm -o 9ML-network ))
288             )
289        "9ML-network")
290
291      (install-program
292       '9ML-network
293       
294       `("9ML-network" )
295       
296       `((version ,version)))
297      )
298    )
299
300(define (installation-chicken-home)
301  (if (not (installation-prefix)) (chicken-home)
302    (make-pathname `(,(installation-prefix) "share") "chicken") ) )
303
304(define SHARED-DIR (installation-chicken-home))
305
306(define 9ML-DIR (make-pathname SHARED-DIR "9ML"))
307
308;; File Copy Operations
309
310(define (*file-copy fn dn)
311  (let ([fn (->string fn)])
312    (copy-file fn (make-pathname dn fn)) ) )
313
314(define (copy-file-to-9ML-dir fn)
315  (*file-copy (->string fn) 9ML-DIR) )
316
317(if (not (file-exists? 9ML-DIR))
318    (create-directory/parents 9ML-DIR))
319
320
321(copy-file-to-9ML-dir "examples/MorrisLecar81.9ML")
322(copy-file-to-9ML-dir "examples/Izhikevich03.9ML")
323(copy-file-to-9ML-dir "examples/Destexhe94.9ML")
324(copy-file-to-9ML-dir "examples/LeakyIAF.9ML")
325(copy-file-to-9ML-dir "examples/ExcInhNetwork.9ML")
326
327(copy-file-to-9ML-dir "templates/Network.sml.tmpl")
328(copy-file-to-9ML-dir "templates/Sim.sml.tmpl")
329(copy-file-to-9ML-dir "templates/Sim.mlb.tmpl")
330(copy-file-to-9ML-dir "templates/Makefile.tmpl")
331
Note: See TracBrowser for help on using the repository browser.