tools-python-prefix.diff
authorBastian Blank <waldi@debian.org>
Sat, 5 Jul 2014 09:47:02 +0000 (11:47 +0200)
committerIan Jackson <ian.jackson@citrix.com>
Mon, 18 Jun 2018 15:10:38 +0000 (16:10 +0100)
Patch-Name: tools-python-prefix.diff

Gbp-Pq: Name tools-python-prefix.diff

tools/python/setup.py

index 8faf1c0ddc9093cec490a8b7211586347a01c9b2..db61025ee305aad23cd5defb774de70e93e56d17 100644 (file)
@@ -5,6 +5,7 @@ import os, sys
 XEN_ROOT = "../.."
 
 extra_compile_args  = [ "-fno-strict-aliasing", "-Werror" ]
+extra_link_args = [ "-Wl,-rpath,${ORIGIN}/../../.." ]
 
 PATH_XEN      = XEN_ROOT + "/tools/include"
 PATH_LIBXENTOOLLOG = XEN_ROOT + "/tools/libs/toollog"
@@ -23,11 +24,12 @@ xc = Extension("xc",
                library_dirs       = [ PATH_LIBXC ],
                libraries          = [ "xenctrl", "xenguest" ],
                depends            = [ PATH_LIBXC + "/libxenctrl.so", PATH_LIBXC + "/libxenguest.so" ],
-               extra_link_args    = [ "-Wl,-rpath-link="+PATH_LIBXENTOOLLOG ],
+               extra_link_args    = extra_link_args + [ "-Wl,-rpath-link="+PATH_LIBXENTOOLLOG ],
                sources            = [ "xen/lowlevel/xc/xc.c" ])
 
 xs = Extension("xs",
                extra_compile_args = extra_compile_args,
+               extra_link_args    = extra_link_args,
                include_dirs       = [ PATH_XEN, PATH_XENSTORE + "/include", "xen/lowlevel/xs" ],
                library_dirs       = [ PATH_XENSTORE ],
                libraries          = [ "xenstore" ],