summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac17
1 files changed, 15 insertions, 2 deletions
diff --git a/configure.ac b/configure.ac
index a963d4d5..95216c57 100644
--- a/configure.ac
+++ b/configure.ac
@@ -207,6 +207,9 @@ if test "x$enable_embedded_tests" = xyes; then
[Define to build test code into the library and binaries])
fi
+# call early to ensure availability
+PKG_PROG_PKG_CONFIG
+
# DBUS_ENABLE_MODULAR_TESTS controls tests that work based on public API.
# These use GTest, from GLib, because life's too short. They're enabled by
# default (unless you don't have GLib), because they don't bloat the library
@@ -907,8 +910,6 @@ fi
# unix:path=/foo or unix:abstract=/foo
AC_SUBST(DBUS_PATH_OR_ABSTRACT)
-PKG_PROG_PKG_CONFIG
-
#### Sort out XML library
# see what we have
@@ -1703,6 +1704,17 @@ if test "x$enable_stats" = xyes; then
[Define to enable bus daemon usage statistics])
fi
+#enable smack label support
+AC_ARG_ENABLE([smack], [AS_HELP_STRING([--enable-smack], [enable SMACK security checks])], [], [enable_smack=no])
+if test "x$enable_smack" = xyes; then
+ PKG_CHECK_MODULES([LIBSMACK], [libsmack >= 1.0],
+ [AC_DEFINE([DBUS_ENABLE_SMACK], [1], [Define to enable SMACK security features])],
+ [AC_MSG_ERROR([libsmack is required to enable smack support])])
+fi
+
+AC_SUBST([LIBSMACK_CFLAGS])
+AC_SUBST([LIBSMACK_LIBS])
+
AC_CONFIG_FILES([
Doxyfile
dbus/versioninfo.rc
@@ -1781,6 +1793,7 @@ echo "
Building checks: ${enable_checks}
Building bus stats API: ${enable_stats}
Building SELinux support: ${have_selinux}
+ Building SMACK support: ${enable_smack}
Building inotify support: ${have_inotify}
Building dnotify support: ${have_dnotify}
Building kqueue support: ${have_kqueue}