Fix libvirt-driver-libxl check

Fix saving CFLAGS in LIBVIRT_DRIVER_CHECK_LIBXL - LIBVIRT_CHECK_LIB will
override old_CFLAGS, so use a different name.

Signed-off-by: Marek Marczykowski-Górecki <marmarek@invisiblethingslab.com>
Reviewed-by: Jim Fehlig <jfehlig@suse.com>
This commit is contained in:
Marek Marczykowski-Górecki 2018-08-05 23:50:35 +02:00 committed by Jim Fehlig
parent 17dff35848
commit 3d203553d3

View File

@ -46,10 +46,10 @@ AC_DEFUN([LIBVIRT_DRIVER_CHECK_LIBXL], [
dnl The libxl driver will make use of this new parameter for specifying dnl The libxl driver will make use of this new parameter for specifying
dnl the Xen migration stream version. Specify LIBXL_API_VERSION to trigger dnl the Xen migration stream version. Specify LIBXL_API_VERSION to trigger
dnl an error if there is too old xenlight dnl an error if there is too old xenlight
old_CFLAGS="$CFLAGS" libxlold_CFLAGS="$CFLAGS"
CFLAGS="$CFLAGS $LIBXL_API_VERSION" CFLAGS="$CFLAGS $LIBXL_API_VERSION"
LIBVIRT_CHECK_LIB([LIBXL], [xenlight], [libxl_ctx_alloc], [libxl.h], [fail="1"]) LIBVIRT_CHECK_LIB([LIBXL], [xenlight], [libxl_ctx_alloc], [libxl.h], [fail="1"])
CFLAGS="$old_CFLAGS" CFLAGS="$libxlold_CFLAGS"
if test $fail = 1; then if test $fail = 1; then
AC_MSG_ERROR([You must install the libxl Library from Xen >= 4.4 to compile libxenlight driver with -lxl]) AC_MSG_ERROR([You must install the libxl Library from Xen >= 4.4 to compile libxenlight driver with -lxl])