[sr #108637] libtool adds -rpath to staging directory

2014-08-19 Thread anonymous
URL:
  

 Summary: libtool adds -rpath to staging directory
 Project: GNU Libtool
Submitted by: None
Submitted on: Tue 19 Aug 2014 11:30:33 PM UTC
Category: None
Priority: 5 - Normal
Severity: 3 - Normal
  Status: None
 Privacy: Public
 Assigned to: None
Originator Email: filbran...@google.com
 Open/Closed: Open
 Discussion Lock: Any
Operating System: GNU/Linux

___

Details:

Hi,

I'm trying to link binaries to libraries that are not installed on the system,
but just unpacked to a "staging" directory.

Consider this (real) example:

1) Build expat with "--libdir=/usr/lib/${platform}"
2) Install expat with "make install DESTDIR=${stagedir}"
3) Configure dbus with "-L${stagedir}/usr/lib/${platform}" where it will find
expat now, and "-rpath /usr/lib/${platform}" where it will find expat at real
runtime when both are installed.
4) Build expat

The problem is that ${stagedir} is leaking and the resulting dbus-daemon gets
both /usr/lib/${platform} *and* ${stagedir}/usr/lib/${platform} added to
it...

I tried working around it by passing --with-sysroot=${stagedir} to the dbus
configure, but unfortunately that didn't work...

I wrote a small reproducer that seems to illustrate the issue, I tried it with
latest libtool from git (commit ac180507c123469d0fe9b25437d459af24b3f789) and
I still have the same problem.

$ libtool_rpath/reproduce.sh
...
===> RPATH of bintest:
 0x000f (RPATH)  Library rpath:
[/path/to/libtool_rpath/destdir/usr/lib/platform:/usr/lib/platform]

Do you have a suggestion of something I could do to accomplish what I'm trying
to accomplish?

Is this a libtool bug?

Any suggestions of workarounds?

Thanks!
Filipe




___

File Attachments:


---
Date: Tue 19 Aug 2014 11:30:33 PM UTC  Name: libtool_rpath.tgz  Size: 912B  
By: None
Script to reproduce this bug.


___

Reply to this item at:

  

___
  Message sent via/by Savannah
  http://savannah.gnu.org/


___
https://lists.gnu.org/mailman/listinfo/libtool


Trying to get libtool not to add -rpath, since libs are only in a staging directory

2014-08-19 Thread Filipe Brandenburger
Hi,

I'm trying to link binaries to libraries that are not installed on the
system, but just unpacked to a "staging" directory.

Consider this (real) example:

1) Build expat with "--libdir=/usr/lib/${platform}"
2) Install expat with "make install DESTDIR=${stagedir}"
3) Configure dbus with "-L${stagedir}/usr/lib/${platform}" where it
will find expat now, and "-rpath /usr/lib/${platform}" where it will
find expat at real runtime when both are installed.
4) Build expat

The problem is that ${stagedir} is leaking and the resulting
dbus-daemon gets both /usr/lib/${platform} and
${stagedir}/usr/lib/${platform} added to it...

I tried working around it by passing --with-sysroot=${stagedir} to the
dbus configure, but unfortunately that didn't work...

Do you have a suggestion of something I could do to accomplish what
I'm trying to accomplish?

Is this a libtool bug?

Any suggestions of workarounds?

(I also filed a bug at
http://savannah.gnu.org/support/index.php?108637 in case this is
actually a libtool bug.)

Thanks in advance!
Filipe

___
https://lists.gnu.org/mailman/listinfo/libtool