source: project/release/3/amb/Makefile @ 18200

Last change on this file since 18200 was 435, checked in by Thomas Chust, 14 years ago

[amb] made the egg fit for -check-imports

File size: 1.2 KB
Line 
1CSI=csi
2CSC=csc
3TAR=tar
4ENSCRIPT=enscript
5
6CSCFLAGS=-O2 -d0 -check-imports
7LDLIBS=
8
9NAME=amb
10VERSION=1.2.0
11
12.PHONY: all clean
13
14all: $(NAME).egg $(NAME)-base.so
15
16clean:
17        $(RM) $(addprefix $(NAME),.egg -base.so .exports .html .setup)
18        $(RM) $(NAME)-demo.html
19
20$(NAME).egg: $(addprefix $(NAME),-base.scm .scm .html .setup) egg.jpg doc.scm $(NAME)-demo.scm Makefile
21        $(TAR) czf $@ $^
22
23$(NAME).html: doc.scm $(NAME)-demo.html
24        $(CSI) -s $< >$@
25
26$(NAME).setup: Makefile
27        echo "(define so-file" >$@; \
28        echo "  (string-append" >>$@; \
29        echo "    \"$(NAME)-base.\"" >>$@; \
30        echo "    (if (eq? (software-type) 'windows) \"dll\" \"so\")))" >>$@; \
31        echo "(compile" >>$@; \
32        echo $(CSCFLAGS) -s \"$(NAME)-base.scm\" $(LDLIBS)" >>$@; \
33        echo "  -o ,so-file -emit-exports \"$(NAME).exports\")" >>$@; \
34        echo "(install-extension" >>$@; \
35        echo "  '$(NAME)" >>$@; \
36        echo "  \`(\"$(NAME).scm\" ,so-file" >>$@; \
37        echo "    \"$(NAME).html\" \"egg.jpg\")" >>$@; \
38        echo "  '((syntax) (require-at-runtime $(NAME)-base)" >>$@; \
39        echo "    (version \"$(VERSION)\") (documentation \"$(NAME).html\")))" >>$@
40
41%.html: %.scm
42        $(ENSCRIPT) --color --pretty-print=scheme --language=html $< -o $@
43
44%.so: %.scm
45        $(CSC) $(CSCFLAGS) -s $< $(LDLIBS) -o $@
Note: See TracBrowser for help on using the repository browser.