]> git.lyx.org Git - lyx.git/blob - lib/doc/Makefile.am
547fd222079a1b73f9d2d1ddcacca94ba5952108
[lyx.git] / lib / doc / Makefile.am
1 include $(top_srcdir)/config/common.am
2
3 DISTCLEANFILES += $(tocfiles)
4
5 EXTRA_DIST = depend.py doc_toc.py README.Documentation $(DEPENDFILE) $(docfiles)
6
7 docfiles = \
8         cs_Tutorial.lyx \
9         Customization.lyx \
10         da_Intro.lyx \
11         de_Customization.lyx \
12         de_Extended.lyx \
13         de_FAQ.lyx \
14         de_Intro.lyx \
15         de_Tutorial.lyx \
16         de_UserGuide.lyx \
17         DocStyle.lyx \
18         es_Intro.lyx \
19         es_Tutorial.lyx \
20         es_EmbeddedObjects.lyx \
21         eu_Customization.lyx \
22         eu_Extended.lyx \
23         eu_FAQ.lyx \
24         eu_Intro.lyx \
25         eu_Tutorial.lyx \
26         eu_UserGuide.lyx \
27         EmbeddedObjects.lyx \
28         Extended.lyx \
29         FAQ.lyx \
30         fr_Customization.lyx \
31         fr_Extended.lyx \
32         fr_FAQ.lyx \
33         fr_Intro.lyx \
34         fr_Tutorial.lyx \
35         fr_UserGuide.lyx \
36         gl_Intro.lyx \
37         gl_Tutorial.lyx \
38         he_Intro.lyx \
39         he_Tutorial.lyx \
40         hu_Intro.lyx \
41         hu_Tutorial.lyx \
42         Intro.lyx \
43         it_Customization.lyx \
44         it_Intro.lyx \
45         it_Tutorial.lyx \
46         it_UserGuide.lyx \
47         LaTeXConfig.lyx.in \
48         nl_Intro.lyx \
49         nl_Tutorial.lyx \
50         nb_Intro.lyx \
51         pl_Extended.lyx \
52         pl_Intro.lyx \
53         pl_Tutorial.lyx \
54         pt_Intro.lyx \
55         pt_Tutorial.lyx \
56         Reference.lyx \
57         ro_Intro.lyx \
58         ru_FAQ.lyx \
59         ru_Intro.lyx \
60         ru_Tutorial.lyx \
61         sk_Tutorial.lyx \
62         sk_UserGuide.lyx \
63         sl_Intro.lyx \
64         sl_Tutorial.lyx \
65         sv_Intro.lyx \
66         sv_Tutorial.lyx \
67         Tutorial.lyx \
68         UserGuide.lyx \
69         escher-lsd.eps \
70         mobius.eps \
71         platypus.eps
72
73 docdir = $(pkgdatadir)/doc
74 doc_DATA = $(docfiles) 
75
76 DEPENDFILE = $(srcdir)/Makefile.depend
77 # include $(DEPENDFILE) does not work because automake is too limited.
78 include $(srcdir)/Makefile.depend
79
80 TOCs : $(DEPENDFILE) $(tocfiles)
81         @echo Made TOCs succesfully.
82
83 # Force regeneration of $(DEPENDFILE) when Makefile.am changes because
84 # new doc files might have been added
85 $(DEPENDFILE): $(srcdir)/Makefile.am $(srcdir)/depend.py
86         python $(srcdir)/depend.py > $(DEPENDFILE)
87
88 # The TOCs are not built for the install and dist targets if they don't exist
89 # for some weird reason.
90 # Make complains although we have rules for them in $(DEPENDFILE), so we
91 # must not include the TOCs in $(docfiles) and have to use the install and
92 # dist hooks below.
93 dist-hook: $(tocfiles)
94         for i in $(tocfiles); \
95         do \
96                 if test -f "$(srcdir)/$$i"; then file="$(srcdir)/$$i"; \
97                 else file="$$i"; fi; \
98                 cp -p "$$file" "$(distdir)"; \
99         done
100 install-data-hook: $(tocfiles)
101         for i in $(tocfiles); \
102         do \
103                 if test -f "$(srcdir)/$$i"; then file="$(srcdir)/$$i"; \
104                 else file="$$i"; fi; \
105                 $(docDATA_INSTALL) "$$file" "$(DESTDIR)$(docdir)/$$i"; \
106         done
107
108 uninstall-local:
109         for i in $(tocfiles); \
110         do \
111                 $(RM) "$(DESTDIR)$(docdir)/$$i" ; \
112         done
113
114 .PHONY: TOCs