[uClibc] arm-uclibc toolchain

Manuel Novoa III mjn3 at codepoet.org
Thu Dec 11 20:11:01 UTC 2003


Hello,

On Thu, Dec 11, 2003 at 02:53:35PM -0500, David Muse wrote:
> Hello,
> 
> I've been having difficulty building an arm-uclibc toolchain lately.

Personally, I'd like to see <arch>-linux-uclibc as the prefix.  But
I haven't hacked the various configure scripts to get that working.

> I have been using a uclibc-0.9.21, glibc-3.3.1 toolchain that I built from the gcc-3.3.1, but a while ago I ran into some timezone-related issues.  I posted the problem that I had to the list and Manuel responded indicating that I needed to pass the GMT offset, not just the timezone abbreviation, but also that there was a bug in uClibc that needed fixing.  Pretty soon afterward 0.9.22 came out, then 0.9.23.

Actually, 0.9.24 is due out in the very near future.

There were some other problems in 0.9.21 re the time code, which I fixed
after finding them with valgrind.  Most of those changes were in 0.9.22.
The only other change made (in cvs) is the move of a thread lock which
was in the wrong place.

> However, I've been unable to build toolchains for 0.9.22 and 0.9.23.  I tried using both of the toolchains and buildroot CVS modules, but both failed in the same way; some kind of software/hardware floating point issue while trying to link libpthread. 
> 
> Recently, I tried the gcc-3.3.x toolchain and it worked, sort of.  The build fails while installing libfloat.  It appears that TARGET_DIR is undefined, but is required by many of the .mk files in the make subdirectory.  I edited the main Makefile and
> added a TARGET_DIR and everything built, but I'm not sure it's right.

I haven't tried 'toolchain' lately, but for buildroot the libfloat stuff
is only built/installed if you have soft float support enabled.  Note
that this is an all-or-nothing setting.  If you enable soft float
support, uClibc is built in soft float mode and can't be linked with
code compiled expecting hard float.

> What I want is a complete toolchain in /opt/arm-uclibc-linux.  That way, I can make a tarball of it and install it on other machines in a standard place.  When I added TARGET_DIR to the gcc-3.3.x toolchain Makefile,  I set it to /opt/arm-uclibc-linux.  In previous toolchain Makefiles setting TARGET_DIR to /opt/arm-uclibc-linux got me what I wanted but with the gcc-3.3.x toolchain Makefile, only some of the necessary files end up in /opt/arm-uclibc-linux.  It appears that the rest of the toolchain ends up in the toolchain_arm_nofpu subdirectory of the gcc-3.3.x directory.  Should I set TARGET_DIR to that directory?  What can I do to get everything installed in /opt/arm-uclibc-linux instead?

Sounds like 'toolchain' is broken.  If I have time, i'll try it later
today.  For what it's worth though, I did buildroot builds last week
without problems.

> Another issue is soft/hard floating point.  I'm using a kernel module to do floating point emulation.  So, from the compilers perspective, I have hardware floating point support.  However, I can't figure out how to build an arm-uclibc without software floating point support.  This isn't a really big deal, I can just not use the kernel module, but it also appears that I need to specify -msoft-float on the command line every time I compile (or maybe just link) a program.  The MontaVista compiler toolchain doesn't require this.  Is there something I can do to the gcc specs file to force -msoft-float option?

You shouldn't have to do anything if soft float is not enabled.  Again,
sounds like something is broken.  Re the arm soft float stuff, I have
a gcc specs file that seems to be working nicely.  But there are still
a couple of soft-float/libfloat issues that I need to track down, as
perl failed several self-tests.

Manuel




More information about the uClibc mailing list