[uClibc] toolchain & buildroot script summary

Bryan Larsen bryan.larsen at lumenera.com
Tue Jul 13 05:38:25 UTC 2004


I'm trying various combinations.  Some work, some don't.  Here is a
summary of my results.  Details are in other emails.

Here's my base configuration:

ARCH:=arm
USE_UCLIBC_SNAPSHOT:=true
BUILD_WITH_LARGEFILE:=false
OPTIMIZE_FOR_CPU=$(ARCH)
SOFT_FLOAT:=false
GCC_USE_SJLJ_EXCEPTIONS:=--enable-sjlj-exceptions
EXTRA_GCC_CONFIG_OPTIONS:=
ENABLE_LOCALE:=false
MULTILIB:=--enable-multilib
INSTALL_LIBSTDCPP:=true

and then I varied the following parameters:
SOFT_FLOAT
USE_UCLIBC_SNAPSHOT
build machine: Linux or OS X
builroot or toolchain.

linux/buildroot/!SOFT_FLOAT/SNAPSHOT: successful

linux/buildroot/SOFT_FLOAT/SNAPSHOT:  sucessful.
It built a Snapgear Linux image.  The image couldn't load init, but
that's probably my problem, not yours.

linux/toolchain/!SOFT_FLOAT/SNAPSHOT: success.
Can build a Snapgear Linux image, and can build a static C++ program
linked against the toolchain's libc, but fails with "hidden symbol
`__udivsi3' in libgcc.a(_udivsi3.oS) is referenced by DSO" when trying
to build against Snapgear 3.1.1's uClibc 0.9.26.

linux/toolchain/SOFT_FLOAT/SNAPSHOT:
must define TARGET_DIR

linux/toolchain/!SOFT_FLOAT/RELEASE:

first I had to patch ioperm.c as described earlier.  Then:

configure:2448: checking whether the C compiler (
/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_build_arm/gcc-3.3-final/gcc/xgcc -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_build_arm/gcc-3.3-final/gcc/ -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/bin/ -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/lib/ -isystem /opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/include -g -Os ) works
configure:2464:
/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_build_arm/gcc-3.3-final/gcc/xgcc -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_build_arm/gcc-3.3-final/gcc/ -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/bin/ -B/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/lib/ -isystem /opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/include -o conftest -g -Os   conftest.c  1>&5
/opt/toolchain.fpu.release/gcc-3.3.x/toolchain_arm/arm-linux-uclibc/bin/ld: conftest: hidden symbol `__udivsi3' in /opt/toolchain.fpu.release/gcc-3.3.x/toolchain_build_arm/gcc-3.3-final/gcc/libgcc.a(_udivsi3.oS) is referenced by DSO
collect2: ld returned 1 exit status
configure: failed program was:

#line 2459 "configure"
#include "confdefs.h"

main(){return(0);}

linux/toolchain/SOFT_FLOAT/RELEASE:

same error as !SOFT_FLOAT/RELEASE

linux/buildroot/!SOFT_FLOAT/RELEASE:

same error as toolchain/RELEASE

os x/toolchain/!SOFT_FLOAT/SNAPSHOT: successful with fixes sent earlier

os x/toolchain/SOFT_FLOAT/SNAPSHOT: ranlib problem described earlier

os x/buildroot/!SOFT_FLOAT/SNAPSHOT: successful: fails when building
genext2fs, but that means the toolchain part built succesfully

os x/buildroot/SOFT_FLOAT/SNAPSHOT: ranlib problem described earlier


With my successful toolchains, I can build a working Snapgear Linux
3.1.1 image.  I can also build a C++ program doing a static link against
the toolchain's libc & libstdc++.

The next step is to build a C++ program against the uClibc-0.9.26
included in Snapgear 3.1.1 or to port current uClibc into my snapgear
development tree.

Right now the former is failing with the DSO error (see above), and the
latter is crashing inside lsmod.

cheers,
Bryan






More information about the uClibc mailing list