julvr wrote:
>
> I'm trying to upgrade the toolchain and I'm getting the following errors
> when I build:
>
> With output:
> /opt/toolchains/uclibc-crosstools-gcc-4.3.4/usr/lib/libc.a(__uClibc_main.os):
> In function `__uClibc_fini':
> __uClibc_main.c:(.text+0x20): undefined reference to `__fini_array_start'
> __uClibc_main.c:(.text+0x24): undefined reference to `__fini_array_end'
> /opt/toolchains/uclibc-crosstools-gcc-4.3.4/usr/lib/libc.a(__uClibc_main.os):
> In function `__uClibc_main':
> __uClibc_main.c:(.text+0x398): undefined reference to
> `__preinit_array_start'
> __uClibc_main.c:(.text+0x39c): undefined reference to
> `__preinit_array_end'
> __uClibc_main.c:(.text+0x3f4): undefined reference to `__init_array_start'
> __uClibc_main.c:(.text+0x3f8): undefined reference to `__init_array_end'
> /opt/toolchains/uclibc-crosstools-gcc-4.3.4/usr/bin/../lib/gcc/mips-linux-uclibc/4.3.4/../../../../mips-linux-uclibc/bin/ld:
> uclibc/libc.so.0-so: hidden symbol `__fini_array_end' isn't defined
> /opt/toolchains/uclibc-crosstools-gcc-4.3.4/usr/bin/../lib/gcc/mips-linux-uclibc/4.3.4/../../../../mips-linux-uclibc/bin/ld:
> final link failed: Nonrepresentable section on output
>
>
>>From Google, as far as I can tell, this is something to do with my
link-script. But I haven't modified the linkscript (nor do I know anything
about them). My target platform is elf32btsmip, so I'm assuming I'm using
elf32btsmip.x as a linkscript?
>
> Does anyone have any ideas what this might be, or how to go about solving
> this?
>
> Thanks
>
> John
>
> _______________________________________________
> uClibc mailing list
> [email protected]
> http://lists.busybox.net/mailman/listinfo/uclibc
>
>
Ok, not getting very far very fast with this. I've discovered that in the
compiler directory under /usr/lib, there's a file called libc.a, which, when
I do a readelf.c on, gives me this:
> /opt/toolchains/uclibc-crosstools-gcc-4.4.2-2/usr/lib> readelf -s libc.a |
> grep __fini_array_start
14: 00000000 0 NOTYPE GLOBAL HIDDEN UND __fini_array_start
I read this to mean that within libc.a, there's a reference to
__fini_array_start, but that reference is HIDDEN?? Thus when I run mklibs,
the hidden reference gets removed, and I end up with a linker error. My
question now is, how does a reference become hidden?? and what can I do
about it?
--
View this message in context:
http://old.nabble.com/Link-Error-to-__preinit_array_start-tp26078332p27127975.html
Sent from the uClibc mailing list archive at Nabble.com.
_______________________________________________
uClibc mailing list
[email protected]
http://lists.busybox.net/mailman/listinfo/uclibc