From a596db45f0b7be61fa497ce9480c7c1e15e22492 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Pavel=20=C5=A0imerda?= Date: Tue, 18 Dec 2012 14:14:13 +0100 Subject: [PATCH] build: add --enable-tests=root to enable tests that require uid=0 --- configure.ac | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/configure.ac b/configure.ac index 411f1b63e..0285b2ba8 100644 --- a/configure.ac +++ b/configure.ac @@ -638,7 +638,7 @@ dnl ------------------------- VAPIGEN_CHECK(0.17.1.24) # Tests, utilities and documentation -AC_ARG_ENABLE(tests, AS_HELP_STRING([--enable-tests], [Build NetworkManager tests (default: yes)])) +AC_ARG_ENABLE(tests, AS_HELP_STRING([--enable-tests=root|yes|no], [Build NetworkManager tests (default: yes)])) AC_ARG_ENABLE(doc, AS_HELP_STRING([--enable-doc], [Build NetworkManager documentation (default: no)])) # Fallback to --with-tests and with-docs AC_ARG_WITH(tests, AS_HELP_STRING([--with-tests], [Build NetworkManager tests (deprecated)])) @@ -649,10 +649,11 @@ AS_IF([test -n "$with_docs"], enable_doc="$with_docs") AS_IF([test -z "$enable_tests"], enable_tests="yes") AS_IF([test -z "$enable_doc"], enable_doc="no") # Normalize values -AS_IF([test "$enable_tests" != "yes"], enable_tests="no") +AS_IF([test "$enable_tests" != "yes" -a "$enable_tests" != "root"], enable_tests="no") AS_IF([test "$enable_doc" != "yes"], enable_doc="no") # Add conditionals -AM_CONDITIONAL(ENABLE_TESTS, test "$enable_tests" = "yes") +AM_CONDITIONAL(ENABLE_TESTS, test "$enable_tests" != "no") +AM_CONDITIONAL(RUN_ROOT_TESTS, test "$enable_tests" == "root") AM_CONDITIONAL(ENABLE_DOC, test "$enable_doc" = "yes") # Add gtk-doc conditionals enable_gtk_doc="$enable_doc"