From: Eric Blake Date: Thu, 13 Sep 2012 12:32:41 +0000 (-0600) Subject: build: don't fail if libnl-3 is not found X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=67936d13016956a6cd6f9c9f3ee3f7b0a2d904ac;p=people%2Fliuw%2Flibxenctrl-split%2Flibvirt.git build: don't fail if libnl-3 is not found Commit 9298bfb changed configure to split the libnl into two separate pkg config checks instead of nesting the second check on the failure path of the first. But the default pkg config behavior is to abort configure if a check fails. Since we have a second check lined up, we need an explicit failure case that does not abort if the first check fails. Meanwhile, commit 51b708c is reverted. It did not fix any behavior, and in fact, introduced a regression to the fallback case when the user explicitly sets $LIBNL_CFLAGS. * configure.ac: Don't abort if libnl-3 is not found. --- diff --git a/configure.ac b/configure.ac index b5666a56d..fd89bfc18 100644 --- a/configure.ac +++ b/configure.ac @@ -2915,7 +2915,7 @@ if test "$with_linux" = "yes"; then fi done case $libnl_ldd:${LIBNL_CFLAGS+set} in - *libnl.so.1*) ;; + *libnl.so.1*:) ;; *) PKG_CHECK_MODULES([LIBNL], [libnl-3.0], [ have_libnl=yes @@ -2924,7 +2924,7 @@ if test "$with_linux" = "yes"; then PKG_CHECK_MODULES([LIBNL_ROUTE3], [libnl-route-3.0]) LIBNL_CFLAGS="$LIBNL_CFLAGS $LIBNL_ROUTE3_CFLAGS" LIBNL_LIBS="$LIBNL_LIBS $LIBNL_ROUTE3_LIBS" - ], []) ;; + ], [:]) ;; esac if test "$have_libnl" = no; then PKG_CHECK_MODULES([LIBNL], [libnl-1 >= $LIBNL_REQUIRED], [