summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorHenrik Grindal Bakken <hgb@ifi.uio.no>2013-04-18 14:40:24 +0200
committerLennart Poettering <lennart@poettering.net>2013-04-18 17:15:59 +0200
commitcee22bd3cb253734a8a0183751d786128e2ea5e4 (patch)
tree74ee035d031d828bf45cbd36564313cfc85bad3f /configure.ac
parent4826f0b7b5c0aefa08b8cc7ef64d69027f84da2c (diff)
buildsys: Add --disable-tests to avoid building tests
This patch adds --disable-tests to configure. It is based on a patch posted by Thierry Reding in 2010. The motivation for adding it is that some tests fail link-time when cross-compiling. The patch adds a new Makefile variable -- manual_tests -- and uses that instead of noinst_PROGRAMS. However, if ENABLE_TESTS is true, the former is added to the latter. It also renames noinst_tests to simply tests.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac5
1 files changed, 5 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac
index 519f1a95e0..aec85ea615 100644
--- a/configure.ac
+++ b/configure.ac
@@ -880,6 +880,11 @@ AS_IF([test "x$0" != "x./configure"], [
AC_SUBST([INTLTOOL_UPDATE], [/bin/true])
])
+AC_ARG_ENABLE(tests,
+ [AC_HELP_STRING([--disable-tests], [disable tests])],
+ enable_tests=$enableval, enable_tests=yes)
+AM_CONDITIONAL(ENABLE_TESTS, [test x$enable_tests = xyes])
+
AC_SUBST([dbuspolicydir], [$with_dbuspolicydir])
AC_SUBST([dbussessionservicedir], [$with_dbussessionservicedir])
AC_SUBST([dbussystemservicedir], [$with_dbussystemservicedir])