More build oddities

Nigel Spon nigel at adi.co.nz
Thu Apr 10 04:33:16 UTC 2008


On 10/04/2008, at 4:17 PM, Ralf Corsepius wrote:
>  Did you build newlib simultaneously to gcc?
> - Did you apply rtems's gcc and newlib patches?
>  For powerpc targets, they matter.
> - Did you build gcc multilib'ed?



I'm afraid I'm rather new to this and I don't know if I built newlib  
simultaneously or built gcc multilib'ed, I just followed the  
directions in the Getting Started pdf for RTEMS 4.8.

I started with the following set of archives and patches and applied  
the patches (successfully) before building:

binutils-2.17.tar.gz			
newlib-1.15.0.tar.gz
gcc-4.1.1.tar.bz2

binutils-2.17-rtems4.8-20061021.diff
gcc-core-4.1.1-rtems4.8-20070201.diff
newlib-1.15.0-rtems4.8-20071221.diff



I'm using a script to build the toolchain which looks like this:

CPU=powerpc
RTEMS_VERSION=4.8
BINUTILS_VERSION=2.17
GCC_VERSION=4.1.1

TARGET=$CPU-rtems$RTEMS_VERSION
TOPDIR=$PROJECT_DIR/..
TOOLDIR=$TOPDIR/tools

cd $BUILD_ROOT
if [ ! -e bin ]
then
	echo "\n\nBuilding binutils..."
	mkdir b-binutils
	cd b-binutils
	$TOOLDIR/binutils-$BINUTILS_VERSION/configure --target=$TARGET -- 
prefix=$BUILD_ROOT
	make all
	make info
	make install
fi

PATH=$PATH:$BUILD_ROOT/bin

cd $BUILD_ROOT
if [ ! -e bin/$TARGET-gcc ]
then
	echo "\n\n\nBuilding gcc"
	mkdir b-gcc
	cd b-gcc
	$TOOLDIR/gcc-$GCC_VERSION/configure --target=$TARGET --prefix= 
$BUILD_ROOT \
			--with-gnu-as --with-gnu-ld --with-newlib --verbose --enable- 
threads --enable-languages="c,c++"
	make all
	make info
	make install
fi



---
"Next week, the tale of some English balloonists who ascended to a  
height of seven miles in 1862, without washing."

Michael Hamel
ADInstruments Ltd, Dunedin, NZ




More information about the users mailing list