problems compiling Python, 0.9.28.2 upgrade

Hamish Moffatt hamish at cloud.net.au
Fri Feb 23 12:09:17 UTC 2007


Hi,

I'm working with the Snapgear linux distribution 3.3.0, which contains
uClibc 0.9.27. I'm trying to compile a recent Python.

I've built Python 2.4.4 with the help of a bunch of patches from around
the net (the Python sf.net bug tracker, openembedded.org) and some of my
own. However it fails many of its test cases, and notably all of the
threading tests seem to hang.

I've compiled without threading which makes those tests irrelevant, but
a lot of other test cases fail too. The float tests don't particularly
bother me (I suspect loss of precision when using -msoft-float) but
things like test_compile, test_datetime etc fail too.

Can anyone give me suggestions on what to do about this? I would ideally
like to have thread support included. Does anyone have a concise set of
patches that are proven to produce a working Python?


I've also been trying to upgrade to uClibc 0.9.28.2 in case that helps.
I dumped it into my Snapgear tree, and it compiles (although I had to
hack in __dummy_libc_stack_end), but when I link anything against it I get 
a warning such as

$ PATH=`pwd`/tools/ucfront-gcc arm-linux-gcc -msoft-float -mbig-endian test.c
/usr/local/lib/gcc/arm-linux/3.4.4/../../../../arm-linux/bin/ld: warning: ld-uClibc.so.0, needed by /home/hamish/<...>/uClibc/lib/libc.so, not found (try using -rpath or -rpath-link)

Now this is just a warning and the binaries tend to work fine. However
anything that tries to link against libdl fails at compile time due to
missing symbols (that are in ld-uClibc.so.0). That includes eg the
user/ppp_nonembed application in Snapgear, and more importantly the
dynamic loader in Python. Meaning that I can't load any .so modules in
Python (even regrtest.py won't run as math.so can't be loaded).

I'm using gcc 3.4.4. Using Snapgear 3.4.0 did not help with the uClibc
0.9.28.2 upgrade (same link warnings).

Thanks for any help.
Hamish
-- 
Hamish Moffatt VK3SB <hamish at debian.org> <hamish at cloud.net.au>



More information about the uClibc mailing list