This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


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

error while using arm-elf-gcc


Hi
I built a cross compiler and compiled a toy program, but I got a error like this: /home/student/wangy/eCos-arm-elf/H-i686-pc-linux-gnu/arm-elf/bin/ld: cannot open crt0.o: No such file or directory collect2: ld returned 1 exit status
My cross compiler was under /home/student/wangy/eCos-arm-elf/H-i686-pc-linux-gnu/bin, I built the cross compiler with the help of this document: http://sources.redhat.com/ecos/tools/linux-arm-elf.html but the versions of the components wad not what it provided, while I couldn't find them, I choose some upper release: binutils-2.13.tar gcc-g++-2.95.2.tar.bz2 gcc-core-2.95.2.tar.bz2 insight-5.2.1.tar.bz2 gdb-5.2.1.tar.bz2
Someone told me that maybe it was because I haven't install the glibc(or newlib), but in the toy c program, I did not use any lib function! The c program was:
int main()
{
return 0;
}

In addition, in the document "http://sources.redhat.com/ecos/tools/linux-arm-elf.html ", the newlibc or glibc was not required while build the toolchain, but in the ajunct file which also talks about how to build a arm toolchain, the glibc was required.
I tried to build the glibc, I config and make the glibc with the command:
../glibc-2.2.4/configure --target=arm-elf
--prefix=/homex/student/wangy/arm-elf-toolchain/arm-elf --enable-add-ons
make
but I got a error like:
arm-elf-gcc ../sysdeps/unix/sysv/linux/i386/sysdep.S -c -I../include -I. -I/home/student/wangy/tar-files/glibc-build/csu -I.. -I../libio -I/home/student/wangy/tar-files/glibc-build -I../sysdeps/i386/elf -I../linuxthreads/sysdeps/unix/sysv/linux/i386 -I../linuxthreads/sysdeps/unix/sysv/linux -I../linuxthreads/sysdeps/pthread -I../sysdeps/pthread -I../linuxthreads/sysdeps/unix OST http://sea1fd.sea1.hotmail.msn.com/cgi-b../linuxthreads/sysdeps/i386/i686 -I../linuxthreads/sysdeps/i386/i586 -I../sysdeps/i386/i586 -I../sysdeps/i386/i486 -I../linuxthreads/sysdeps/i386 -I../sysdeps/unix/sysv/linux/i386/i686 -I../sysdeps/unix/sysv/linux/i386 -I../sysdeps/unix/sysv/linux -I../sysdeps/gnu -I../sysdeps/unix/common -I../sysdeps/unix/mman -I../sysdeps/unix/inet -I../sysdeps/unix/sysv/i386 -I../sysdeps/unix/sysv -I../sysdeps/unix/i386 -I../sysdeps/unix -I../sysdeps/posix -I../sysdeps/i386/i686/fpu -I../sysdeps/i386/i686 -I../sysdeps/i386/fpu -I../sysdeps/i386 -I../sysdeps/wordsize-32 -I../sysdeps/ieee754/ldbl-96 -I../sysdeps/ieee754/dbl-64 -I../sysdeps/ieee754/flt-32 -I../sysdeps/ieee754 -I../sysdeps/generic/elf -I../sysdeps/generic -D_LIBC_REENTRANT -include ../include/libc-symbols.h -DHAVE_INITFINI -DASSEMBLER -I/home/student/wangy/tar-files/glibc-build/csu/. -DGAS_SYNTAX -o /home/student/wangy/tar-files/glibc-build/csu/sysdep.o
../sysdeps/unix/sysv/linux/i386/sysdep.S: Assembler messages:
../sysdeps/unix/sysv/linux/i386/sysdep.S:30: Error: unrecognized symbol type ""
../sysdeps/unix/sysv/linux/i386/sysdep.S:50: Error: unrecognized symbol type ""
../sysdeps/unix/sysv/linux/i386/sysdep.S:51: Error: bad instruction `negl %eax'
../sysdeps/unix/i386/sysdep.S:47: Error: bad instruction `pushl %eax'
../sysdeps/unix/i386/sysdep.S:49: Error: bad instruction `call __errno_location'
../sysdeps/unix/i386/sysdep.S:51: Error: bad instruction `popl %ecx'
../sysdeps/unix/i386/sysdep.S:52: Error: bad instruction `movl %ecx,(%eax)'
../sysdeps/unix/i386/sysdep.S:74: Error: bad instruction `movl $-1,%eax'
../sysdeps/unix/i386/sysdep.S:75: Error: bad instruction `ret'
make[2]: *** [/home/student/wangy/tar-files/glibc-build/csu/sysdep.o] Error 1
make[2]: Leaving directory `/home/student/wangy/tar-files/glibc-2.2.4/csu'
make[1]: *** [csu/subdir_lib] Error 2
make[1]: Leaving directory `/home/student/wangy/tar-files/glibc-2.2.4'
make: *** [all] Error 2


What to do now?
Thanks for your help!
Dam Wang




_________________________________________________________________
Ãâ·ÑÏÂÔØ MSN Explorer: http://explorer.msn.com/lccn/

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