Subject: Re: different behaviour of system cc and TOOLDIR/cc
To: Matthias Drochner <>
From: Todd Vierling <>
List: tech-toolchain
Date: 06/10/2003 13:07:01
On Tue, 10 Jun 2003, Matthias Drochner wrote:

: When I try this:
: /usr/tools/bin/i386--netbsdelf-gcc -v -Wl,-nostdlib -B/usr/lib  -Wl,-x
:  -shared -Wl,-soname -Wl, -o  -Wl,--whole-a
: rchive libtest_pic.a  -Wl,--no-whole-archive -lstdc++  -L/usr/lib -L/u
: sr/lib  -Wl,-R/usr/lib -Wl,-R/usr/lib

You're probably going to fall over laughing at this, but try the following

    ... -B/usr/lib/ ...

Note the trailing slash.  It's a gcc peculiarity with -B.

-- Todd Vierling <>