1 # === Miscellaneous ===
4 EXTRA_DIST = API_CHANGES.txt dbus-python.pc.in HACKING.txt \
5 AUTHORS COPYING NEWS ChangeLog TODO \
7 examples/example-async-client.py \
8 examples/example-client.py \
9 examples/example-service.py \
10 examples/example-signal-emitter.py \
11 examples/example-signal-recipient.py \
12 examples/list-system-services.py \
13 test/cross-test-client.py \
14 test/cross-test-server.py \
17 test/run-with-tmp-session-bus.sh \
19 test/test-service.py \
20 test/test-signals.py \
21 test/test-standalone.py \
22 test/TestSuitePythonService.service.in \
23 test/tmp-session-bus.conf.in
24 # miss out the gconf examples for now - they don't work
26 pkgconfigdir = $(libdir)/pkgconfig
27 pkgconfig_DATA = dbus-python.pc
29 include_HEADERS = include/dbus-python.h
33 nobase_python_PYTHON = dbus_bindings.py \
34 dbus/dbus_bindings.py \
38 dbus/_expat_introspect_parser.py \
42 dbus/mainloop/__init__.py \
43 dbus/mainloop/glib.py \
48 # === Python C extensions ===
50 pyexec_LTLIBRARIES = _dbus_bindings.la _dbus_glib_bindings.la
51 _dbus_bindings_la_CPPFLAGS = -I$(srcdir)/include \
54 _dbus_bindings_la_LDFLAGS = -module -avoid-version \
55 -export-symbols-regex init_dbus_bindings \
57 _dbus_bindings_la_SOURCES = \
58 _dbus_bindings/abstract.c \
59 _dbus_bindings/bus.c \
60 _dbus_bindings/bytes.c \
61 _dbus_bindings/conn.c \
62 _dbus_bindings/conn-internal.h \
63 _dbus_bindings/conn-methods.c \
64 _dbus_bindings/containers.c \
65 _dbus_bindings/dbus_bindings-internal.h \
66 _dbus_bindings/debug.c \
67 _dbus_bindings/exceptions.c \
68 _dbus_bindings/float.c \
69 _dbus_bindings/generic.c \
70 _dbus_bindings/int.c \
71 _dbus_bindings/mainloop.c \
72 _dbus_bindings/message-append.c \
73 _dbus_bindings/message.c \
74 _dbus_bindings/message-get-args.c \
75 _dbus_bindings/message-internal.h \
76 _dbus_bindings/module.c \
77 _dbus_bindings/pending-call.c \
78 _dbus_bindings/signature.c \
79 _dbus_bindings/string.c \
80 _dbus_bindings/types-internal.h \
81 _dbus_bindings/validation.c \
84 _dbus_glib_bindings_la_CPPFLAGS = -I$(top_srcdir)/include \
88 _dbus_glib_bindings_la_LDFLAGS = -module -avoid-version \
89 -export-symbols-regex init_dbus_glib_bindings \
90 $(DBUS_LIBS) $(DBUS_GLIB_LIBS)
91 _dbus_glib_bindings_la_SOURCES = _dbus_glib_bindings/module.c \
97 TESTS_ENVIRONMENT = DBUS_TOP_SRCDIR="$(PWD)/$(top_srcdir)" \
98 DBUS_TOP_BUILDDIR="$(PWD)" \
99 DBUS_PYTHON_VERSION='$(PACKAGE_VERSION)' \
100 PYTHONPATH="$(PWD)/.libs:$(PWD)/$(top_srcdir):$(PWD)/$(top_srcdir)/test" \
102 TESTS = test/run-test.sh
104 cross-test-compile: all
106 $(TESTS_ENVIRONMENT) $(PYTHON) $(top_srcdir)/test/cross-test-server.py
108 $(TESTS_ENVIRONMENT) $(PYTHON) $(top_srcdir)/test/cross-test-client.py
110 # === Documentation ===
112 ChangeLog: always-rebuild
113 @if test -d $(top_srcdir)/.git; then \
114 if git-log --stat > ChangeLog; then \
117 git-log > Changelog || exit 1; \
121 TXT_RSTDOCS = doc/tutorial.txt API_CHANGES.txt HACKING.txt
122 RSTDOCS = README NEWS TODO
123 dist_doc_DATA = $(TXT_RSTDOCS) $(RSTDOCS)
126 HTML_TXT_RSTDOCS = doc/tutorial.html API_CHANGES.html HACKING.html
127 HTML_RSTDOCS = README.html NEWS.html TODO.html
128 nodist_doc_DATA = $(HTML_TXT_RSTDOCS) $(HTML_RSTDOCS)
130 CLEANFILES += $(nodist_doc_DATA)
132 RST2HTMLFLAGS = --generator --date --time --exit-status=2 \
133 --cloak-email-addresses --no-raw --no-file-insertion
135 $(HTML_TXT_RSTDOCS) : %.html: %.txt
136 $(RST2HTML) $(RST2HTMLFLAGS) $< $@
137 $(HTML_RSTDOCS) : %.html: %
138 $(RST2HTML) $(RST2HTMLFLAGS) $< $@
147 api api/index.html: $(nobase_python_PYTHON) _dbus_bindings.la _dbus_glib_bindings.la
150 $(TESTS_ENVIRONMENT) $(EPYDOC) -o api --html \
151 --docformat restructuredtext -v \
152 `echo $(nobase_python_PYTHON) \
153 | sed -e 's#/__init__\.py##g' \
154 -e 's/\.py\>//g' -e 's#/#.#'g` \
155 || { rm -rf api; exit 1; }
158 .PHONY: cross-test-compile cross-test-server cross-test-client always-rebuild