On 04/15/2016 03:48 AM, Martin Kletzander wrote:
> On Thu, Apr 14, 2016 at 04:35:12PM -0600, Jim Fehlig wrote:
>> To ensure the libvirt libxl driver will build with future versions
>> of Xen where the libxl API may change in incompatible ways,
>> explicitly use LIBXL_API_VERSION 0x040200. The libxl driver
>> does use new libxl APIs that have been added since Xen 4.2, but
>> currently it does not make use of any changes made to existing
>> APIs such as libxl_domain_create_restore or libxl_set_vcpuaffinity.
>> The version can be bumped if/when the libxl driver consumes the
>> changed APIs.
>>
>> Further details can be found in the following discussion thread
>>
>> https://www.redhat.com/archives/libvir-list/2016-April/msg00178.html
>> Signed-off-by: Jim Fehlig
>> ---
>> configure.ac | 2 ++
>> src/libxl/libxl_conf.h | 12
>> src/libxl/libxl_domain.c | 15 ---
>> 3 files changed, 2 insertions(+), 27 deletions(-)
>>
>> diff --git a/configure.ac b/configure.ac
>> index b1500f6..446f2a2 100644
>> --- a/configure.ac
>> +++ b/configure.ac
>> @@ -894,6 +894,7 @@ if test "$with_libxl" != "no" ; then
>> PKG_CHECK_MODULES([LIBXL], [xenlight], [
>> LIBXL_FIRMWARE_DIR=`$PKG_CONFIG --variable xenfirmwaredir xenlight`
>> LIBXL_EXECBIN_DIR=`$PKG_CONFIG --variable libexec_bin xenlight`
>> + LIBXL_CFLAGS="$LIBXL_CFLAGS -DLIBXL_API_VERSION=0x040200"
>> with_libxl=yes
>> ], [LIBXL_FOUND=no])
>> if test "$LIBXL_FOUND" = "no"; then
>> @@ -906,6 +907,7 @@ if test "$with_libxl" != "no" ; then
>> LIBS="$LIBS $LIBXL_LIBS"
>> AC_CHECK_LIB([xenlight], [libxl_ctx_alloc], [
>> with_libxl=yes
>> +LIBXL_CFLAGS="$LIBXL_CFLAGS -DLIBXL_API_VERSION=0x040200"
>> LIBXL_LIBS="$LIBXL_LIBS -lxenlight"
>> ],[
>> if test "$with_libxl" = "yes"; then
>
>
> Looks good, I'd just adjust these two hunks so that it's added in one
> place (and can be changed in one place later on so we don't fall into
> trouble accidentally. ACK with that changed.
Thanks. I used one LIBXL_CFLAGS="$LIBXL_CFLAGS -DLIBXL_API_VERSION=0x040200"
after the test for libxenlight, and added a comment for good measure. Pushed
now.
Regards,
Jim
___
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel