summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMartin Xu <martin.xu@intel.com>2009-12-03 17:05:41 +0800
committerMarcel Holtmann <marcel@holtmann.org>2009-12-03 22:11:40 +0100
commit4960526aa9a3053b9f3c949c53f6e8f141af1708 (patch)
treed495d431d0919548fa379a2271d36faa5ca16e44
parentbcef5a1dd6af08d1cc7745ed0342252ff4af9ac4 (diff)
downloadofono-4960526aa9a3053b9f3c949c53f6e8f141af1708.tar.bz2
Allow builds to install the test scripts for debugging
-rw-r--r--Makefile.am9
-rwxr-xr-xbootstrap-configure1
-rw-r--r--configure.ac4
3 files changed, 12 insertions, 2 deletions
diff --git a/Makefile.am b/Makefile.am
index 4b0d7e80..2a140c1c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -231,7 +231,7 @@ doc_files = doc/overview.txt doc/ofono-paper.txt \
doc/call-meter-api.txt \
doc/dataconnectionmanager-api.txt
-test_files = test/test-manager test/test-modem test/test-voicecall \
+test_scripts = test/test-manager test/test-modem test/test-voicecall \
test/test-network-registration test/test-phonebook \
test/test-advice-of-charge test/test-call-settings \
test/test-call-forwarding test/test-call-barring \
@@ -244,10 +244,15 @@ test_files = test/test-manager test/test-modem test/test-voicecall \
test/activate-context test/deactivate-context \
test/process-context-settings
+if TEST
+testdir = $(pkglibdir)/test
+test_SCRIPTS = $(test_scripts)
+endif
+
conf_files = src/ofono.conf plugins/modem.conf
EXTRA_DIST = src/genbuiltin plugins/example_history.c $(doc_files) \
- $(test_files) $(conf_files) $(udev_files)
+ $(test_scripts) $(conf_files) $(udev_files)
dist_man_MANS = doc/ofonod.8
diff --git a/bootstrap-configure b/bootstrap-configure
index 63a689af..f6659438 100755
--- a/bootstrap-configure
+++ b/bootstrap-configure
@@ -7,6 +7,7 @@ fi
./bootstrap && \
./configure --enable-maintainer-mode \
--enable-debug \
+ --enable-test \
--prefix=/usr \
--mandir=/usr/share/man \
--sysconfdir=/etc \
diff --git a/configure.ac b/configure.ac
index 5c2255ad..a3b7d758 100644
--- a/configure.ac
+++ b/configure.ac
@@ -48,6 +48,10 @@ AC_ARG_ENABLE(debug, AC_HELP_STRING([--enable-debug],
fi
])
+AC_ARG_ENABLE(test, AC_HELP_STRING([--enable-test],
+ [enable test/example scripts]), [enable_test=${enableval}])
+AM_CONDITIONAL(TEST, test "${enable_test}" = "yes")
+
AC_ARG_ENABLE(pie, AC_HELP_STRING([--enable-pie],
[enable position independent executables flag]), [
if (test "${enableval}" = "yes" &&