[lldb-dev] Heads-up: FreeBSD LLDB CMake build broken by relative rpath change
emaste at freebsd.org
Thu Feb 27 08:12:21 PST 2014
On 27 February 2014 10:57, Rafael Espíndola <rafael.espindola at gmail.com> wrote:
> On 27 February 2014 10:51, Brad King <brad.king at kitware.com> wrote:
>> If a user sets CMAKE_INSTALL_RPATH to include $ORIGIN then he/she
>> can also add -zorigin as necessary.
> True. My thinking was that there is probably no reason not to have it,
> but the fact that it is not implicit in freebsd probably means there
> is a reason for not having it sometimes.
Aha, I think I've finally found a reference that makes sense of
DF_ORIGIN, in this decade-old SCO documentation:
Based on this I think that FreeBSD's rtld is actually in the wrong
here, and an executable's rpath that contains $ORIGIN should undergo
substitution, regardless of the state of the DF_ORIGIN flag. If I
understand correctly DF_ORIGIN should be necessary only in the case of
an executable that does not use $ORIGIN in an rpath, but later
dlopen()s a library that does.
That said, it still seems safe to just set the flag always.
More information about the lldb-dev