source: trunk/doc/Makefile.am @ 2175

Last change on this file since 2175 was 2170, checked in by jylam, 8 years ago
  • Include common.am in doc/Makefile
File size: 1.7 KB
Line 
1include $(top_srcdir)/build/autotools/common.am
2
3EXTRA_DIST = doxygen.cfg.in doxygen.css footer.html header.html \
4             $(man_MANS) $(doxygen_DOX)
5CLEANFILES += doxygen.log stamp-latex stamp-doxygen
6
7doxygen_DOX = lolengine.dox
8man_MANS = lolengine.1
9
10if BUILD_DOCUMENTATION
11htmldoc_DATA = html/doxygen.css
12htmldocdir = $(datadir)/doc/lolengine-dev/html
13if USE_LATEX
14pdfdoc_DATA = latex/lolengine.pdf
15pdfdocdir = $(datadir)/doc/lolengine-dev/pdf
16endif
17endif
18
19html/doxygen.css html/doxygen.png: stamp-doxygen
20latex/lolengine.pdf: stamp-latex
21
22stamp-doxygen: $(doxygen_DOX)
23if BUILD_DOCUMENTATION
24        doxygen doxygen.cfg 2>&1 | tee doxygen.log
25        touch stamp-doxygen
26endif
27
28stamp-latex: stamp-doxygen
29if BUILD_DOCUMENTATION
30if USE_LATEX
31        rm -f latex/lolengine.tex latex/lolengine.pdf
32        mv latex/refman.tex latex/lolengine.tex
33        sed 's/setlength{/renewcommand{/' latex/lolengine.tex \
34          | sed 's/.*usepackage.*times.*//' > latex/refman.tex
35        cd latex && $(MAKE) $(AM_CFLAGS) refman.pdf || (cat refman.log; exit 1)
36        mv latex/refman.pdf latex/lolengine.pdf
37        touch stamp-latex
38endif
39endif
40
41clean-local:
42        -rm -Rf html latex man
43
44install-data-local:
45if BUILD_DOCUMENTATION
46        mkdir -p $(DESTDIR)$(datadir)/doc
47        $(mkinstalldirs) $(DESTDIR)$(datadir)/doc/lolengine-dev/html
48        cp `find html -name '*.html' -o -name '*.gif' -o -name '*.png'` \
49          $(DESTDIR)$(datadir)/doc/lolengine-dev/html
50        $(mkinstalldirs) $(DESTDIR)$(mandir)/man3
51        for man in $$(find man -name '*.3lol'); do \
52          sed -e 's/man3lol/man3/g' -e "s/fC'\([a-zA-Z0-9]*\)'/fC\"\1\"/g" \
53            $$man >$(DESTDIR)$(mandir)/man3/$${man##*/}; \
54        done
55endif
56        $(mkinstalldirs) $(DESTDIR)$(mandir)/man1
57
58uninstall-local:
59        rm -f $(DESTDIR)$(datadir)/doc/libcucul-dev
60        rmdir $(DESTDIR)$(datadir)/doc 2>/dev/null || true
61
Note: See TracBrowser for help on using the repository browser.