libxl: colo: make it depend on availability of libnl
authorWei Liu <wei.liu2@citrix.com>
Tue, 5 Apr 2016 19:20:53 +0000 (20:20 +0100)
committerIan Jackson <Ian.Jackson@eu.citrix.com>
Wed, 6 Apr 2016 14:10:10 +0000 (15:10 +0100)
commit5cf46a66883ad7a56c5bdee97696373473f80974
treefadace524f3aca4f07c97289bf3ba990648f4859
parentabf68227c74c8b83df43078a1cebdc4e5b991b50
libxl: colo: make it depend on availability of libnl

Netlink is required when initialising COLO, so make sure only to compile
COLO only when netlink is available. Change the inclusion of
linux/netlink.h to netlink/netlink.h so that it doesn't use Linux kernel
header directly.

Provide necessary stub functions in case COLO is disabled. This should
fix build on FreeBSD because there is no netlink there. It would also
make libxl build properly when netlink is not present on a Linux
system.

Signed-off-by: Wei Liu <wei.liu2@citrix.com>
Acked-by: Ian Jackson <ian.jackson@eu.citrix.com>
tools/libxl/Makefile
tools/libxl/libxl_colo_proxy.c
tools/libxl/libxl_no_colo.c [new file with mode: 0644]