2 check_LTLIBRARIES = libgimarshallingtests.la
3 test_typelibs = GIMarshallingTests-1.0.typelib
5 nodist_libgimarshallingtests_la_SOURCES = $(GI_DATADIR)/tests/gimarshallingtests.c $(GI_DATADIR)/tests/gimarshallingtests.h
6 libgimarshallingtests_la_CFLAGS = $(GLIB_CFLAGS)
7 libgimarshallingtests_la_LDFLAGS = -module -avoid-version $(GLIB_LIBS)
9 # This is a hack to make sure a shared library is built
10 libgimarshallingtests.la: $(libgimarshallingtests_la_OBJECTS) $(libgimarshallingtests_la_DEPENDENCIES)
11 $(AM_V_GEN) $(LINK) -rpath $(pkgpyexecdir) $(libgimarshallingtests_la_LDFLAGS) $(libgimarshallingtests_la_OBJECTS) $(libgimarhallingtests_la_LIBADD) $(LIBS)
13 GIMarshallingTests-1.0.gir: libgimarshallingtests.la Makefile
14 $(AM_V_GEN) g-ir-scanner --include=Gio-2.0 \
15 --namespace=GIMarshallingTests --nsversion=1.0 --symbol-prefix=gi_marshalling_tests \
16 --warn-all --warn-error \
17 --library=libgimarshallingtests.la \
18 --libtool="$(top_builddir)/libtool" \
20 $(nodist_libgimarshallingtests_la_SOURCES)
21 GIMarshallingTests-1.0.typelib: GIMarshallingTests-1.0.gir Makefile
22 $(AM_V_GEN) g-ir-compiler $< -o $@
24 # regress.c needs cairo
26 check_LTLIBRARIES += libregress.la
27 test_typelibs += Regress-1.0.typelib
28 nodist_libregress_la_SOURCES = $(GI_DATADIR)/tests/regress.c $(GI_DATADIR)/tests/regress.h
29 libregress_la_CFLAGS = $(GIO_CFLAGS) $(CAIRO_CFLAGS)
30 libregress_la_LDFLAGS = -module -avoid-version $(GIO_LIBS) $(CAIRO_LIBS)
32 libregress.la: $(libregress_la_OBJECTS) $(libregress_la_DEPENDENCIES)
33 $(AM_V_GEN) $(LINK) -rpath $(pkgpyexecdir) $(libregress_la_LDFLAGS) $(libregress_la_OBJECTS) $(libregress_la_LIBADD) $(LIBS)
35 # g-i doesn't ship these as shared libraries anymore; we build them here
36 Regress-1.0.gir: libregress.la Makefile
37 $(AM_V_GEN) g-ir-scanner --include=cairo-1.0 --include=Gio-2.0 \
38 --namespace=Regress --nsversion=1.0 \
39 --warn-all --warn-error \
40 --library=libregress.la \
41 --libtool="$(top_builddir)/libtool" \
43 $(nodist_libregress_la_SOURCES)
44 Regress-1.0.typelib: Regress-1.0.gir Makefile
45 $(AM_V_GEN) g-ir-compiler $< -o $@
50 gschemas.compiled: org.gnome.test.gschema.xml
51 glib-compile-schemas --targetdir=. --schema-file=$<
53 CLEANFILES += Regress-1.0.gir Regress-1.0.typelib GIMarshallingTests-1.0.gir GIMarshallingTests-1.0.typelib gschemas.compiled
55 check_LTLIBRARIES += testhelper.la
57 testhelper_la_CFLAGS = -I$(top_srcdir)/gi/_gobject -I$(top_srcdir)/gi/_glib $(PYTHON_INCLUDES) $(GLIB_CFLAGS)
58 testhelper_la_LDFLAGS = -module -avoid-version
59 testhelper_la_LIBADD = $(GLIB_LIBS)
60 testhelper_la_SOURCES = \
66 # This is a hack to make sure a shared library is built
67 testhelper.la: $(testhelper_la_OBJECTS) $(testhelper_la_DEPENDENCIES)
68 $(AM_V_GEN) $(LINK) -rpath $(pkgpyexecdir) $(testhelper_la_LDFLAGS) $(testhelper_la_OBJECTS) $(testhelper_la_LIBADD) $(LIBS)
72 test -L $@ || $(LN_S) .libs/$@ $@
75 all: $(check_LTLIBRARIES:.la=.so)
86 org.gnome.test.gschema.xml \
92 test_internal_api.py \
95 test_object_marshaling.py \
106 test_overrides_glib.py \
107 test_overrides_pango.py \
108 test_overrides_gdk.py \
109 test_overrides_gtk.py \
111 test_generictreemodel.py \
114 compat_test_pygtk.py \
116 gi/overrides/__init__.py \
117 gi/overrides/Regress.py \
121 rm -f $(check_LTLIBRARIES:.la=.so) file.txt~
123 DBUS_LAUNCH=$(shell which dbus-launch)
124 RUN_TESTS_ENV_VARS= \
125 PYTHONPATH=$(top_builddir):$(top_builddir)/tests:$${PYTHONPATH:+:$$PYTHONPATH} \
126 LD_LIBRARY_PATH=$(builddir)/.libs:$$LD_LIBRARY_PATH \
127 GI_TYPELIB_PATH=$(builddir):$$GI_TYPELIB_PATH \
128 XDG_DATA_DIRS=$$XDG_DATA_DIRS:/usr/share \
131 G_SLICE=debug-blocks \
132 TESTS_BUILDDIR=$(builddir)
134 # pygtkcompat tests need to be run in a separate process as they
135 # clobber global name space
136 check-local: $(check_LTLIBRARIES:.la=.so) $(test_typelibs) gschemas.compiled
137 @echo " CHECK Pyflakes"
138 @if type pyflakes >/dev/null 2>&1; then pyflakes $(top_srcdir); else echo "skipped, pyflakes not installed"; fi
139 @if test -z "$$SKIP_PEP8"; then \
140 echo " CHECK PEP8"; \
141 if type pep8 >/dev/null 2>&1; then pep8 --ignore=E501,E123,E124 --repeat --show-source $(top_srcdir); else echo "skipped, pep8 not installed"; fi; \
143 export `$(DBUS_LAUNCH)` && \
144 $(RUN_TESTS_ENV_VARS) $(EXEC_NAME) $(PYTHON) -Wd $(srcdir)/runtests.py; rc=$$?; \
145 [ "$$rc" -ne 0 ] || [ -n "$$TEST_NAMES" ] || { TEST_NAMES=compat_test_pygtk $(RUN_TESTS_ENV_VARS) $(EXEC_NAME) $(PYTHON) -Wd -Werror::PendingDeprecationWarning -Werror::DeprecationWarning -Werror::RuntimeWarning $(srcdir)/runtests.py; rc=$$?; }; \
146 kill $$DBUS_SESSION_BUS_PID; \
150 EXEC_NAME="gdb --args" $(MAKE) check
153 EXEC_NAME="nemiver" $(MAKE) check
156 EXEC_NAME="G_SLICE=always-malloc valgrind --leak-check=full --show-possibly-lost=no --suppressions=python.supp" G_DEBUG=gc-friendly $(MAKE) check
159 mkdir -p $(top_builddir)/tmp
160 EXEC_NAME="G_SLICE=always-malloc valgrind --log-file=$(top_builddir)/tmp/`git rev-parse HEAD | cut -c1-8`-$$TEST_NAMES.log --leak-check=full --show-possibly-lost=no --suppressions=python.supp" G_DEBUG=gc-friendly $(MAKE) check
163 mkdir -p $(top_builddir)/tmp
164 EXEC_NAME="G_SLICE=always-malloc valgrind --xml=yes --xml-file=$(top_builddir)/tmp/`git rev-parse HEAD | cut -c1-8`-$$TEST_NAMES.xml --leak-check=full --show-possibly-lost=no --suppressions=python.supp" G_DEBUG=gc-friendly $(MAKE) check