1 abs_top_srcdir = @abs_top_srcdir@
2 abs_top_builddir = @abs_top_builddir@
4 ACLOCAL_AMFLAGS = -I m4
6 # the api, doc, include subdirs don't need their own Makefile.am
7 SUBDIRS = _dbus_bindings _dbus_glib_bindings dbus examples m4 test tools
17 # miss out the gconf examples for now - they don't work
19 pkgconfigdir = $(libdir)/pkgconfig
20 pkgconfig_DATA = dbus-python.pc
22 dbusincludedir = $(includedir)/dbus-1.0/dbus
23 dbusinclude_HEADERS = include/dbus-python.h
25 python_PYTHON = dbus_bindings.py
29 cross-test-compile: all
31 @$(MAKE) -C test cross-test-server
33 @$(MAKE) -C test cross-test-client
35 # === Documentation ===
38 chmod u+w $(distdir)/ChangeLog
39 if test -d $(top_srcdir)/.git; then \
40 if git-log --stat > $(distdir)/ChangeLog; then \
43 git-log > $(distdir)/ChangeLog; \
47 TXT_RSTDOCS = doc/tutorial.txt doc/API_CHANGES.txt doc/HACKING.txt
48 RSTDOCS = README NEWS TODO
49 dist_doc_DATA = $(TXT_RSTDOCS) $(RSTDOCS)
51 maintainer-update-website: _maintainer-update-apidocs \
52 _maintainer-update-htmldocs
55 _maintainer-update-htmldocs: $(HTML_TXT_RSTDOCS) $(HTML_RSTDOCS)
56 rsync -rtvzPp --chmod=Dg+s,ug+rwX,o=rX doc \
57 $(RSTDOCS) $(HTML_RSTDOCS) \
58 dbus.freedesktop.org:/srv/dbus.freedesktop.org/www/doc/dbus-python/
60 HTML_TXT_RSTDOCS = doc/tutorial.html doc/API_CHANGES.html doc/HACKING.html
61 HTML_RSTDOCS = README.html NEWS.html TODO.html
62 nodist_doc_DATA = $(HTML_TXT_RSTDOCS) $(HTML_RSTDOCS)
64 CLEANFILES += $(nodist_doc_DATA)
66 $(HTML_TXT_RSTDOCS) : %.html: %.txt
68 $(RST2HTML) $(RST2HTMLFLAGS) $< $@
69 $(HTML_RSTDOCS) : %.html: %
70 $(RST2HTML) $(RST2HTMLFLAGS) $< $@
72 _maintainer-update-htmldocs:
73 @echo "*** Not updating the HTML docs on the website - install rst2html"
74 @echo "*** from http://docutils.sourceforge.net/ and configure with "
75 @echo "*** --enable-html-docs"
84 dbus/.doc-needs-rebuild-stamp:
86 _dbus_bindings/_dbus_bindings.la:
87 $(MAKE) -C _dbus_bindings
88 _dbus_glib_bindings/_dbus_glib_bindings.la:
89 $(MAKE) -C _dbus_glib_bindings
91 APIDOC_PYTHONPATH = $(abs_top_srcdir):$(abs_top_builddir)/_dbus_bindings/.libs:$(abs_top_builddir)/_dbus_glib_bindings/.libs
93 api api/index.html: $(python_PYTHON) dbus/.doc-needs-rebuild-stamp \
94 _dbus_bindings/_dbus_bindings.la \
95 _dbus_glib_bindings/_dbus_glib_bindings.la
98 PYTHONPATH=$(APIDOC_PYTHONPATH) DBUS_PYTHON_NO_DEPRECATED=1 $(PYTHON) -Wignore::DeprecationWarning $(EPYDOC) -o api --html \
99 --docformat restructuredtext -v \
100 `find dbus -name '*.py' | grep -v dbus_bindings \
101 | sed -e 's#/__init__\.py##g' \
102 -e 's/\.py\>//g' -e 's#/#.#'g` \
103 || { rm -rf api; exit 1; }
105 _maintainer-update-apidocs: api
106 rsync -rtvzPp --chmod=Dg+s,ug+rwX,o=rX api/ \
107 dbus.freedesktop.org:/srv/dbus.freedesktop.org/www/doc/dbus-python/api/
109 _maintainer-update-apidocs:
110 @echo "*** Not updating the API docs on the website - install epydoc 3"
111 @echo "*** alpha (or newer) and configure with --enable-api-docs"
114 .PHONY: cross-test-compile cross-test-server cross-test-client \
115 always-rebuild maintainer-update-website \
116 _maintainer-update-apidocs _maintainer-update-htmldocs