HEAD doesn't build (was Re: patch applied (ghc): Add
hardwire-lib-paths
option and make it default for inplace invocations)
Simon Marlow
simonmarhaskell at gmail.com
Wed Aug 1 08:28:44 EDT 2007
Roman Leshchinskiy wrote:
> Simon Marlow wrote:
>> Roman Leshchinskiy wrote:
>>> Simon Marlow wrote:
>>>>
>>>> We had a discussion on glasgow-haskell-users recently about whether
>>>> to use libtool, and the general concensus was not:
>>>
>>> Hmm, I missed that one completely. It's probably too late for me to
>>> jump in but I just don't see how the approach you outlined in
>>>
>>> http://www.haskell.org/pipermail/glasgow-haskell-users/2007-June/012740.html
>>>
>>>
>>> deals with systems which don't *have* an rpath and with users who
>>> manually set LD_LIBRARY_PATH. To be entirely honest, I suspect that
>>> what you are trying to achieve can't be done portably and reliably.
>>
>> I don't expect it to be portable. So on MacOS X, is it the case that
>> the only way to build a binary that links to a particular shared
>> library outside the system location is to use LD_LIBRARY_PATH?
>
> IIUC yes, except that it's called DYLD_LIBRARY_PATH. From man dyld:
>
> For each library that a program uses, the dynamic linker looks
> for it in each directory in DYLD_LIBRARY_PATH in turn. If it
> still can't find the library, it then searches DYLD_FALL-
> BACK_FRAMEWORK_PATH and DYLD_FALLBACK_LIBRARY_PATH in turn.
>
> But I think on MacOS, the library paths are usually hardcoded in the
> executable.
If you can hardcode the library paths in the executable, then that's
exactly what -rpath does isn't it?
Cheers,
Simon
More information about the Cvs-ghc
mailing list