mirror of
https://github.com/xen-project/xen.git
synced 2026-10-29 18:50:05 +01:00
tools/python: do not link against blktap except on Linux
Link to libblktapctl in python setup only for platforms which build it. This fixes a build breakage on NetBSD introduced in 330c4d9010da. Signed-off-by: Gianni Tedesco <gianni.tedesco@citrix.com> Tested-by: Christoph Egger <Christoph.Egger@amd.com> Signed-off-by: Ian Jackson <ian.jackson@eu.citrix.com>
This commit is contained in:
1 parent
a39b5bc64b
commit
ce675adf0d
1 file changed
+5
-3
@@ -14,8 +14,7 @@ include_dirs = [ XEN_ROOT + "/tools/libxc",
|
||||
|
||||
library_dirs = [ XEN_ROOT + "/tools/libxc",
|
||||
XEN_ROOT + "/tools/xenstore",
|
||||
XEN_ROOT + "/tools/libxl",
|
||||
XEN_ROOT + "/tools/blktap2/control",
|
||||
XEN_ROOT + "/tools/libxl"
|
||||
]
|
||||
|
||||
libraries = [ "xenctrl", "xenguest", "xenstore" ]
|
||||
@@ -23,8 +22,11 @@ libraries = [ "xenctrl", "xenguest", "xenstore" ]
|
||||
plat = os.uname()[0]
|
||||
if plat == 'Linux':
|
||||
uuid_libs = ["uuid"]
|
||||
blktap_ctl_libs = ["blktapctl"]
|
||||
library_dirs.append(XEN_ROOT + "/tools/blktap2/control")
|
||||
else:
|
||||
uuid_libs = []
|
||||
blktap_ctl_libs = []
|
||||
|
||||
xc = Extension("xc",
|
||||
extra_compile_args = extra_compile_args,
|
||||
@@ -96,7 +98,7 @@ xl = Extension("xl",
|
||||
extra_compile_args = extra_compile_args,
|
||||
include_dirs = include_dirs + [ "xen/lowlevel/xl" ],
|
||||
library_dirs = library_dirs,
|
||||
libraries = libraries + ["xenlight", "blktapctl" ] + uuid_libs,
|
||||
libraries = libraries + ["xenlight" ] + blktap_ctl_libs + uuid_libs,
|
||||
sources = [ "xen/lowlevel/xl/xl.c", "xen/lowlevel/xl/_pyxl_types.c" ])
|
||||
|
||||
modules = [ xc, xs, ptsname, acm, flask, xl ]
|
||||
|
||||