I'm trying to set up a cross-compiler for ARM. I followed this tutorial and I'm at the point now where I can run the cross compiler and get:

arm-unknown-eabi-gcc (GCC) 4.8.4 Copyright (C) 2013 Free Software
Foundation, Inc. This is free software; see the source for copying
conditions.  There is NO warranty; not even for MERCHANTABILITY or

But when I try to ./configure Dropbear (the software I'm trying to compile) I get an error:

checking for gcc... /home/josh/opt/cross/bin/arm-unknown-eabi-gcc
checking whether the C compiler works... no
configure: error: in `/home/josh/src/dropbear-2016.74':
configure: error: C compiler cannot create executables
See `config.log' for more details

I believe this is because I don't yet have a standard library for the target system, because the tutorial I was following mentions:

Note how this compiler is not able to compile normal C programs. The cross-compiler will spit errors whenever you want to #include any of the standard headers (except for a select few that actually are platform-independent, and generated by the compiler itself). This is quite correct - you don't have a standard library for the target system yet!

How can I obtain/build a standard library for my target?

  • 2
    A common standard library on embedded systems is uClibc.
    – user4443
    Sep 29, 2016 at 5:11
  • 1
    You could follow the LFS build. It constructs a gcc and glibc that are detached from the libraries it were compiled with.
    – grochmal
    Sep 30, 2016 at 1:00

1 Answer 1


I ended up solving this by deleting all my manually built cross compiler stuff and just doing sudo apt-get install gcc-arm-linux-gnueabi, which seems to work out of the box.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .