[uClibc] Fw: I'm try to compile Python-2.3.4 by uClibc-0.9.26, but......

cwang cwang at redsonic.com
Fri Sep 17 04:53:39 UTC 2004


> Hi my friends:
>
> I'm try to compile Python-2.3.4 by uClibc-0.9.26. It works find if I link
it
> with uClibc staticly. :)
> But when I try to link it with uClibc sharely, the generated binary aways
> segment fault.
>
> Here I list the command that I used to compile the source(my uclibc
> toolchain is located in /opt/toolchain_i386').
>
> # PATH=/opt/toolchain_i386/i386-linux-uclibc/bin:$PATH
>
./configure --host=i386-linux-uclibc --build=i686-redhat-linux-gnu --prefix=
> /usr/i386-linux-ucblic/usr
> ......
> # PATH=/opt/toolchain_i386/i386-linux-uclibc/bin:$PATH make.
>
> So the binary 'python' is generated.
>
> If I use it directly, it report that Can't find '/lib/ld-uClibc.so.0'. So
I
> add -Xlinker --dynamic-linker /usr/i386-linux-uclibc/ld-uClibc.so.0 to the
> tail of the compile command. And the dynamic linked binary 'python' cause
> segment fault.
>
> Then I use gdb to check the segment fault, the binary crashed before it
> reach the main function in python code. The stack is:
>
> #0  0xbf518702 in erand48_r () from /usr/i386-linux-uclibc/lib/libc.so.0
> #1  0xbf518bbe in malloc () from /usr/i386-linux-uclibc/lib/libc.so.0
> #2  0xbf518cec in realloc () from /usr/i386-linux-uclibc/lib/libc.so.0
> #3  0xbf516dc0 in on_exit () from /usr/i386-linux-uclibc/lib/libc.so.0
> #4  0xbf538fd9 in __pthread_initialize_minimal () from
> /usr/i386-linux-uclibc/lib/libpthread.so.0
> #5  0xbf53c135 in sendto () from
/usr/i386-linux-uclibc/lib/libpthread.so.0
> #6  0xbf5357cd in _init () from /usr/i386-linux-uclibc/lib/libpthread.so.0
> #7  0x00f0104f in _dl_boot () from
/usr/i386-linux-uclibc/lib/ld-uClibc.so.0
> #8  0x00f005ba in _dl_boot () from
/usr/i386-linux-uclibc/lib/ld-uClibc.so.0
> #9  0x00000001 in ?? ()
>
> And the 'ldd python' output:
>
>         libm.so.0 => /usr/i386-linux-uclibc/lib/libm.so.0 (0xbf59a000)
>         libpthread.so.0 => /usr/i386-linux-uclibc/lib/libpthread.so.0
> (0xbf588000)
>         libdl.so.0 => /usr/i386-linux-uclibc/lib/libdl.so.0 (0xbf585000)
>         libutil.so.0 => /usr/i386-linux-uclibc/lib/libutil.so.0
(0xbf583000)
>         libc.so.0 => /usr/i386-linux-uclibc/lib/libc.so.0 (0xbf549000)
>         ld-uClibc.so.0 => /usr/i386-linux-uclibc/lib/ld-uClibc.so.0
> (0x39c000)
>
> Is this a bug in ld-uClibc.so of uclibc?
>
> It will be very helpful to build python with uClibc.
>
> If anybody is interesting about this, I'm willing to provide more details
to
> help to resolve this problem.
>
> Thanks.
>
> Charles  Sep 17.
>
>




More information about the uClibc mailing list