On Thu, 2009-12-03 at 08:59 -0800, Howard B. Golden wrote:
> On Thursday December 3, 2009, Duncan Coutts wrote:

> > The point is, technically we probably do not want "ghci -lpcre" to
> > translate directly into a call to dlopen "libpcre.so". There should
> >  be another translation stage to give us "libpcre.so.0". Then that
> >  name --- corresponding to a fixed ABI --- should be kept in the
> >  package config so we keep linking to the same thing even if you
> >  install newer versions of the C lib.
> 
> I'm not sure this applies to ghci loading from the command line. I 
> believe the semantics should be the same as the system linker uses, 
> i.e., the current version.

Right, but if we can resolve -lpcre to libpcre.so.0 then we can dlopen
libpcre.so.0 without having to parse linker scripts.

> > The problem is I don't know any sensible way to obtain "libpcre.so.0"
> > from "libpcre.so". You can take an empty .o file and use the system
> > linker to link it against -lpcre and then use ldd to see what it
> >  ended up picking. But I'm not sure that's so helpful.
> 
> Using the system linker with an empty file is the best idea I have come 
> up with so far. Otherwise, you just have to copy/adapt what's already in 
> the system linker to figure out the current version.

Yeah, but it's not great is it :-(.

Duncan

_______________________________________________
Cvs-ghc mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/cvs-ghc

Reply via email to