]> matita.cs.unibo.it Git - helm.git/blob - helm/www/matita/Makefile
...
[helm.git] / helm / www / matita / Makefile
1
2 # should be a checked out version of sofware/matita/help/C/ (or a symlink to it)
3 DOCS_SRC_DIR = docs-src
4 DOCS_DEST_DIR = $(CURDIR)/docs/manual
5
6 MARGIN_X=30
7 MARGIN_Y=206
8 SIZE_X=426
9 SIZE_Y=70
10
11 SEQ=3
12
13 all:
14         @echo
15         @echo "Nothing to do per default, interesting targets:"
16         @echo
17         @echo "  manual    # import the (xhtml version of the) user manual"
18         @echo "  library   # import the scripts building the library"
19         @echo "  images    # build images for the splash screen"
20         @echo "  papers    # build the papers page from xml/papers.xml"
21         @echo
22
23 clean:
24
25 manual: manual-stamp
26 manual-stamp: $(DOCS_SRC_DIR)/*.xml $(DOCS_SRC_DIR)/xsl/*
27         $(MAKE) -C $(DOCS_SRC_DIR)/ html
28         rm -rf $(DOCS_DEST_DIR)/*
29         test -d $(DOCS_DEST_DIR)/ || mkdir -p $(DOCS_DEST_DIR)/
30         $(MAKE) -C $(DOCS_SRC_DIR) install DESTDIR=$(DOCS_DEST_DIR)/
31         touch $@
32
33 .PHONY: library
34 library:
35         if [ -d library/ ] ; then \
36           svn update library/ ; \
37         else \
38           echo "Can't find the scripts, check them out in library/" ; \
39           exit 1 ; \
40         fi
41
42 papers: papers.shtml
43 papers.shtml: xsl/papers2xhtml.xsl xml/papers.xml
44         xsltproc $^ > $@
45
46 .PHONY: images
47 images: images/matita.xcf
48         for Y in `seq 0 $(SEQ)`; do \
49                 convert images/matita.png -crop \
50                         $(SIZE_X)x$(SIZE_Y)+$(MARGIN_X)+`expr $(MARGIN_Y) + $$Y '*' '(' $(SIZE_Y) + 1 ')'` tmp.png; \
51                 composite -compose src-over images/bg.png tmp.png images/bg$$Y.png;\
52         done;\
53         rm tmp.png              
54
55 clean:
56         rm -f manual-stamp
57 dist-clean: clean
58         for X in `seq 0 $(SEQ)`; do\
59                 rm images/bg$$X.png;\
60         done
61