From dec646eb888e5d9d9050d6b85d00d7414b7918c5 Mon Sep 17 00:00:00 2001 From: Kaj-Michael Lang Date: Thu, 10 Apr 2008 14:15:58 +0300 Subject: [PATCH] Make HAL optional even if requested --- configure.ac | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) 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) -- 2.39.5