Subject: Re: -Wl,-rpath on non-ELF systems
To: None <tech-pkg@netbsd.org>
From: Jan Schaumann <jschauma@netbsd.org>
List: tech-pkg
Date: 08/22/2002 14:48:55
Thomas Klausner <wiz@danbala.ifoer.tuwien.ac.at> wrote:
> On Thu, Aug 22, 2002 at 01:43:45PM -0400, Jan Schaumann wrote:
> > Do I understand it correctly that the '-rpath' option only works on
> > ELF-systems?  I found www/ap-php3 to only compile under Linux if I take
> > this option out -- I would assume that there are other instances where
> > this option might cause a build to fail.
> 
> IIRC, -rpath is only in newer ld(1)s. For compatibility with our a.out
> platforms we mostly use -R.

Hmmm, even though the ld(1) on the linux machine is newer than the one
on my netbsd boxen, I'm having problems.  In particular, the compilation
of the source-file works fine (gcc [...] -Wl,-rpath /path [...]), but
then the linking fails, as if the '-rpath' option wasn't given at all
(gcc -shared -o file /path files).  That is, it simply adds the '/path'
instead of passing the '-L/path' flags.

When using '-R/path', however, things work fine.

So you're of course right - now the question is, why is that?  I find it
odd.

-Jan
 
-- 
http://www.eff.org