$(build_tooldir)/lib (was Re: http://gcc.gnu.org/ml/gcc-patches/2000-05/msg01104.html)
Jim Wilson
wilson@cygnus.com
Fri Jul 21 15:28:00 GMT 2000
When you build an ia64 toolchain, where does your crt0.o live? How does
the compiler find it?
The libraries are copied to $prefix/$target/lib (aka $tooldir/lib) at
configure time. That is one of the paths that gcc searches by default.
That happens in gcc.c when it adds tooldir_prefix/lib to startfile_prefixes.
Looking at H.J. messages, he says this doesn't work because tooldir is
really $prefix/lib/gcc-lib/$target/$version/../../../../$target/lib
and $prefix/lib/gcc-lib/$target/$version doesn't exist at build time.
But it does. We deliberately create it so that $tooldir/lib and
$tooldir/sys-include will work. See the code in the stmp-fixinc rule in the
Makefile. Nothing needs $libsubdir before then. If something does need it,
then we should create it earlier.
I believe one of H.J.'s other comments was that he defines prefix to point
somewhere in /usr, and since he isn't root when he is building the toolchain,
the creation of $libsubdir fails. I think that is a little weak. But if
this is a concern, then the new scheme doesn't help fix it, because it is
still installing stuff in $prefix at configure/build time.
Jim
More information about the Binutils
mailing list