﻿id	summary	reporter	owner	description	type	status	priority	milestone	component	version	severity	resolution	keywords	cc
1023	Perl script enhancement when readjusting the toolchain	hugo@…	Matthew Burgess	"In the section ""6.12. Readjusting the toolchain"":

If that perl script is called more than one time:
   perl -pi -e 's@ /tools/lib/ld-linux.so.2@ /lib/ld-linux.so.2@g;' \
      -e 's@\*startfile_prefix_spec:\n@$_/usr/lib/@g;' \
      `gcc --print-file specs`

The resulting specs file will look like this:
   *startfile_prefix_spec:
   /usr/lib//usr/lib/

Which gives the error
   /tools/lib/gcc/i686-pc-linux-gnu/3.4.3/../../../../i686-pc-linux-gnu/bin/ld: 
crt1.o: No such file: No such file or directory
   collect2: ld returned 1 exit status

If we add a space after the /usr/lib/ part in the perl script, it takes care of 
the problem (although the same directory can still be present multiple times):
   perl -pi -e 's@ /tools/lib/ld-linux.so.2@ /lib/ld-linux.so.2@g;' \
      -e 's@\*startfile_prefix_spec:\n@$_/usr/lib/ @g;' \
      `gcc --print-file specs`"	enhancement	closed	lowest		Book	SVN	minor	fixed		
