File: Makefile.in

package info (click to toggle)
synopsis 0.8.0-5
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 10,112 kB
  • ctags: 12,996
  • sloc: cpp: 34,254; ansic: 33,620; python: 10,975; sh: 7,261; xml: 6,369; makefile: 773; asm: 445
file content (80 lines) | stat: -rw-r--r-- 2,201 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
#
# Copyright (C) 2003 Stefan Seefeld
# All rights reserved.
# Licensed to the public under the terms of the GNU LGPL (>= 2),
# see the file COPYING for details.
#

SHELL	:= /bin/sh

srcdir	:= @srcdir@

processors := Synopsis.Parsers.Python.Parser \
              Synopsis.Parsers.IDL.Parser \
              Synopsis.Parsers.Cpp.Parser \
              Synopsis.Parsers.C.Parser \
              Synopsis.Parsers.Cxx.Parser \
              Synopsis.Processors.Linker \
              Synopsis.Formatters.Dump.Formatter \
              Synopsis.Formatters.Docbook.Formatter \
              Synopsis.Formatters.Texinfo.Formatter \
              Synopsis.Formatters.Dot.Formatter \
              Synopsis.Formatters.HTML.Formatter \
              Synopsis.Formatters.SXR.Formatter

appendix:= $(patsubst %, %.xml, $(processors))
examples:= $(shell cd $(srcdir) && find examples -path '*/.svn' -prune -o -type f -a -print)

.PHONY: examples

vpath %.xml $(srcdir)

all: html pdf
html: html/Tutorial html/DevGuide
pdf: Tutorial.pdf DevGuide.pdf

html/Tutorial: Tutorial.xml $(appendix) examples 
	mkdir -p $@
	cp $(srcdir)/synopsis.css $@
	xsltproc --novalid --path $(shell pwd) --xinclude -o $@/ $(srcdir)/html.xsl $<
	mkdir -p $@/images
	cp $(srcdir)/images/*.png $@/images/
	cp examples/Paths/doc4/*.png $@/images/

html/DevGuide: DevGuide.xml
	mkdir -p $@
	cp $(srcdir)/synopsis.css $@
	xsltproc --novalid -o $@/ $(srcdir)/html.xsl $<
	mkdir -p $@/images
	cp $(srcdir)/images/*.png $@/images/

examples:
	for file in $(examples); do \
          if ! cmp -s $(srcdir)/$$file $$file 2>/dev/null; then \
            mkdir -p `dirname $$file`;\
            cp -p $(srcdir)/$$file $$file;\
          fi\
        done
	make -C examples       # build examples...
	make -C examples clean # ...but remove temporary files

Tutorial.pdf: $(appendix)

%.pdf: %.fo
	fop $< $@

%.fo: %.xml
	xsltproc --novalid --path $(shell pwd) --xinclude -o $@ $(srcdir)/fo.xsl $^
	mkdir -p images
	cp -u $(srcdir)/images/*.svg images/

$(appendix): %.xml:
	python $(srcdir)/parameters.py $(patsubst %.xml, %, $@) $@

clean:
	rm -f Synopsis.*.xml
	rm Tutorial.fo DevGuide.fo

distclean: clean
	rm -rf html Tutorial.pdf DevGuide.pdf