source: libcaca/trunk/doc/Makefile.am @ 3118

Last change on this file since 3118 was 3118, checked in by Sam Hocevar, 12 years ago

doc: fix symlink failure when installing libcaca twice.

  • Property svn:keywords set to Id
File size: 1.9 KB
RevLine 
[342]1# $Id: Makefile.am 3118 2008-10-27 13:45:56Z sam $
[341]2
[1986]3EXTRA_DIST = doxygen.cfg.in doxygen.css footer.html header.html \
4             $(man_MANS) $(doxygen_DOX)
[207]5
[1357]6doxygen_DOX = libcaca.dox user.dox migrating.dox tutorial.dox canvas.dox font.dox style.dox
[1916]7man_MANS = caca-config.1 cacafire.1 cacaview.1 cacaserver.1 img2txt.1 cacaplay.1
[207]8
[346]9if BUILD_DOCUMENTATION
[296]10htmldoc_DATA = html/doxygen.css
[2821]11htmldocdir = $(datadir)/doc/libcaca-dev/html
[346]12if USE_LATEX
[772]13pdfdoc_DATA = latex/libcaca.pdf
[2821]14pdfdocdir = $(datadir)/doc/libcaca-dev/pdf
[270]15endif
16endif
[207]17
[270]18html/doxygen.css html/doxygen.png: stamp-doxygen
[772]19latex/libcaca.pdf: stamp-latex
[270]20
[847]21stamp-doxygen: $(doxygen_DOX)
[346]22if BUILD_DOCUMENTATION
[207]23        doxygen doxygen.cfg
24        touch stamp-doxygen
25endif
26
27stamp-latex: stamp-doxygen
[346]28if BUILD_DOCUMENTATION
29if USE_LATEX
[772]30        rm -f latex/libcaca.tex latex/libcaca.pdf
[313]31        mv latex/refman.tex latex/libcaca.tex
32        sed 's/setlength{/renewcommand{/' latex/libcaca.tex > latex/refman.tex
[1835]33        cd latex && $(MAKE) $(AM_CFLAGS) refman.pdf || (cat refman.log; exit 1)
[772]34        mv latex/refman.pdf latex/libcaca.pdf
[207]35        touch stamp-latex
36endif
37endif
38
39clean: clean-local
40clean-local:
[268]41        -rm -Rf html latex man
[207]42        -rm -f stamp-latex stamp-doxygen
43
[270]44install-data-local:
[346]45if BUILD_DOCUMENTATION
[2835]46        mkdir -p $(DESTDIR)$(datadir)/doc
[3118]47        ln -sf libcaca-dev $(DESTDIR)$(datadir)/doc/libcucul-dev
[2821]48        $(mkinstalldirs) $(DESTDIR)$(datadir)/doc/libcaca-dev/html
[297]49        cp `find html -name '*.html' -o -name '*.gif' -o -name '*.png'` \
[2821]50          $(DESTDIR)$(datadir)/doc/libcaca-dev/html
[270]51        $(mkinstalldirs) $(DESTDIR)$(mandir)/man3
[1020]52        for man in $$(find man -name '*.3caca'); do \
[1103]53          sed -e 's/man3caca/man3/g' -e "s/fC'\([a-zA-Z0-9]*\)'/fC\"\1\"/g" \
54            $$man >$(DESTDIR)$(mandir)/man3/$${man##*/}; \
[1020]55        done
[310]56        $(mkinstalldirs) $(DESTDIR)$(mandir)/man1
[1093]57        rm -f $(DESTDIR)$(mandir)/man1/cacademo.1
[3118]58        ln -sf cacafire.1 $(DESTDIR)$(mandir)/man1/cacademo.1
[270]59endif
60
[2831]61uninstall-local:
62        rm -f $(DESTDIR)$(datadir)/doc/libcucul-dev
[2835]63        rmdir $(DESTDIR)$(datadir)/doc 2>/dev/null || true
[2831]64
Note: See TracBrowser for help on using the repository browser.