分类: LINUX
2009-08-18 11:24:08
"out/target/product/generic/obj/lib/crtbegin-static.o:In function '__start':初步怀疑可能是交叉编译器的问题
(.text+0x14):relocation truncated to fit: R_MIPS_PC16 against '__libc_init'
collect2:ld returned 1 exit status
Status: | New | Start: | 08/18/2009 | |
Priority: | Normal | Due date: | ||
Assigned to: | - | % Done: |
0% | |
Category: | - | Spent time: | - | |
Target version: | - | |||
Description
hi guys.
when I use the cross-compile [version :4.0.4] to compile the source code,end with
error
"out/target/product/generic/obj/lib/crtbegin-static.o:In function '__start':
(.text+0x14):relocation truncated to fit: R_MIPS_PC16 against '__libc_init'
collect2:ld returned 1 exit status
so I thinks maybe the cross-compiler's version is too low, when I use the version 4.3
the issue is found too.
who can give me some support?
tangke
thanks in advance
I encountered the same error too, the toolchain which I used is generated by gentoo's crossdev.
$mipsel-softfloat-linux-gnu-gcc -v
Using built-in specs.
Target: mipsel-softfloat-linux-gnu
Configured with: /var/build/cross/mipsel-softfloat-linux-gnu/portage/cross-mipsel-softfloat-linux-gnu/gcc-4.3.4/work/gcc-4.3.4/configure --prefix=/usr --bindir=/usr/i486-pc-linux-gnu/mipsel-softfloat-linux-gnu/gcc-bin/4.3.4 --includedir=/usr/lib/gcc/mipsel-softfloat-linux-gnu/4.3.4/include --datadir=/usr/share/gcc-data/mipsel-softfloat-linux-gnu/4.3.4 --mandir=/usr/share/gcc-data/mipsel-softfloat-linux-gnu/4.3.4/man --infodir=/usr/share/gcc-data/mipsel-softfloat-linux-gnu/4.3.4/info --with-gxx-include-dir=/usr/lib/gcc/mipsel-softfloat-linux-gnu/4.3.4/include/g++-v4 --host=i486-pc-linux-gnu --target=mipsel-softfloat-linux-gnu --build=i486-pc-linux-gnu --disable-altivec --disable-fixed-point --with-float=soft --enable-nls --without-included-gettext --with-system-zlib --disable-checking --disable-werror --enable-secureplt --disable-multilib --disable-libmudflap --disable-libssp --disable-libgomp --enable-cld --disable-libgcj --enable-languages=c,c++ --with-sysroot=/usr/mipsel-softfloat-linux-gnu --disable-bootstrap --disable-libgomp --enable-__cxa_atexit --enable-clocale=gnu --with-bugurl= --with-pkgversion='Gentoo 4.3.4 p1.0, pie-10.1.5'
Thread model: posix
gcc version 4.3.4 (Gentoo 4.3.4 p1.0, pie-10.1.5)
$mipsel-softfloat-linux-gnu-ld -v
GNU ld (Linux/GNU Binutils) 2.19.51.0.9.20090606