Busybox Syntax error: word unexpected (expecting ")")
Hi,
When I tried compile an simple hello world program on ARM9 board by using Busybox 1.15.3, I am getting the error, Syntax error: word unexpected (expecting ")") "file busybox" output:: busybox: ELF 32-bit LSB executable, ARM, version 1, statically linked, for GNU/Linux 2.4.3, stripped "file Hello" output:: hello: ELF 32-bit LSB executable, ARM, version 1 (SYSV), dynamically linked (uses shared libs), for GNU/Linux 2.6.14, not stripped Help me solve the issue. -Prakash |
Probably would be a good idea to show us the source code of this program you're trying to compile; the error might be just as simple as it reads: You're missing a ")" somewhere. Shouldn't be hard to spot, but it would help to see the code.
|
Hi,
Its an simple hello world program using by C language. /********************************/ #include<stdio.h> void main() { printf("Hello world\n"); } /*******************************/ Tested the above program in x86. Its working fine. I guess there is something wrong to the library links. It is not helpful for me, http://www.mail-archive.com/uclibc@u.../msg03394.html -Prakash |
Hm, that is odd.
Not sure what to suggest, but the program compiled and ran for me (yes, totally different architecture), and here's the `file` and `ldd` info, in case it helps at all: Code:
sasha@reactor: gcc -o hello hello.c |
Thanks for the hint.
Seems, the binary on ARM is looking for some libraries. I tried the same ldd for ARM version of hello executable. But getting the error, ldd: exited with unknown exit code (126) -Prakash |
This is something like binaries incompatibility, IMHO nothing to deal with busybox, busybox is just a light version of useful tools for embedded system. I'll look to the cross-compiler version used for the libc of your target and the libc you're linking your application with....
|
[Solved]
You are correct.
I copied the libc and ld-linux library from the arm cross-compiler libc into my target root filesystems /lib. Now the program is working fine. -Prakash |
All times are GMT -5. The time now is 05:35 PM. |