summaryrefslogtreecommitdiffstats
path: root/test/Makefile.am
diff options
context:
space:
mode:
authorColin Walters <walters@verbum.org>2008-05-30 16:53:35 -0400
committerColin Walters <walters@verbum.org>2008-05-30 16:53:35 -0400
commita73a79a155e97a3bd0d3ce5001ca6b9db803eeeb (patch)
treef1c3baeb481bcc0f485a7f9371f1fdc43f0efe08 /test/Makefile.am
parent9d8989cfec02e6ca41f8ffa0ccda16c93ddcb23c (diff)
Add noinst convenience test library, add a test-shutdown
* test/Makefile.am: New convenience library libdbus_testutils_la. Reorder build so that test/ gets built before test/name-test so name-test files can depend on it. * test/name-test/test-shutdown.c: New file, exercises dbus_shutdown () a bit. * test/name-test/run-test.sh Run test-shutdown. * test/test-utils.h: In some cases we already have DBUS_COMPILATION defined, avoid double definition warning.
Diffstat (limited to 'test/Makefile.am')
-rw-r--r--test/Makefile.am26
1 files changed, 12 insertions, 14 deletions
diff --git a/test/Makefile.am b/test/Makefile.am
index 56ab66fc..a7f05970 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -1,10 +1,14 @@
## the "name-test" subdir in fact contains a bunch of tests now that need a temporary bus
## to be running to do stuff with. The directory should be renamed.
-SUBDIRS=name-test
+## We want to build the current directory first to pick up the testutils lib
+SUBDIRS= . name-test
DIST_SUBDIRS=name-test
INCLUDES=-I$(top_srcdir) $(DBUS_TEST_CFLAGS)
+libdbus_testutils_la_SOURCES = test-utils.h test-utils.c
+
+noinst_LTLIBRARIES = libdbus-testutils.la
if DBUS_BUILD_TESTS
## break-loader removed for now
@@ -28,22 +32,16 @@ endif
noinst_PROGRAMS= $(TEST_BINARIES) $(GCOV_BINARIES)
test_service_SOURCES= \
- test-service.c \
- test-utils.c \
- test-utils.h
+ test-service.c
test_names_SOURCES= \
- test-names.c \
- test-utils.c \
- test-utils.h
+ test-names.c
##break_loader_SOURCES= \
## break-loader.c
test_shell_service_SOURCES = \
- test-shell-service.c \
- test-utils.c \
- test-utils.h
+ test-shell-service.c
shell_test_SOURCES= \
shell-test.c
@@ -65,15 +63,15 @@ decode_gcov_SOURCES= \
TEST_LIBS=$(DBUS_TEST_LIBS) $(top_builddir)/dbus/libdbus-convenience.la
-test_service_LDADD=$(TEST_LIBS)
+test_service_LDADD=$(TEST_LIBS) libdbus-testutils.la
test_service_LDFLAGS=@R_DYNAMIC_LDFLAG@
-test_names_LDADD=$(TEST_LIBS)
+test_names_LDADD=$(TEST_LIBS) libdbus-testutils.la
test_names_LDFLAGS=@R_DYNAMIC_LDFLAG@
## break_loader_LDADD= $(TEST_LIBS)
## break_loader_LDFLAGS=@R_DYNAMIC_LDFLAG@
-test_shell_service_LDADD=$(TEST_LIBS)
+test_shell_service_LDADD=$(TEST_LIBS) libdbus-testutils.la
test_shell_service_LDFLAGS=@R_DYNAMIC_LDFLAG@
-shell_test_LDADD=$(TEST_LIBS)
+shell_test_LDADD=$(TEST_LIBS) libdbus-testutils.la
shell_test_LDFLAGS=@R_DYNAMIC_LDFLAG@
spawn_test_LDADD=$(TEST_LIBS)
spawn_test_LDFLAGS=@R_DYNAMIC_LDFLAG@