From: Kaj-Michael Lang Date: Thu, 10 Apr 2008 11:15:58 +0000 (+0300) Subject: Make HAL optional even if requested X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dec646eb888e5d9d9050d6b85d00d7414b7918c5;p=mapper Make HAL optional even if requested --- diff --git a/configure.ac b/configure.ac index 1883370..7714e9e 100644 --- a/configure.ac +++ b/configure.ac @@ -134,10 +134,14 @@ else fi if test "x$enable_hal" = "xyes" ; then - PKG_CHECK_MODULES(HAL, hal) - AC_SUBST(HAL_LIBS) - AC_SUBST(HAL_CFLAGS) - AC_DEFINE([WITH_HAL], 1, [Listen to special events using hal]) + PKG_CHECK_MODULES(HAL, hal, HAVE_HAL=yes, HAVE_HAL=no) + if test "x$HAVE_HAL" = "xyes"; then + AC_SUBST(HAL_LIBS) + AC_SUBST(HAL_CFLAGS) + AC_DEFINE([WITH_HAL], 1, [Listen to special events using HAL]) + else + AC_MSG_NOTICE([HAL support requested but not found, disabling]) + fi fi AC_PATH_PROG(GLIB_GENMARSHAL, glib-genmarshal)