[tracker/gdbus: 18/21] functional-tests: Do not use dbus-glib where not necessary
- From: Martyn James Russell <mr src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [tracker/gdbus: 18/21] functional-tests: Do not use dbus-glib where not necessary
- Date: Wed, 27 Oct 2010 17:04:41 +0000 (UTC)
commit 5bb8eab9896a94948c49748469c228e0b33e75f1
Author: Jürg Billeter <j bitron ch>
Date: Mon Oct 25 14:36:09 2010 +0200
functional-tests: Do not use dbus-glib where not necessary
configure.ac | 8 ++++++++
examples/class-signal/Makefile.am | 14 +++++++++++---
tests/functional-tests/Makefile.am | 1 -
tests/functional-tests/ipc/Makefile.am | 18 ++++++++++++++++--
4 files changed, 35 insertions(+), 6 deletions(-)
---
diff --git a/configure.ac b/configure.ac
index dc3f658..2242035 100644
--- a/configure.ac
+++ b/configure.ac
@@ -477,6 +477,14 @@ PKG_CHECK_MODULES(TRACKER_NAUTILUS_EXTENSION, [$TRACKER_NAUTILUS_EXTENSION_REQUI
[have_tracker_nautilus_extension=yes],
[have_tracker_nautilus_extension=no])
+# Check for D-Bus requirements (for tests/examples only)
+PKG_CHECK_MODULES(TRACKER_DBUS,
+ [gio-unix-2.0 >= $GLIB_REQUIRED
+ dbus-1 >= $DBUS_REQUIRED
+ dbus-glib-1 >= $DBUS_GLIB_REQUIRED],
+ [have_tracker_dbus=yes],
+ [have_tracker_dbus=no])
+
# General CFLAGS/LIBS
BUILD_CFLAGS="${WARN_CFLAGS} ${GCOV_CFLAGS} -DG_LOG_DOMAIN=\\\"Tracker\\\" -DTRACKER_COMPILATION"
BUILD_LIBS="${GCOV_LIBS}"
diff --git a/examples/class-signal/Makefile.am b/examples/class-signal/Makefile.am
index 6657faa..313b8fd 100644
--- a/examples/class-signal/Makefile.am
+++ b/examples/class-signal/Makefile.am
@@ -5,12 +5,20 @@ noinst_PROGRAMS = class-signal
AM_CPPFLAGS = \
$(BUILD_CFLAGS) \
-I$(top_srcdir)/src \
- $(LIBTRACKER_SPARQL_CFLAGS)
+ $(LIBTRACKER_SPARQL_CFLAGS) \
+ $(TRACKER_DBUS_CFLAGS)
LDADD = \
$(top_builddir)/src/libtracker-sparql/libtracker-sparql-$(TRACKER_API_VERSION).la \
$(BUILD_LIBS) \
- $(LIBTRACKER_SPARQL_LIBS)
+ $(LIBTRACKER_SPARQL_LIBS) \
+ $(TRACKER_DBUS_LIBS)
-class_signal_SOURCES = class-signal.c
+# NOTE: class-signal needed to have gio/dbus/dbus-glib-1 CFLAGS/LIBS
+# added. The reason for this is that the
+# LIBTRACKER_SPARQL_{CFLAGS|LIBS} no longer include dbus/dbus-glib-1
+# so these tests fail without that. The fix is to update the test
+# cases to use gdbus. For now this is a temporary fix for these tests,
+# -mr.
+class_signal_SOURCES = class-signal.c
diff --git a/tests/functional-tests/Makefile.am b/tests/functional-tests/Makefile.am
index ea862c4..f5ed968 100644
--- a/tests/functional-tests/Makefile.am
+++ b/tests/functional-tests/Makefile.am
@@ -23,7 +23,6 @@ config_SCRIPTS += \
tracker-tests.aegis
endif
-
standard_tests = \
01-insertion.py
if HAVE_TRACKER_FTS
diff --git a/tests/functional-tests/ipc/Makefile.am b/tests/functional-tests/ipc/Makefile.am
index fc7db0f..1b886d3 100644
--- a/tests/functional-tests/ipc/Makefile.am
+++ b/tests/functional-tests/ipc/Makefile.am
@@ -24,11 +24,21 @@ LDADD = \
$(BUILD_LIBS) \
$(LIBTRACKER_SPARQL_LIBS)
+# NOTE: test-busy-handling, test-class-signal,
+# test-class-signal-performance are all tests which needed to have
+# gio/dbus/dbus-glib-1 CFLAGS/LIBS added. The reason for this is that
+# the LIBTRACKER_SPARQL_{CFLAGS|LIBS} no longer include
+# dbus/dbus-glib-1 so these tests fail without that. The fix is to
+# update the test cases to use gdbus. For now this is a temporary fix
+# for these tests, -mr.
+
test_busy_handling_VALASOURCES = test-busy-handling.vala
test_busy_handling_SOURCES = \
test-busy-handling.vala.stamp \
$(test_busy_handling_VALASOURCES:.vala=.c)
+test_busy_handling_CPPFLAGS = $(AM_CPPFLAGS) $(TRACKER_DBUS_CFLAGS)
+test_busy_handling_LDADD = $(LDADD) $(TRACKER_DBUS_LIBS)
test-busy-handling.vala.stamp: $(test_busy_handling_VALASOURCES)
$(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 --pkg dbus-glib-1 $^
@@ -77,11 +87,11 @@ bus_vapi_sources = \
$(top_srcdir)/src/libtracker-bus/tracker-bus.vapi
test-bus-query.vala.stamp: $(test_bus_query_VALASOURCES) $(bus_vapi_sources)
- $(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 --pkg dbus-glib-1 $^
+ $(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 $^
$(AM_V_GEN)touch $@
test-bus-update.vala.stamp: $(test_bus_update_VALASOURCES) $(bus_vapi_sources)
- $(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 --pkg dbus-glib-1 $^
+ $(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 $^
$(AM_V_GEN)touch $@
test_class_signal_VALASOURCES = test-class-signal.vala
@@ -89,6 +99,8 @@ test_class_signal_VALASOURCES = test-class-signal.vala
test_class_signal_SOURCES = \
test-class-signal.vala.stamp \
$(test_class_signal_VALASOURCES:.vala=.c)
+test_class_signal_CPPFLAGS = $(AM_CPPFLAGS) $(TRACKER_DBUS_CFLAGS)
+test_class_signal_LDADD = $(LDADD) $(TRACKER_DBUS_LIBS)
test-class-signal.vala.stamp: $(test_class_signal_VALASOURCES) $(direct_vapi_sources)
$(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 --pkg dbus-glib-1 $^
@@ -99,6 +111,8 @@ test_class_signal_performance_VALASOURCES = test-class-signal-performance.vala
test_class_signal_performance_SOURCES = \
test-class-signal-performance.vala.stamp \
$(test_class_signal_performance_VALASOURCES:.vala=.c)
+test_class_signal_performance_CPPFLAGS = $(AM_CPPFLAGS) $(TRACKER_DBUS_CFLAGS)
+test_class_signal_performance_LDADD = $(LDADD) $(TRACKER_DBUS_LIBS)
test-class-signal-performance.vala.stamp: $(test_class_signal_performance_VALASOURCES) $(direct_vapi_sources)
$(AM_V_GEN)$(VALAC) $(GCOV_VALAFLAGS) -C $(VALAFLAGS) --pkg gio-2.0 --pkg dbus-glib-1 $^
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]