[PATCH] 2nd try: enabling clients to use rpath to find LLVM shared libraries on OS X
Benjamin Scarlet
flld0 at greynode.net
Mon Jul 29 20:48:52 PDT 2013
Are these other places inside the llvm svn trunk? If not, how broadly should I be looking?
-Ben
On Jul 29, 2013, at 4:57 PM, Eric Christopher <echristo at gmail.com> wrote:
> Seems to make sense. There are a couple of other places where we use
> executable path instead of rpath (including one for libclang in cmake
> which entertains me), can you fix those up as well?
>
> Thanks.
>
> -eric
>
> On Tue, Jul 9, 2013 at 5:04 PM, Benjamin Scarlet <flld0 at greynode.net> wrote:
>> I sent this patch at a rather inopportune time, and it doesn't seem to have
>> caught anyone's attention. On the advice of some helpful folks on IRC, I'm
>> trying again.
>>
>> Begin forwarded message:
>>
>> From: Benjamin Scarlet <flld0 at greynode.net>
>> Subject: enabling clients to use rpath to find LLVM shared libraries on OS X
>> Date: July 6, 2013 8:58:00 AM EDT
>> To: llvm-commits at cs.uiuc.edu
>>
>> Could someone please review and apply this patch (or ask for further work,
>> etc. etc.)?
>>
>> The attached patch changes the install name built into
>> libLLVM-<version>.dylib, libLTO.dylib, and libprofile_rt.dylib from
>> @executable_path/../lib/<libraryname> to @rpath/<libraryname> on OS X.
>>
>> Without this patch, on OS X, only executables installed inside the LLVM
>> install directory hierarchy can find the LLVM shared libraries without using
>> DYLD_LIBRARY_PATH - the install name does not allow the use of an rpath.
>>
>> With this patch, an executable which is linked against those libraries will
>> honor a specified rpath, and so the overall behavior is the same as on,
>> e.g., Linux.
>>
>> Because the LLVM binaries are already built with such an rpath (probably
>> because it's necessary on other platforms), no additional change is
>> necessary to keep them finding their dependencies.
>>
>> Thanks for looking,
>> Ben Scarlet
>>
>>
>>
>>
>>
>>
>>
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>>
More information about the llvm-commits
mailing list