[uClibc]Question on building shared objects -- possible bug

Joel Coltoff joel at wmi.com
Thu Oct 10 14:39:50 UTC 2002

I've finally had some success in building a shared object to use
with dlopen() on a mipsel system. I still get into trouble (segfault)
when I try to call a function even if the function is in the same
source file as the one I called. I can call all my functions from
my test app. What is the correct incantation for creating my files?
This is what I'm using.

    mipsel-uclibc-gcc -fno-strict-aliasing -rdynamic -fPIC -o test test.c -ldl
    mipsel-uclibc-gcc -fno-strict-aliasing -fPIC -c mylib.c
    mipsel-uclibc-ld -shared -o mylib.so mylib.o

Is this a bug? The file libc/misc/internals/interp.c looks like

	#ifdef HAVE_ELF

but there is no include of features.h nor is there a -DHAVE_ELF on
the compile command.

Joel Coltoff

If I had my life to live again, I'd make the same mistakes, only sooner.
    -- Tallulah Bankhead

More information about the uClibc mailing list