![]() ![]() |
Mar 4 2006, 03:52 AM
Post
#1
|
|
|
Group: Members Posts: 15 Joined: 9-October 05 Member No.: 8,280 |
I'm trying to compile some world-hailing test program on my zaurus. I installed gcc and, as far as I know, everything needed. But when I'm trying to
CODE arm-linux-gcc hello.c -o hello I got an ugly CODE /usr/lib/gcc/arm-linux/3.4.3/../../../../arm-linux/bin/ld:/usr/lib/gcc/arm-linux/3.4.3/../../../libc.so: file format not recognized; treating as linker script /usr/lib/gcc/arm-linux/3.4.3/../../../../arm-linux/bin/ld:/usr/lib/gcc/arm-linux/3.4.3/../../../libc.so:4: syntax error collect2: ld returned 1 exit status Would anyone understand this? And, better, explain me why? Thanks alot. |
|
|
|
Mar 6 2006, 05:18 PM
Post
#2
|
|
|
Group: Members Posts: 29 Joined: 30-June 05 Member No.: 7,497 |
QUOTE(larrycow @ Mar 4 2006, 08:52 PM) I'm trying to compile some world-hailing test program on my zaurus. I installed gcc and, as far as I know, everything needed. But when I'm trying to CODE arm-linux-gcc hello.c -o hello I got an ugly CODE /usr/lib/gcc/arm-linux/3.4.3/../../../../arm-linux/bin/ld:/usr/lib/gcc/arm-linux/3.4.3/../../../libc.so: file format not recognized; treating as linker script /usr/lib/gcc/arm-linux/3.4.3/../../../../arm-linux/bin/ld:/usr/lib/gcc/arm-linux/3.4.3/../../../libc.so:4: syntax error collect2: ld returned 1 exit status Would anyone understand this? And, better, explain me why? Thanks alot. Hi. You should edit "/usr/lib/libc.so". From CODE /*GNU ld script Use the shared library,but some functions are only in the static library,so try that secondarily. */ OUTPUT_FORMAT(elf32-littlearm) GROUP( /lib/libc.so.6 /usr/lib/libc_nonshared.a AS_NEEDED( /lib/ld-linux.so.2) ) To CODE /*GNU ld script Use the shared library,but some functions are only in the static library,so try that secondarily. */ OUTPUT_FORMAT(elf32-littlearm) GROUP( /lib/libc.so.6 /usr/lib/libc_nonshared.a ) Bilding consists of this well in my environment . |
|
|
|
Mar 8 2006, 12:34 PM
Post
#3
|
|
|
Group: Members Posts: 15 Joined: 9-October 05 Member No.: 8,280 |
Actually, my /usr/lib/libc.so looks more like this:
CODE /* GNU ld script Use the shared library, but some functions are only in the static library, so try that secondarily. */ *** BUG in libc/scripts/output-format.sed *** elf32-bigarm,elf32-littlearm GROUP ( /lib/libc.so.6 /usr/lib/libc_nonshared.a ) I guess the BUG line can explain a lot of things, but I can't see how to work around this. |
|
|
|
Mar 9 2006, 03:03 AM
Post
#4
|
|
|
Group: Members Posts: 4,515 Joined: 25-October 03 From: Bath, UK Member No.: 464 |
|
|
|
|
Mar 29 2006, 02:45 PM
Post
#5
|
|
|
Group: Members Posts: 15 Joined: 9-October 05 Member No.: 8,280 |
I tried again on the new 3.5.4 release. Loads of packages to install, but at least it looks better (*-symlinks.ipk is the way...).
Still, I can't compile the simplest C program on Earth. Well, actually I can't link it. The linker told me that CODE root@collie:~# gcc -o hello hello.c /usr/lib/gcc/arm-linux/3.4.4/../../../../arm-linux/bin/ld: cannot find /lib/libc.so.6 inside /usr/bin/../../usr collect2: ld returned 1 exit status Would anyone have an idea? |
|
|
|
Apr 8 2006, 05:32 AM
Post
#6
|
|
![]() Group: Members Posts: 21 Joined: 15-April 04 From: Brugg, Schweiz Member No.: 2,858 |
Hoi,
I had a similar problem with libc6. You should check that you have libc6 installed. If this is already the case, you should check that libc6.so.6 is in the path ... Greetings, Georg |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 24th May 2013 - 08:51 AM |