1# This file is part of avahi.
2#
3# avahi is free software; you can redistribute it and/or modify it
4# under the terms of the GNU Lesser General Public License as
5# published by the Free Software Foundation; either version 2 of the
6# License, or (at your option) any later version.
7#
8# avahi is distributed in the hope that it will be useful, but WITHOUT
9# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
10# or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public
11# License for more details.
12#
13# You should have received a copy of the GNU Lesser General Public
14# License along with avahi; if not, write to the Free Software
15# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
16# USA.
17
18ACLOCAL_AMFLAGS = -I common
19
20include $(srcdir)/common/doxygen.mk
21
22EXTRA_DIST = \
23	autogen.sh \
24	bootstrap.sh \
25	LICENSE \
26	$(DX_CONFIG) \
27	docs/INSTALL \
28	docs/TODO \
29	docs/NEWS \
30	docs/README \
31	docs/DBUS-API \
32	docs/AUTHORS \
33	docs/HACKING \
34	docs/API-CHANGES-0.6 \
35	docs/COMPAT-LAYERS \
36	docs/MALLOC \
37	docs/overview.dia \
38	docs/server-states.dia \
39	docs/avahi-poll.dia \
40	avahi-core.pc.in \
41	avahi-client.pc.in \
42	avahi-glib.pc.in \
43	avahi-gobject.pc.in \
44	avahi-qt3.pc.in \
45	avahi-qt4.pc.in \
46	avahi-sharp.pc.in \
47	avahi-ui-sharp.pc.in \
48	avahi-compat-libdns_sd.pc.in \
49	avahi-compat-howl.pc.in \
50	avahi-ui.pc.in \
51	avahi-ui-gtk3.pc.in \
52	doxygen_to_devhelp.xsl \
53        common/introspection.m4
54
55SUBDIRS = \
56	common \
57	avahi-common \
58	avahi-core \
59	avahi-qt \
60	avahi-client \
61	avahi-glib \
62	avahi-gobject \
63	avahi-discover-standalone \
64	avahi-daemon \
65	avahi-sharp \
66	initscript \
67	avahi-dnsconfd \
68	avahi-utils \
69	avahi-python \
70	examples \
71	man \
72	tests \
73	service-type-database \
74	avahi-compat-libdns_sd \
75	avahi-compat-howl \
76	avahi-autoipd \
77	avahi-ui \
78	avahi-ui-sharp \
79	po
80
81DX_INPUT = \
82	$(srcdir)/avahi-common/address.h \
83	$(srcdir)/avahi-common/avahi-malloc.h \
84	$(srcdir)/avahi-common/strlst.h \
85	$(srcdir)/avahi-common/alternative.h \
86	$(srcdir)/avahi-common/defs.h \
87	$(srcdir)/avahi-common/error.h \
88	$(srcdir)/avahi-common/domain.h \
89	$(srcdir)/avahi-common/watch.h \
90	$(srcdir)/avahi-common/simple-watch.h \
91	$(srcdir)/avahi-common/thread-watch.h
92
93DX_EXAMPLE_PATH = $(srcdir)/examples
94DX_EXAMPLE_PATTERNS = *.c
95
96if HAVE_QT3
97DX_INPUT += \
98	$(srcdir)/avahi-qt/qt-watch.h
99else
100if HAVE_QT4
101DX_INPUT += \
102	$(srcdir)/avahi-qt/qt-watch.h
103endif
104endif
105
106if HAVE_GLIB
107DX_INPUT += \
108	$(srcdir)/avahi-glib/glib-watch.h \
109	$(srcdir)/avahi-glib/glib-malloc.h
110
111if HAVE_GOBJECT
112if HAVE_DBUS
113DX_INPUT += \
114	$(srcdir)/avahi-gobject/ga-client.h \
115	$(srcdir)/avahi-gobject/ga-entry-group.h \
116	$(srcdir)/avahi-gobject/ga-enums.h \
117	$(srcdir)/avahi-gobject/ga-error.h \
118	$(srcdir)/avahi-gobject/ga-record-browser.h \
119	$(srcdir)/avahi-gobject/ga-service-browser.h \
120	$(srcdir)/avahi-gobject/ga-service-resolver.h
121endif
122endif
123endif
124
125if HAVE_DBUS
126DX_INPUT += \
127	$(srcdir)/avahi-client/client.h \
128	$(srcdir)/avahi-client/lookup.h \
129	$(srcdir)/avahi-client/publish.h
130endif
131
132if HAVE_DBUS
133if HAVE_GTK
134DX_INPUT += \
135	$(srcdir)/avahi-ui/avahi-ui.h
136endif
137endif
138
139if ENABLE_CORE_DOCS
140DX_INPUT += \
141	$(srcdir)/avahi-core/core.h \
142	$(srcdir)/avahi-core/lookup.h \
143	$(srcdir)/avahi-core/publish.h \
144	$(srcdir)/avahi-core/rr.h \
145	$(srcdir)/avahi-core/log.h
146endif
147
148if HAVE_GTK
149DX_INPUT += \
150	$(srcdir)/avahi-ui/avahi-ui.h
151endif
152
153pkgconfigdir = $(libdir)/pkgconfig
154
155%.pc: %.pc.in
156	$(AM_V_GEN)sed -e 's,@prefix\@,$(prefix),g' \
157	    -e 's,@libdir\@,$(libdir),g' \
158	    -e 's,@HOWL_COMPAT_VERSION\@,$(HOWL_COMPAT_VERSION),g' \
159	    -e 's,@PACKAGE_VERSION\@,$(PACKAGE_VERSION),g' $< > $@
160
161pkgconfig_DATA = avahi-core.pc
162CLEANFILES = avahi-core.pc
163
164if HAVE_DBUS
165pkgconfig_DATA += avahi-client.pc
166CLEANFILES += avahi-client.pc
167
168if ENABLE_COMPAT_HOWL
169pkgconfig_DATA += avahi-compat-howl.pc
170CLEANFILES += avahi-compat-howl.pc
171endif
172
173if ENABLE_COMPAT_LIBDNS_SD
174pkgconfig_DATA += avahi-compat-libdns_sd.pc
175CLEANFILES += avahi-compat-libdns_sd.pc
176endif
177
178if HAVE_MONO
179pkgconfig_DATA += avahi-sharp.pc avahi-ui-sharp.pc
180CLEANFILES += avahi-sharp.pc avahi-ui-sharp.pc
181endif
182
183endif
184
185if HAVE_GLIB
186pkgconfig_DATA += avahi-glib.pc
187CLEANFILES += avahi-glib.pc
188
189if HAVE_GOBJECT
190pkgconfig_DATA += avahi-gobject.pc
191CLEANFILES += avahi-gobject.pc
192endif
193endif
194
195if HAVE_GTK
196if HAVE_DBUS
197pkgconfig_DATA += avahi-ui.pc
198CLEANFILES += avahi-ui.pc
199endif
200endif
201
202if HAVE_GTK3
203if HAVE_DBUS
204pkgconfig_DATA += avahi-ui-gtk3.pc
205CLEANFILES += avahi-ui-gtk3.pc
206endif
207endif
208
209if HAVE_QT3
210pkgconfig_DATA += avahi-qt3.pc
211CLEANFILES += avahi-qt3.pc
212endif
213
214if HAVE_QT4
215pkgconfig_DATA += avahi-qt4.pc
216CLEANFILES += avahi-qt4.pc
217endif
218
219CLEANFILES += avahi.devhelp
220
221avahi.devhelp: doxygen-run
222	xsltproc -o $@ doxygen_to_devhelp.xsl doxygen/xml/index.xml
223
224MOSTLYCLEANFILES = $(DX_CLEANFILES)
225
226DISTCHECK_CONFIGURE_FLAGS = \
227	--disable-monodoc \
228	--enable-introspection \
229	--with-systemdsystemunitdir=$$dc_install_base/$(systemdsystemunitdir)
230
231homepage:
232	$(MAKE) -C man
233	scp avahi-daemon/*.xml avahi-daemon/introspect.dtd avahi-daemon/introspect.xsl\
234	    man/*.xml man/xmltoman.dtd man/xmltoman.xsl \
235	    tango:www/avahi.org/tree/download/
236	scp avahi-$(PACKAGE_VERSION).tar.gz tango:www/avahi.org/tree/download/
237	rm -rf doxygen
238	$(MAKE) doxygen-run
239	ssh tango rm -rf www/avahi.org/tree/download/doxygen
240	scp -r doxygen/html tango:www/avahi.org/tree/download/doxygen
241
242DISTCLEANFILES = \
243	po/.intltool-merge-cache
244