Note that there are some explanatory texts on larger screens.

plurals
  1. POCross Compiling for Arm armv5tejl
    primarykey
    data
    text
    <p>I am trying to cross compile a simple hello world program for a linux system.</p> <p>I have the following information:</p> <pre><code>uname -a Linux (none) 2.6.32.28 #130 PREEMPT Mon Feb 18 13:54:18 CST 2013 armv5tejl GNU/Linux cat /proc/cpuinfo Processor : ARM926EJ-S rev 5 (v5l) BogoMIPS : 421.06 Features : swp half fastmult edsp java CPU implementer : 0x41 CPU architecture: 5TEJ CPU variant : 0x0 CPU part : 0x926 CPU revision : 5 Hardware : KeyASIC Ka2000 EVM Revision : 0000 Serial : 0000000000000000 </code></pre> <p>I would like to know how to cross compile for this system. I have tried the following:</p> <ul> <li>arm-linux-gnueabi-gcc helloworld.c -march=armv5 -o helloworld</li> <li>arm-linux-gnueabi-gcc helloworld.c -mcpu=arm926ej-s -o helloworld</li> </ul> <p>But when I try and run the executable I get the error message "command not found". I am probably not compiling it correctly but I don't know what compile options to use given the information I have.</p> <p>(I know the helloworld.c is all working).</p> <pre><code>ls -l helloworld -rwxr-xr-x 1 0 0 8428 Jan 1 00:00 helloworld which helloworld which: applet not found </code></pre> <p>I put busybox-armv5l on</p> <pre><code>busybox which helloworld (no output) </code></pre> <p>ldd is also not on the system I am trying to compile for (its the transcend WifiSD card).</p> <pre><code>ls -ln /lib/libc* -rwxrwxrwx 1 0 0 244279 Jan 19 2012 /lib/libc.so.0 -rwxrwxrwx 1 0 0 13043 Jan 19 2012 /lib/libcrypt.so.0 -rwxr-xr-x 1 0 0 1251776 Jan 1 00:00 /lib/libcrypto.so.0.9.8 </code></pre> <p>I tried to run /lib/libc.so.0 to get version information and I got a segmentation fault. It seems compiling with -static fixed the issue. So I guess it was an issue with the libc library. Thank you for the help.</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload