This is the mail archive of the crossgcc@sources.redhat.com mailing list for the crossgcc project.

See the CrossGCC FAQ for lots more information.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

__register_frame_info glibc incompatibility


I just ran into a famous old problem.  I compiled hello, world with
my new compilers for ppc and sh4.  The ppc one ran fine, but the sh4
one failed to run, saying
./sh4-unknown-linux-gnu-hello: error while loading shared libraries: ./sh4-unknown-linux-gnu-hello: symbol __register_frame_info, version GLIBC_2.2 not defined in file libc.so.6 with link time reference

A little google searching showed a workaround: run with LD_PRELOAD=register_frame_info_fix.so
after building that shared library as follows:

::::::::::::::
register_frame_info_fix.sh
::::::::::::::
#!/bin/sh
# give a gcc as the 1st argument, cflags as 2nd arg
$1 $2 -shared -o register_frame_info_fix.so register_frame_info_fix.c
::::::::::::::
register_frame_info_fix.c
::::::::::::::
/* See
 * http://www.linuxhq.com/lnxlists/linux-gcc/lg_9902/msg00044.html
 * http://www.informatik.uni-oldenburg.de/~joey/Linux/Tips+Tricks/register-frame.html
 * http://www.rtems.com/rtems/maillistArchives/rtems-snapshots/1999/december/msg00078.html
 * http://lists.debian.org/lsb-spec/1999/lsb-spec-199903/msg00002.html
 * http://freestandards.org/pipermail/lsb-test/2002-January/000649.html
 */
__register_frame_info() {}
__deregister_frame_info() {}
::::::::::::::

Even after reading about the issue, I'm still a bit mystified as to
why my old sh4 glibc (which I built myself last year) doesn't export
that symbol.

Next step is, I suppose, for me to try running my hello, world program
with my new glibc, which almost certainly will export that symbol
and make this problem go away.

Does anyone recall any source of wisdom about this issue beyond the
links I gave above?

- Dan

--
Dan Kegel
http://www.kegel.com
http://counter.li.org/cgi-bin/runscript/display-person.cgi?user=78045


------ Want more information? See the CrossGCC FAQ, http://www.objsw.com/CrossGCC/ Want to unsubscribe? Send a note to crossgcc-unsubscribe@sources.redhat.com


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]