This is the mail archive of the gcc@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: --rpath -vs- cc1plus


On Dec 15, 2001, Tom Tromey <tromey@redhat.com> wrote:

> creche. gcc foo.cc -lgcj -lgcjgc -lzgcj
> /usr/bin/ld: warning: libgcc_s.so.1, needed by /x1/egcs/install/lib/gcc-lib/i686-pc-linux-gnu/3.1/../../../libgcj.so, not found (try using --rpath)

Newer versions of the linker suggest --rpath-link, which is actually a
better choice.

> So I used --rpath and got a different error:

> creche. gcc foo.cc --rpath /x1/egcs/install/lib -lgcj -lgcjgc -lzgcj  
> cc1plus: unrecognized option `-frpath'

--rpath is a linker option.  As such, you have to use -Wl, or -Xlinker
to get it only to the linker.

> cc1plus should probably recognize and ignore this.
> Or, some spec should take care not to pass -frpath to cc1plus.

Yep, it doesn't make sense to me to pass options like that.  The
option was --rpath, after all, not -frpath or anything that resembled
a cc1plus option.

-- 
Alexandre Oliva   Enjoy Guarana', see http://www.ic.unicamp.br/~oliva/
Red Hat GCC Developer                  aoliva@{cygnus.com, redhat.com}
CS PhD student at IC-Unicamp        oliva@{lsd.ic.unicamp.br, gnu.org}
Free Software Evangelist    *Please* write to mailing lists, not to me


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]