From: Diego Elio Pettenò Date: Fri, 18 Dec 2009 17:29:13 +0000 (+0100) Subject: Don't make it possible to define HAVE_HAL but not enable it in automake X-Git-Tag: v0.7.5~49 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3a524a2b11b6d8f5a5e9928b637518713547aa7c;p=thirdparty%2Flibvirt.git Don't make it possible to define HAVE_HAL but not enable it in automake * configure.in: With the previous logic, if libhal_get_all_devices function was not found, HAVE_HAL would be defined for the preprocessor but it wouldn't be enabled in automake conditionals, causing the final link to fail with missing references to HAL entries. --- diff --git a/configure.in b/configure.in index bac042aaa4..09d35b5e41 100644 --- a/configure.in +++ b/configure.in @@ -1723,9 +1723,6 @@ if test "x$with_hal" = "xyes" -o "x$with_hal" = "xcheck"; then fi ]) if test "x$with_hal" = "xyes" ; then - AC_DEFINE_UNQUOTED([HAVE_HAL], 1, - [use HAL for host device enumeration]) - old_CFLAGS=$CFLAGS old_LDFLAGS=$LDFLAGS CFLAGS="$CFLAGS $HAL_CFLAGS" @@ -1735,6 +1732,10 @@ if test "x$with_hal" = "xyes" -o "x$with_hal" = "xcheck"; then CFLAGS="$old_CFLAGS" LDFLAGS="$old_LDFLAGS" fi + if test "x$with_hal" = "xyes" ; then + AC_DEFINE_UNQUOTED([HAVE_HAL], 1, + [use HAL for host device enumeration]) + fi fi AM_CONDITIONAL([HAVE_HAL], [test "x$with_hal" = "xyes"]) AC_SUBST([HAL_CFLAGS])