Locating shared libraries

Peter Tanski p.tanski at gmail.com
Mon Jun 18 19:18:36 EDT 2007


On Jun 18, 2007, at 6:06 PM, Stefan O'Rear wrote:
> On Mon, Jun 18, 2007 at 11:56:57AM -0400, Peter Tanski wrote:
>> Now each GHC-Haskell-based program installer would search /usr/local/
>> lib for, say, libHSrts_dyn-6.6.1.dylib and install that version if
>> necessary.  What happens on uninstall?  ...
>>
>> That is why I think your idea was good: put everything into distinct
>> directories.
>
> Debian's high level package manager will automatically garbage collect
> dependancies, such that every package on your system is either  
> manually
> selected for install or a dependant of one.  Thus there is no library
> leak problem.

The Debian package system (I assume you are referring to apt, or  
maybe dpkg?) is very convenient (and relatively quick!).  I don't  
know how well the BSD-style package systems garbage collect but I  
have not had any problems using port or fink--though sometimes they  
pull more dependancies than they need because installed programs  
outside their system are (wisely) not considered.  Since my best  
machine is a Mac (PowerBook G4, 1.25GHz) the lost libraries become a  
problem as soon as I work independently of a package system.  I  
expect the same would be true for anyone working independently.  Some  
individual languages have their own package systems, such as Lisp's  
asdf; OCaml has GODI.  Haskell is moving in that direction with Cabal  
but it is still more of a build system than anything else and in any  
case it would probably be better to keep with the system packaging  
setup, such as Debian's, for program distribution.  That way GHC  
libraries may reside comfortably in the standard system directories  
but I am still a little querulous.  I would rather all haskell  
libraries use the standard (OS X) DYLD_LIBRARY_PATH, though  
DYLD_FALLBACK_LIBRARY_PATH (putting things in $(home)/lib) might help  
for the haskell-universe.  That may be the solution for programs,  
though it requires more work: Haskell would need packaging.

On a related note, if anyone is interested, once we get an idea of  
where we want to put things I can modify the installer script to  
create an OS X pkg (using PackageMaker) for GHC binary  
distributions.  At least that would make removal easier (using  
Desinstaller).  The old 6.4.1 OS X application install was slick; I  
might redo that.

Cheers,
Pete



More information about the Glasgow-haskell-users mailing list