summaryrefslogtreecommitdiff
path: root/configure.ac
diff options
context:
space:
mode:
authorOlaf Leidinger <[email protected]>2015-11-14 16:46:28 +0100
committerOlaf Leidinger <[email protected]>2015-11-14 16:46:28 +0100
commitf9a2293e611930bab7a799efe2569313a4414348 (patch)
treec51e1606038df706e4d1fb03326afbeb88fb35b6 /configure.ac
parentdebd5bbbe3dda8934687eb66dbf0a5bfa97f5b2e (diff)
downloadmate-session-manager-f9a2293e611930bab7a799efe2569313a4414348.tar.bz2
mate-session-manager-f9a2293e611930bab7a799efe2569313a4414348.tar.xz
compile fix for upower 0.99 series
upower 0.99 has lost support for hibernate and suspend. This leads to undefined references to up_client_get_can_suspend and up_client_get_can_hibernate on my system. This patch removes any call to those functions for upower >= 0.99.
Diffstat (limited to 'configure.ac')
-rw-r--r--configure.ac7
1 files changed, 6 insertions, 1 deletions
diff --git a/configure.ac b/configure.ac
index 74d86ac..9fe1f29 100644
--- a/configure.ac
+++ b/configure.ac
@@ -146,13 +146,18 @@ AC_ARG_ENABLE(upower,
enable_upower=$enableval,
enable_upower=no)
if test "x$enable_upower" = "xyes"; then
- PKG_CHECK_MODULES(UPOWER, upower-glib >= $UPOWER_REQUIRED, has_upower=yes, has_upower=no)
+ PKG_CHECK_MODULES([UPOWER], [upower-glib >= $UPOWER_REQUIRED], has_upower=yes, has_upower=no)
if test "x$has_upower" = "xyes"; then
AC_DEFINE(HAVE_UPOWER, 1, [upower support])
AC_SUBST(UPOWER_CFLAGS)
AC_SUBST(UPOWER_LIBS)
fi
+ PKG_CHECK_MODULES([UPOWER_HIBERNATE], [upower-glib < 0.99], has_upower_hibernate_suspend=yes, has_upower_hibernate_suspend=no)
+ if test "x$has_upower_hibernate_suspend" = "xyes"; then
+ AC_DEFINE(HAVE_UPOWER_HIBERNATE_SUSPEND, 1, [upower based support for hibernate and suspend (<0.99) ])
+ fi
+
fi
AM_CONDITIONAL(HAVE_UPOWER, test "x$has_upower" = "xyes")
AC_SUBST(HAVE_UPOWER)