source: project/release/4/picnic/trunk/picnic.setup @ 30645

Last change on this file since 30645 was 30645, checked in by Ivan Raikov, 7 years ago

picnic: reintegrated calculator language parser

File size: 2.4 KB
Line 
1; -*- Hen -*-
2
3(define (dynld-name fn)         
4  (make-pathname #f fn ##sys#load-dynamic-extension))   
5
6(include "picnic-version.scm")
7
8(use make)
9
10(make (
11       ("calc.yy.scm" ("calc.grm")
12        (run (csi -s calc.grm)))
13
14       ((dynld-name "picnic-utils") ("picnic-utils.scm" "calc.yy.scm")
15        (compile -O -d2 -S -s picnic-utils.scm -j picnic-utils))
16
17       ((dynld-name "picnic-utils.import") ("picnic-utils.import.scm")
18        (compile -O2 -s picnic-utils.import.scm))
19       )
20  (list (dynld-name "picnic-utils")
21        (dynld-name "picnic-utils.import"))
22  )
23
24(install-extension
25
26  ; Name of your extension:
27  'picnic-utils
28
29  ; Files to install for your extension:
30  `(,(dynld-name "picnic-utils") ,(dynld-name "picnic-utils.import"))
31
32  ; Assoc list with properties for your extension:
33  `((version ,picnic-version)))
34
35(make (
36       ((dynld-name "picnic-core") ("picnic-core.scm")
37        (compile -O -d2 -S -s picnic-core.scm -j picnic-core))
38
39       ((dynld-name "picnic-core.import") ("picnic-core.import.scm")
40        (compile -O2 -s picnic-core.import.scm))
41       )
42  (list (dynld-name "picnic-core")
43        (dynld-name "picnic-core.import"))
44  )
45
46(install-extension
47
48  ; Name of your extension:
49  'picnic-core
50
51  ; Files to install for your extension:
52  `(,(dynld-name "picnic-core") ,(dynld-name "picnic-core.import"))
53
54  ; Assoc list with properties for your extension:
55  `((version ,picnic-version)))
56
57
58(if (deployment-mode)
59
60    (begin
61      (run (csi -s expr.grm))
62      (compile -deploy -uses files -O -d2 picnic.scm
63               -o ,(installation-prefix))
64      )
65
66    (begin
67      (make (
68             ("expr.grm.scm" ("expr.grm")
69              (run (csi -s expr.grm)))
70
71             ("picnic" ("picnic.scm" "expr.grm.scm")
72              (compile -O -d2 picnic.scm))
73             )
74        "picnic")
75     
76      (install-program
77       'picnic
78       
79       `("picnic" )
80       
81       `((version ,picnic-version)
82         ))
83      )
84    )
85
86;; From setup-header.scm by Kon Lovett
87
88(define (installation-chicken-home)
89  (if (not (installation-prefix)) (chicken-home)
90    (make-pathname `(,(installation-prefix) "share") "chicken") ) )
91
92;;; Constants & Procedures
93
94(define SHARED-DIR (installation-chicken-home))
95(define PICNIC-DIR (make-pathname SHARED-DIR "picnic"))
96
97;; File Copy Operations
98
99(define (copy-file-to-picnic-dir fn)
100  (let ([fn (->string fn)])
101    (copy-file fn (make-pathname PICNIC-DIR fn)) ) )
102
Note: See TracBrowser for help on using the repository browser.