diff options
author | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2017-04-06 11:03:00 -0400 |
---|---|---|
committer | Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> | 2017-04-19 19:27:01 -0400 |
commit | 86cebca72ba9ddb5dc6e6a2723f08a3881f3fbe3 (patch) | |
tree | 9429796ea4b0af1cb07e98049297fd02a7fa993a | |
parent | f96c10bdca1a71e39ebd8b2616f9d2cd8344a770 (diff) |
configure: restore check for glib libraries
This is a partial revert of 2375607039517c88df. We still have code
guarded by HAVE_GLIB in tests.
v2:
- do not define the automake conditional, it wasn't used anywhere
- rename --disable-gudev to --disable-glib
v3:
- do not cause an error if the libs are not found, this is supposed
to be an "auto" dep by default.
-rw-r--r-- | configure.ac | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 68e82463a3..3436a9d8a6 100644 --- a/configure.ac +++ b/configure.ac @@ -399,6 +399,16 @@ AS_IF([test "x$enable_dbus" != "xno"], [ AM_CONDITIONAL(HAVE_DBUS, [test "$have_dbus" = "yes"]) # ------------------------------------------------------------------------------ +have_glib=no +AC_ARG_ENABLE(glib, AS_HELP_STRING([--disable-glib], [disable usage of glib,gobject,gio in tests])) +AS_IF([test "x$enable_glib" != "xno"], [ + PKG_CHECK_MODULES(GLIB, [glib-2.0 >= 2.22.0 gobject-2.0 >= 2.22.0 gio-2.0], + [AC_DEFINE(HAVE_GLIB, 1, [Define if glib,gobject,gio are available]) have_glib=yes], + [have_glib=no]) + AS_IF([test "x$have_glib" = "xno" -a "x$enable_glib" = "xyes"], + [AC_MSG_ERROR([*** glib support requested but libraries not found])])]) + +# ------------------------------------------------------------------------------ have_utmp=yes AC_ARG_ENABLE([utmp], AS_HELP_STRING([--disable-utmp], [disable utmp/wtmp log handling]), AS_CASE("x${enableval}", @@ -1741,6 +1751,7 @@ AC_MSG_RESULT([ blkid: ${have_blkid} libmount: ${have_libmount} dbus: ${have_dbus} + glib: ${have_glib} nss-myhostname: ${have_myhostname} hwdb: ${enable_hwdb} tpm: ${have_tpm} |