From: Zhigang Wang <zhigang.x.wang@oracle.com>
To: Andrew Cooper <andrew.cooper3@citrix.com>, Olaf Hering <olaf@aepfle.de>
Cc: Ian Campbell <Ian.Campbell@citrix.com>,
xen-devel <xen-devel@lists.xen.org>
Subject: Re: libcacard is been installed to /usr/lib while libdir=/usr/lib64
Date: Tue, 20 May 2014 12:55:48 -0400 [thread overview]
Message-ID: <537B8914.8060100@oracle.com> (raw)
In-Reply-To: <537B56C0.20201@oracle.com>
[-- Attachment #1: Type: text/plain, Size: 1630 bytes --]
On 05/20/2014 09:21 AM, Zhigang Wang wrote:
> On 05/20/2014 09:07 AM, Andrew Cooper wrote:
>> On 20/05/14 14:02, Olaf Hering wrote:
>>> On Tue, May 20, Ian Campbell wrote:
>>>
>>>>> For qemu: we didn't pass the --libdir when we configure it, so it uses the default one: $PREFIX/lib
>>>> Thanks. I think your patch is probably the correct one then. Please can
>>>> you submit with a proper changelog.
>>> Likely not.
>>> Since the included qemu is a private part of xen itself, it should
>>> install stuff into $prefix/lib/xen/ instead of overwriting system files.
>>> This most likely means qemu has to be build with rpath to really use its
>>> own libs, if there are any.
>>>
>>> Olaf
>>
>> I agree. Having the Xen build system build itself non-xen components
>> makes integrating the results into a real system very difficult without
>> collisions.
>>
>> In this case, any qemu built by the Xen build system is private to Xen,
>> and should not install as if it were the system qemu.
>>
>> The same goes for other 3rd party components.
>>
>> ~Andrew
>
> I agree with the direction you mentioned.
>
> On CentOS, libcacard is built as a separate RPM and installed to /usr/lib64,
> which will conflict with our build with this patch.
>
> But keep our libcacard under /usr/lib also seems wrong.
>
> Could you please generate a patch to put libcacard etc staff into
> $prefix/lib/xen and build qemu with rpath?
>
> I'm not a expert on these staff but I can test it.
I checked rpath usage and attached patch is what I think is right
to the best of my knowledge.
Please help to confirm this is what we want.
Thanks,
Zhigang
[-- Attachment #2: xen-tools-qemu-libdir.patch --]
[-- Type: text/x-patch, Size: 926 bytes --]
tools: install qemu libraries to xen private directory and add rpath to it
This will prevent our qemu libraries from conflict with system qemu libraries.
Signed-off-by: Zhigang Wang <zhigang.x.wang@oracle.com>
diff --git a/tools/Makefile b/tools/Makefile
index 992fe3e..1dfeda6 100644
--- a/tools/Makefile
+++ b/tools/Makefile
@@ -188,11 +188,14 @@ subdir-all-qemu-xen-dir: qemu-xen-dir-find
$$source/configure --enable-xen --target-list=i386-softmmu \
$(QEMU_XEN_ENABLE_DEBUG) \
--prefix=$(PREFIX) \
+ --libdir=$(PREFIX)/lib/xen/lib \
+ --includedir=$(PREFIX)/lib/xen/include \
--source-path=$$source \
--extra-cflags="-I$(XEN_ROOT)/tools/include \
-I$(XEN_ROOT)/tools/libxc \
-I$(XEN_ROOT)/tools/xenstore \
-I$(XEN_ROOT)/tools/xenstore/compat \
+ -Wl,-rpath=$(PREFIX)/lib/xen/lib \
$(EXTRA_CFLAGS_QEMU_XEN)" \
--extra-ldflags="-L$(XEN_ROOT)/tools/libxc \
-L$(XEN_ROOT)/tools/xenstore" \
[-- Attachment #3: Type: text/plain, Size: 126 bytes --]
_______________________________________________
Xen-devel mailing list
Xen-devel@lists.xen.org
http://lists.xen.org/xen-devel
next prev parent reply other threads:[~2014-05-20 16:55 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-05-13 0:10 libcacard is been installed to /usr/lib while libdir=/usr/lib64 Zhigang Wang
2014-05-15 15:10 ` Ian Campbell
2014-05-15 15:54 ` Zhigang Wang
2014-05-20 12:40 ` Ian Campbell
2014-05-20 13:00 ` Zhigang Wang
2014-05-20 13:05 ` Olaf Hering
2014-05-20 13:02 ` Olaf Hering
2014-05-20 13:07 ` Andrew Cooper
2014-05-20 13:21 ` Zhigang Wang
2014-05-20 16:55 ` Zhigang Wang [this message]
2014-05-21 7:46 ` Olaf Hering
2014-05-21 10:25 ` Ian Campbell
2014-05-21 10:50 ` Olaf Hering
2014-05-21 13:52 ` Zhigang Wang
2014-05-21 14:16 ` Ian Campbell
2014-05-28 16:13 ` Zhigang Wang
2014-06-02 14:40 ` Ian Campbell
2014-06-02 14:49 ` Ian Campbell
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=537B8914.8060100@oracle.com \
--to=zhigang.x.wang@oracle.com \
--cc=Ian.Campbell@citrix.com \
--cc=andrew.cooper3@citrix.com \
--cc=olaf@aepfle.de \
--cc=xen-devel@lists.xen.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).