diff options
author | Jan Palus <[email protected]> | 2024-01-24 13:14:24 +0100 |
---|---|---|
committer | raveit65 <[email protected]> | 2024-02-02 21:10:24 +0100 |
commit | bc1296b16d9ec05e8d990c18d22fc52b78071afb (patch) | |
tree | 8e5d9f92d33a8cc3b7e84b9c72196da03930cdec | |
parent | 4d3102f305d3caf3b242b1635d557007a8a8013d (diff) | |
download | mate-system-monitor-bc1296b16d9ec05e8d990c18d22fc52b78071afb.tar.bz2 mate-system-monitor-bc1296b16d9ec05e8d990c18d22fc52b78071afb.tar.xz |
build: do enable systemd by default (but don't force it)
contrary to help string (--disable-systemd) systemd was not enabled by
default since enable_systemd was set to `no` if no option was passed. do
enable it but use `auto` mode by default: use systemd if available but
continue if it's missing. enforcing systemd can be ecomplished with
--enable-systemd.
-rw-r--r-- | configure.ac | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/configure.ac b/configure.ac index 90136fb..9f6621f 100644 --- a/configure.ac +++ b/configure.ac @@ -64,14 +64,14 @@ AM_CONDITIONAL(HAVE_WNCK, [test "enable_wnck" = "yes"]) PKG_CHECK_MODULES(TOOLS, glib-2.0 >= $GLIB_REQUIRED) have_systemd=no -AC_ARG_ENABLE(systemd, AS_HELP_STRING([--disable-systemd], [disable systemd support]),,enable_systemd=no) +AC_ARG_ENABLE(systemd, AS_HELP_STRING([--disable-systemd], [disable systemd support]),enable_systemd="$enableval",enable_systemd=auto) if test "x$enable_systemd" != "xno"; then PKG_CHECK_MODULES(SYSTEMD, [libsystemd], [have_systemd=yes], [PKG_CHECK_MODULES(SYSTEMD, [libsystemd-login >= $SYSTEMD_REQUIRED], [have_systemd=yes])]) - if test "x$have_systemd" = xno; then + if test "x$have_systemd" = xno && test "x$enable_systemd" = xyes; then AC_MSG_ERROR([*** systemd support requested but libraries not found]) - else + elif test "x$have_systemd" = xyes; then AC_DEFINE(HAVE_SYSTEMD, 1, [Define if systemd is available]) fi fi |