------- Comment #5 from gin at mo dot msk dot ru  2006-12-28 13:32 -------
Subject: Re:  -B$(build_tooldir)/bin/

It actually broke build of gcc (version 3.0.3) at least on one class
of systems, i386-pc-sco3.2v5, as follows.

Had on that system gnu binutils installed with PREFIX.  Had gcc
configured with to install with the same PREFIX.  Configured it

--without-included-gettext --prefix=PREFIX --with-as=PREFIX/bin/gas
--enable-multilib --disable-static --enable-shared

(Native `as' was broken in many ways, so GNU one was indeed strongly
preferred.  OTOH, not specifying `--with-ld', so that native is used
`ld', was essential: one from binutils, at least as of 2.11.2, would
output elf binaries that system dynamic linker would not link.)

make bootstrap

would fail as follows.

stage1/xgcc -Bstage1/ -BPREFIX/i586-pc-sco3.2v5.0.4/bin/  -DIN_GCC    -g -O2 -W
-Wall -Wwrite-strings -Wstrict-prototypes -Wmissing-prototypes -Wtraditional
-pedantic -Wno-long-long  -DHAVE_CONFIG_H -DGENERATOR_FILE  -o gengenrtl \
 gengenrtl.o ` case "obstack.o" in ?*) echo obstack.o ;; esac ` ` case
"alloca.o" in ?*) echo alloca.o ;; esac ` ` case "" in ?*) echo  ;; esac ` `
case "" in ?*) echo  ;; esac ` ` case "" in ?*) echo  ;; esac ` ` case "" in
?*) echo  ;; esac ` 
PREFIX/i586-pc-sco3.2v5.0.4/bin/ld: unrecognized option
'-YP,/usr/ccs/lib:/lib:/usr/lib'
PREFIX/i586-pc-sco3.2v5.0.4/bin/ld: use the --help option for usage information
collect2: ld returned 1 exit status
gmake[2]: *** [gengenrtl] Error 1

The `-YP' exists in native `ld', but not in GNU one.  That is, gcc
correctly configured itself to use to `ld' options for native one.  It
is exactly `-B$(build_tooldir)/bin/' that expands to
`-BPREFIX/i586-pc-sco3.2v5.0.4/bin/' so that gcc finds and invokes GNU
`ld' instead of native one.  Moving `PREFIX/i586-pc-sco3.2v5.0.4/bin/'
directory works around that.

If the bug was not already reopened, would do that now.


-- 


http://gcc.gnu.org/bugzilla/show_bug.cgi?id=28472

Reply via email to