[20866] | 1 | # |
---|
| 2 | # No modifications of this Makefile should be necessary. |
---|
| 3 | # |
---|
[18345] | 4 | # To use this template: |
---|
[20866] | 5 | # 1) Define: figdir, docname, lang, omffile, and entities in |
---|
| 6 | # your Makefile.am file for each document directory, |
---|
| 7 | # although figdir, omffile, and entities may be empty |
---|
| 8 | # 2) Make sure the Makefile in (1) also includes |
---|
| 9 | # "include $(top_srcdir)/xmldocs.make" and |
---|
| 10 | # "dist-hook: app-dist-hook". |
---|
| 11 | # 3) Optionally define 'entities' to hold xml entities which |
---|
| 12 | # you would also like installed |
---|
| 13 | # 4) Figures must go under $(figdir)/ and be in PNG format |
---|
| 14 | # 5) You should only have one document per directory |
---|
| 15 | # 6) Note that the figure directory, $(figdir)/, should not have its |
---|
| 16 | # own Makefile since this Makefile installs those figures. |
---|
[18345] | 17 | # |
---|
[20866] | 18 | # example Makefile.am: |
---|
| 19 | # figdir = figures |
---|
[18345] | 20 | # docname = scrollkeeper-manual |
---|
| 21 | # lang = C |
---|
| 22 | # omffile=scrollkeeper-manual-C.omf |
---|
| 23 | # entities = fdl.xml |
---|
[20866] | 24 | # include $(top_srcdir)/xmldocs.make |
---|
[18345] | 25 | # dist-hook: app-dist-hook |
---|
| 26 | # |
---|
[20866] | 27 | # About this file: |
---|
| 28 | # This file was taken from scrollkeeper_example2, a package illustrating |
---|
| 29 | # how to install documentation and OMF files for use with ScrollKeeper |
---|
| 30 | # 0.3.x and 0.4.x. For more information, see: |
---|
| 31 | # http://scrollkeeper.sourceforge.net/ |
---|
| 32 | # Version: 0.1.2 (last updated: March 20, 2002) |
---|
| 33 | # |
---|
[18345] | 34 | |
---|
[20866] | 35 | |
---|
| 36 | # ********** Begin of section some packagers may need to modify ********** |
---|
| 37 | # This variable (docdir) specifies where the documents should be installed. |
---|
| 38 | # This default value should work for most packages. |
---|
[18345] | 39 | docdir = $(datadir)/gnome/help/$(docname)/$(lang) |
---|
| 40 | |
---|
[20866] | 41 | # ********** You should not have to edit below this line ********** |
---|
[18345] | 42 | xml_files = $(entities) $(docname).xml |
---|
| 43 | |
---|
[20866] | 44 | EXTRA_DIST = $(xml_files) $(omffile) |
---|
| 45 | CLEANFILES = omf_timestamp |
---|
[18345] | 46 | |
---|
[20866] | 47 | include $(top_srcdir)/omf.make |
---|
[18345] | 48 | |
---|
| 49 | all: omf |
---|
| 50 | |
---|
| 51 | $(docname).xml: $(entities) |
---|
| 52 | -ourdir=`pwd`; \ |
---|
| 53 | cd $(srcdir); \ |
---|
| 54 | cp $(entities) $$ourdir |
---|
| 55 | |
---|
[20866] | 56 | app-dist-hook: |
---|
| 57 | if test "$(figdir)"; then \ |
---|
| 58 | $(mkinstalldirs) $(distdir)/$(figdir); \ |
---|
| 59 | for file in $(srcdir)/$(figdir)/*.png; do \ |
---|
| 60 | basefile=`echo $$file | sed -e 's,^.*/,,'`; \ |
---|
| 61 | $(INSTALL_DATA) $$file $(distdir)/$(figdir)/$$basefile; \ |
---|
| 62 | done \ |
---|
| 63 | fi |
---|
[18345] | 64 | |
---|
[20866] | 65 | install-data-local: omf |
---|
| 66 | $(mkinstalldirs) $(DESTDIR)$(docdir) |
---|
| 67 | for file in $(xml_files); do \ |
---|
| 68 | cp $(srcdir)/$$file $(DESTDIR)$(docdir); \ |
---|
[18345] | 69 | done |
---|
[20866] | 70 | if test "$(figdir)"; then \ |
---|
| 71 | $(mkinstalldirs) $(DESTDIR)$(docdir)/$(figdir); \ |
---|
| 72 | for file in $(srcdir)/$(figdir)/*.png; do \ |
---|
| 73 | basefile=`echo $$file | sed -e 's,^.*/,,'`; \ |
---|
| 74 | $(INSTALL_DATA) $$file $(DESTDIR)$(docdir)/$(figdir)/$$basefile; \ |
---|
| 75 | done \ |
---|
| 76 | fi |
---|
[18345] | 77 | |
---|
[20866] | 78 | install-data-hook: install-data-hook-omf |
---|
| 79 | |
---|
| 80 | uninstall-local: uninstall-local-doc uninstall-local-omf |
---|
| 81 | |
---|
| 82 | uninstall-local-doc: |
---|
| 83 | -if test "$(figdir)"; then \ |
---|
| 84 | for file in $(srcdir)/$(figdir)/*.png; do \ |
---|
| 85 | basefile=`echo $$file | sed -e 's,^.*/,,'`; \ |
---|
| 86 | rm -f $(DESTDIR)$(docdir)/$(figdir)/$$basefile; \ |
---|
| 87 | done; \ |
---|
| 88 | rmdir $(DESTDIR)$(docdir)/$(figdir); \ |
---|
| 89 | fi |
---|
[18345] | 90 | -for file in $(xml_files); do \ |
---|
| 91 | rm -f $(DESTDIR)$(docdir)/$$file; \ |
---|
| 92 | done |
---|
| 93 | -rmdir $(DESTDIR)$(docdir) |
---|
[20866] | 94 | |
---|
| 95 | clean-local: clean-local-omf |
---|