]> Pileus Git - ~andy/gtk/blob - docs/reference/gdk-pixbuf/Makefile.am
0.8 - Federico
[~andy/gtk] / docs / reference / gdk-pixbuf / Makefile.am
1 ## Process this file with automake to produce Makefile.in
2
3 # The name of the module.
4 DOC_MODULE=gdk-pixbuf
5
6 # The top-level SGML file.
7 DOC_MAIN_SGML_FILE=gdk-pixbuf.sgml
8
9 # The directory containing the source code (if it contains documentation).
10 DOC_SOURCE_DIR=$(GDK_PIXBUF_DIR)/gdk-pixbuf
11
12 CFLAGS=`gnome-config --cflags gnomeui gdk_pixbuf gnomecanvaspixbuf`
13 LDFLAGS=`gnome-config --libs gnomeui gdk_pixbuf gnomecanvaspixbuf`
14
15 HTML_DIR=$(datadir)/gnome/html
16
17 TARGET_DIR=$(HTML_DIR)/$(DOC_MODULE)
18
19 tmpl_sources =                                  \
20         tmpl/animation.sgml                     \
21         tmpl/creating.sgml                      \
22         tmpl/file-loading.sgml                  \
23         tmpl/from-drawables.sgml                \
24         tmpl/gdk-pixbuf-loader.sgml             \
25         tmpl/gdk-pixbuf-unused.sgml             \
26         tmpl/gdk-pixbuf.sgml                    \
27         tmpl/gnome-canvas-pixbuf.sgml           \
28         tmpl/refcounting.sgml                   \
29         tmpl/rendering.sgml                     \
30         tmpl/scaling.sgml                       \
31         tmpl/util.sgml
32
33 gdk_pixbuf_docdir = $(HTML_DIR)
34 gdk_pixbuf_doc_DATA =                   \
35         gdk-pixbuf.html                 \
36         gdk-pixbuf.hierarchy            \
37         gdk-pixbuf.types                \
38         gdk-pixbuf-decl.txt             \
39         gdk-pixbuf-sections.txt
40
41 content_files =                         \
42         compiling.sgml                  \
43         gdk-pixbuf.sgml
44
45 EXTRA_DIST =                            \
46         $(gdk_pixbuf_doc_DATA)          \
47         $(content_files)
48
49 if ENABLE_GTK_DOC
50 gdk-pixbuf.html: html/book1.html
51         -cd $(srcdir) && cp html/book1.html gdk-pixbuf.html
52 else
53 gdk-pixbuf.html:
54 endif
55
56 html/book1.html: sgml/gdk-pixbuf-doc.bottom $(content_files)
57         $(MAKE) html
58
59 sgml/gdk-pixbuf-doc.bottom: $(tmpl_sources)
60         $(MAKE) sgml
61
62 scan:
63         -(cd $(srcdir) \
64         && env CFLAGS=$(CFLAGS) LDFLAGS=$(LDFLAGS) \
65                  gtkdoc-scanobj --module=$(DOC_MODULE) \
66         && gtkdoc-scan --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR) --ignore-headers="pixops.h pixops-internal.h" )
67
68 templates: scan
69         cd $(srcdir) && gtkdoc-mktmpl --module=$(DOC_MODULE)
70
71 sgml:
72         cd $(srcdir) \
73         && gtkdoc-mkdb --module=$(DOC_MODULE) --source-dir=$(DOC_SOURCE_DIR)
74
75 html:
76         test -d $(srcdir)/html || mkdir $(srcdir)/html
77         -cd $(srcdir)/html && gtkdoc-mkhtml $(DOC_MODULE) ../$(DOC_MAIN_SGML_FILE)
78
79 clean-local:
80         rm -f *~ *.bak *.signals *-unused.txt
81
82 maintainer-clean-local: clean
83         cd $(srcdir) && rm -rf sgml html $(DOC_MODULE)-decl-list.txt $(DOC_MODULE)-decl.txt
84
85 install-data-local:
86         $(mkinstalldirs) $(DESTDIR)$(TARGET_DIR)
87         (installfiles=`echo $(srcdir)/html/*.html`; \
88         if test "$$installfiles" = '$(srcdir)/html/*.html'; \
89         then echo '-- Nothing to install' ; \
90         else \
91           for i in $$installfiles; do \
92             echo '-- Installing '$$i ; \
93             $(INSTALL_DATA) $$i $(DESTDIR)$(TARGET_DIR); \
94           done; \
95           echo '-- Installing $(srcdir)/html/index.sgml' ; \
96           $(INSTALL_DATA) $(srcdir)/html/index.sgml $(DESTDIR)$(TARGET_DIR); \
97           echo '-- Fixing Crossreferences' ; \
98           gtkdoc-fixxref --module=$(DOC_MODULE) --html-dir=$(HTML_DIR)|| true; \
99         fi)
100
101 dist-hook:
102         mkdir $(distdir)/html
103         mkdir $(distdir)/sgml
104         mkdir $(distdir)/tmpl
105         -cp $(srcdir)/html/*.html $(srcdir)/html/*.css $(distdir)/html
106         -cp $(srcdir)/tmpl/*.sgml $(distdir)/tmpl
107         -cp $(srcdir)/sgml/*.sgml $(distdir)/sgml
108         -cp $(srcdir)/sgml/*.bottom $(srcdir)/sgml/*.top $(distdir)/sgml
109
110 .PHONY : html sgml templates scan