Bug 13225 - gcc3.3.3 Makefile changes break crosscompiling
Summary: gcc3.3.3 Makefile changes break crosscompiling
Status: RESOLVED WORKSFORME
Alias: None
Product: gcc
Classification: Unclassified
Component: bootstrap (show other bugs)
Version: 3.3.3
: P2 normal
Target Milestone: 3.3.3
Assignee: Not yet assigned to anyone
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-11-28 21:58 UTC by olh
Modified: 2005-07-23 22:49 UTC (History)
1 user (show)

See Also:
Host: powerpc-linux
Target: i686-linux,powerpc64-linux
Build: powerpc-linux
Known to work:
Known to fail:
Last reconfirmed:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description olh 2003-11-28 21:58:29 UTC
This simple script works with plain 3.3.2, but it fails with the current CVS gcc-3_3-branch.

chmod 755 ../fixinc.sh
make[2]: Leaving directory `/home/toolchain/cross-test/obj/gcc/gcc/fixinc'
The directory that should contain system headers does not exist:
  /home/toolchain/cross-test/x/lib/gcc-lib/i686-linux/3.3.2/../../../../i686-linux/sys-include
make[1]: *** [stmp-fixinc] Error 1
make[1]: *** Waiting for unfinished jobs....
make[1]: Leaving directory `/home/toolchain/cross-test/obj/gcc/gcc'
make: *** [all-gcc] Error 2
Command exited with non-zero status 2

toolchain@papaya:~> find -name sys-include
./cross-test/x/i686-linux/sys-include
toolchain@papaya:~> ls -l /home/toolchain/cross-test/x/lib/ 
total 876
-rw-r--r--    1 toolchain users      891234 Nov 28 22:53 libiberty.a
toolchain@papaya:~> 



set -ex
export CROSS=$HOME/cross-test
export CROSSP=$CROSS/x
export PATH=$CROSSP/bin:$PATH
cd      $HOME
#
rm -rf  $CROSS
mkdir   $CROSS
cd      $CROSS
#
~olaf/bin/unrpm  ~olaf/glibc-devel.rpm 
#
tar xfj ~olaf/cross-ppc64-binutils/binutils-2.14.90.0.7.tar.bz2 
cd binutils-2.14.90.0.7/
bzip2 -cd ~olaf/binutils-2.14.90.0.7-binutils-head.patch.bz2 | patch -Esp1
cd ..
tar xfj ~olaf/cross-ppc64-gcc-core/gcc-3.3.2.tar.bz2 
cd gcc-3.3.2/
gzip  -cd ~olaf/gcc-3_3-branch-20031128.diff.gz | patch -Esp0
cd ..
mkdir obj
cd obj/
mkdir binutils gcc
cd binutils/
powerpc32 $CROSS/binutils-2.14.90.0.7/configure --disable-nls --target=i686-linux --prefix=$CROSSP
make -j6
make install
cd ..
cd gcc
powerpc32 $CROSS/gcc-3.3.2/configure --disable-nls --target=i686-linux --prefix=$CROSSP --enable-languages=c --disable-shared --with-headers=$CROSS/usr/include
make -j6
make
make install
cd ..
Comment 1 Andrew Pinski 2003-11-28 22:04:55 UTC
Do not use with-headers any more, use --with-sysroot= instead, it got included for 3.3.3.
Comment 2 olh 2003-11-28 23:20:48 UTC
thanks, make sure it ends up in the release notes.

toolchain@papaya:~> ./cross-test/x/bin/i686-linux-gcc -v
Reading specs from /home/toolchain/cross-test/x/lib/gcc-lib/i686-linux/3.3.2/specs
Configured with: /home/toolchain/cross-test/gcc-3.3.2/configure --disable-nls --target=i686-linux --prefix=/home/toolchain/cross-test/x --enable-languages=c --disable-shared --with-sysroot=/home/toolchain/cross-test
Thread model: posix
gcc version 3.3.2 20031128 (prerelease)