]> git.meshlink.io Git - catta/blob - man/Makefile.am
build-sys: make things more quiet
[catta] / man / Makefile.am
1 # $Id$
2
3 # This file is part of avahi.
4 #
5 # avahi is free software; you can redistribute it and/or modify it
6 # under the terms of the GNU Lesser General Public License as
7 # published by the Free Software Foundation; either version 2 of the
8 # License, or (at your option) any later version.
9 #
10 # avahi is distributed in the hope that it will be useful, but WITHOUT
11 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
12 # or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
13 # License for more details.
14 #
15 # You should have received a copy of the GNU Lesser General Public
16 # License along with avahi; if not, write to the Free Software
17 # Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
18 # USA.
19
20 pkgsysconfdir=$(sysconfdir)/avahi
21 servicedir=$(pkgsysconfdir)/services
22
23 if BUILD_MANPAGES
24
25 man_MANS = \
26         avahi-daemon.8 \
27         avahi-dnsconfd.8 \
28         avahi-daemon.conf.5 \
29         avahi-dnsconfd.action.8 \
30         avahi.service.5 \
31         avahi.hosts.5
32
33 noinst_DATA = \
34         avahi-browse.1.xml \
35         avahi-publish.1.xml \
36         avahi-resolve.1.xml \
37         avahi-set-host-name.1.xml \
38         avahi-daemon.8.xml \
39         avahi-discover.1.xml \
40         avahi-bookmarks.1.xml \
41         avahi-dnsconfd.8.xml \
42         avahi-daemon.conf.5.xml \
43         avahi-dnsconfd.action.8.xml \
44         avahi.service.5.xml \
45         avahi.hosts.5.xml \
46         avahi-autoipd.8.xml \
47         avahi-autoipd.action.8.xml \
48         bssh.1.xml
49
50 CLEANFILES = \
51         $(noinst_DATA)
52
53 if HAVE_DBUS
54
55 man_MANS += \
56         avahi-browse.1 \
57         avahi-resolve.1 \
58         avahi-publish.1 \
59         avahi-set-host-name.1
60
61 if HAVE_GTK
62 man_MANS += \
63         bssh.1
64 endif
65
66 if HAVE_PYTHON
67 man_MANS += \
68         avahi-bookmarks.1
69 if HAVE_GTK
70 man_MANS += \
71         avahi-discover.1
72 endif
73 endif
74 endif
75
76 if ENABLE_AUTOIPD
77 if HAVE_LIBDAEMON
78
79 man_MANS += \
80         avahi-autoipd.8 \
81         avahi-autoipd.action.8
82
83 endif
84 endif
85
86 %.xml: %.xml.in Makefile
87         $(AM_V_GEN) sed -e 's,@pkgsysconfdir\@,$(pkgsysconfdir),g' \
88                 -e 's,@servicedir\@,$(servicedir),g' \
89                 -e 's,@PACKAGE_BUGREPORT\@,$(PACKAGE_BUGREPORT),g' \
90                 -e 's,@PACKAGE_URL\@,$(PACKAGE_URL),g' $< > $@
91
92 if USE_XMLTOMAN
93
94 CLEANFILES += $(man_MANS)
95
96 %.1: %.1.xml Makefile
97         $(AM_V_GEN)xmltoman $< > $@
98
99 %.5: %.5.xml Makefile
100         $(AM_V_GEN)xmltoman $< > $@
101
102 %.8: %.8.xml Makefile
103         $(AM_V_GEN)xmltoman $< > $@
104
105 xmllint: $(noinst_DATA)
106         for f in $(noinst_DATA) ; do \
107                         xmllint --noout --valid "$$f" || exit 1 ; \
108         done
109
110 endif
111
112 endif
113
114 EXTRA_DIST = \
115         $(man_MANS) \
116         avahi-browse.1.xml.in \
117         avahi-publish.1.xml.in \
118         avahi-resolve.1.xml.in \
119         avahi-set-host-name.1.xml.in \
120         avahi-daemon.8.xml.in \
121         avahi-discover.1.xml.in \
122         avahi-bookmarks.1.xml.in \
123         avahi-dnsconfd.8.xml.in \
124         avahi-daemon.conf.5.xml.in \
125         avahi-dnsconfd.action.8.xml.in \
126         avahi.service.5.xml.in \
127         avahi.hosts.5.xml.in \
128         avahi-autoipd.action.8.xml.in \
129         avahi-autoipd.8.xml.in \
130         bssh.1.xml.in \
131         xmltoman.css \
132         xmltoman.xsl \
133         xmltoman.dtd
134
135
136 if HAVE_DBUS
137
138 BSSH_LN =
139 if HAVE_GTK
140 if HAVE_GLIB
141 BSSH_LN += $(LN_S) bssh.1 bvnc.1 &&
142 endif
143 endif
144 install-exec-local:
145         mkdir -p $(DESTDIR)/$(mandir)/man1 && \
146                 cd $(DESTDIR)/$(mandir)/man1 && \
147                 rm -f avahi-resolve-host-name.1 avahi-resolve-address.1 avahi-browse-domains.1 avahi-publish-address.1 avahi-publish-service.1 bvnc.1 && \
148                 $(BSSH_LN) \
149                 $(LN_S) avahi-resolve.1 avahi-resolve-host-name.1 && \
150                 $(LN_S) avahi-resolve.1 avahi-resolve-address.1 && \
151                 $(LN_S) avahi-browse.1 avahi-browse-domains.1 && \
152                 $(LN_S) avahi-publish.1 avahi-publish-address.1 && \
153                 $(LN_S) avahi-publish.1 avahi-publish-service.1
154
155
156 endif