This is the mail archive of the crossgcc@sourceware.org mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

trouble with eglibc for p2020


Hi,
This is my first foray into the world of embedded linux so I hope if I
ask too many stupid questions you won't get too impatient.
I am trying to build a toolchain for freescale p2020 which has two
e500 cores (I think v2 but not sure).
I have built binutils installed kernel headers and built the bootstrap
gcc and now I am having trouble with eglibc.
I am following loosely 'building embedded linux systems', however as
the software suggested there is rather outdated I attempted to follow
the elfs instructions.

My environment variables I set to:

export PROJECT=P2020RDB
export PRJROOT=/home/${USER}/embed_devel/${PROJECT}
export TARGET=powerpc-linux-gnuspe
export HOST=x86_64-cross-linux-gnu
export PREFIX=${PRJROOT}/tools
export TARGET_PREFIX=${PREFIX}/${TARGET}
export PATH=${PREFIX}/bin:${PATH}

I setup binutils like this:
../binutils-2.21/configure -target=$TARGET -prefix=$PREFIX --with-sysroot
 =/home/wfedorko/embed_devel/P2020RDB/rootfs/
and make:
make CFLAGS="-Os -w"
(the flags I found on some website - don't think these are essential)

headers:
cd linux-2.6.37.1/
make mrproper
make headers_check
make INSTALL_HDR_PATH=/home/wfedorko/embed_devel/P2020RDB/rootfs/usr/include
headers_install
make INSTALL_HDR_PATH=/home/wfedorko/embed_devel/P2020RDB/rootfs/usr
headers_install


bootstrap gcc:

  cd ../gcc-obj/
 ../gcc-4.5.2/configure --build=${HOST} --host=${HOST} -target=$TARGET
-prefix=$PREFIX --with-local-prefix=$PREFIX --disable-nls
--disable-shared
-with-sysroot=/home/wfedorko/embed_devel/P2020RDB/rootfs/
--without-headers --with-newlib --disable-decimal-float
--disable-libgomp --disable-libmudflap --disable-libssp
--disable-threads --enable-languages=c --disable-multilib
 make all-gcc all-target-libgcc
 make install-gcc install-target-libgcc


For eglibc I follow almost exactly:
http://cross-lfs.org/view/svn/ppc/cross-tools/eglibc.html
except that the paths need additional libc after eglibc-2.12
I also tried with eglibc-2.13 with the same result.

when I make I get this:
make[2]: Entering directory
`/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13/libc/stdlib'
powerpc-linux-gnuspe-gcc
../sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S -c
-I../include -I/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build/stdlib
-I/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build
-I../sysdeps/powerpc/powerpc32/elf -I../sysdeps/powerpc/elf
-I../sysdeps/unix/sysv/linux/powerpc/powerpc32/fpu
-I../sysdeps/powerpc/powerpc32/fpu
-I../nptl/sysdeps/unix/sysv/linux/powerpc/powerpc32
-I../sysdeps/unix/sysv/linux/powerpc/powerpc32
-I../nptl/sysdeps/unix/sysv/linux/powerpc
-I../sysdeps/unix/sysv/linux/powerpc -I../sysdeps/ieee754/ldbl-128ibm
-I../sysdeps/ieee754/ldbl-opt -I../nptl/sysdeps/unix/sysv/linux
-I../nptl/sysdeps/pthread -I../sysdeps/pthread
-I../sysdeps/unix/sysv/linux -I../sysdeps/gnu -I../sysdeps/unix/common
-I../sysdeps/unix/mman -I../sysdeps/unix/inet
-I../nptl/sysdeps/unix/sysv -I../sysdeps/unix/sysv
-I../sysdeps/unix/powerpc -I../nptl/sysdeps/unix -I../sysdeps/unix
-I../sysdeps/posix -I../sysdeps/powerpc/powerpc32
-I../sysdeps/wordsize-32 -I../sysdeps/powerpc/fpu
-I../nptl/sysdeps/powerpc -I../sysdeps/powerpc
-I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32
-I../sysdeps/ieee754 -I../sysdeps/generic/elf -I../sysdeps/generic
-I../nptl  -I.. -I../libio -I. -nostdinc -isystem
/home/wfedorko/embed_devel/P2020RDB/tools/lib/gcc/powerpc-linux-gnuspe/4.5.2/include
-isystem /home/wfedorko/embed_devel/P2020RDB/tools/lib/gcc/powerpc-linux-gnuspe/4.5.2/include-fixed
-isystem /home/wfedorko/embed_devel/P2020RDB/rootfs/usr/include
-D_LIBC_REENTRANT -include ../include/libc-symbols.h       -DASSEMBLER
 -Wa,--noexecstack   -o
/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build/stdlib/getcontext.o
-MD -MP -MF /home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build/stdlib/getcontext.o.dt
-MT /home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build/stdlib/getcontext.o
../sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S: Assembler messages:
../sysdeps/unix/sysv/linux/powerpc/powerpc32/getcontext.S:41: Error:
unsupported relocation against __NR_swapcontext
make[2]: *** [/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13-build/stdlib/getcontext.o]
Error 1
make[2]: Leaving directory
`/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13/libc/stdlib'
make[1]: *** [stdlib/subdir_lib] Error 2
make[1]: Leaving directory
`/home/wfedorko/embed_devel/P2020RDB/build/eglibc-2.13/libc'
make: *** [all] Error 2

Any clue how I can avoid this? Is there anything else I am doing wrong?

Thanks,
Wojtek

--
For unsubscribe information see http://sourceware.org/lists.html#faq


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]