This is my script which is basicly everything the tutorial says to do in one file.
Code: Select all
#!/bin/sh
echo building GMP
cd /usr/src
mkdir build-gmp
cd build-gmp
../gmp-5.0.1/configure --prefix=/usr/local
make all install
echo building MPFR
cd /usr/src
mkdir build-mpfr
cd build-mpfr
../mpfr-2.4.2/configure --prefix=/usr/local
make all install
export PREFIX=/usr/cross
export TARGET=i586-elf
cd /usr/src
mkdir build-binutils build-gcc
echo building binutils
cd /usr/src/build-binutils
../binutils-2.9/configure --target=$TARGET --prefix=$PREFIX --disable-nls
make all
make install
echo building gcc
cd /usr/src/build-gcc
export PATH=$PATH:$PREFIX/bin
../gcc-4.4.3/configure --target=$TARGET --prefix=$PREFIX --disable-nls \
--enable-languages=c,c++ --without-headers
make all-gcc
make install-gcc
echo building libgcc
make all-target-libgcc
make install-target-libgcc
Code: Select all
checking for correct version of gmp.h... yes
checking for correct version of mpfr.h... no
configure: error: Building GCC requires GMP 4.1+ and MPFR 2.3.2+.
Try the --with-gmp and/or --with-mpfr options to specify their locations.
Copies of these libraries' source code can be found at their respective
hosting sites as well as at ftp://gcc.gnu.org/pub/gcc/infrastructure/.
See also http://gcc.gnu.org/install/prerequisites.html for additional info.
If you obtained GMP and/or MPFR from a vendor distribution package, make
sure that you have installed both the libraries and the header files.
They may be located in separate packages.
make: *** No rule to make target `all-gcc'. Stop.
make: *** No rule to make target `install-gcc'. Stop.
when I look in the build-mpfr directory there is only one file, the config.log but nothing else. What can I do to get a working cross-compiler? I am using cygwin by the way.