|
From: phil-news-nospam on 8 Jul 2008 12:22 Anyone know what these errors mean when I link dynamically? [long line warning] ==== BEGIN CAPTURE ========================================================== phil(a)faraday:/home/phil 50> gcc -O2 -o bin/electric electric.c -lm -lh /usr/lib/gcc/i486-slackware-linux/4.1.2/../../../../i486-slackware-linux/bin/ld: bin/electric: hidden symbol `__fixunsxfdi' in /usr/lib/gcc/i486-slackware-linux/4.1.2/libgcc.a(_fixunsxfdi.o) is referenced by DSO /usr/lib/gcc/i486-slackware-linux/4.1.2/../../../../i486-slackware-linux/bin/ld: final link failed: Nonrepresentable section on output collect2: ld returned 1 exit status phil(a)faraday:/home/phil 51> gcc --static -O2 -o bin/electric electric.c -lm -lh phil(a)faraday:/home/phil 52> gcc -O2 -o bin/electric electric.c /usr/lib/libc.a -lm -lh phil(a)faraday:/home/phil 53> gcc -O2 -o bin/electric electric.c -lm /usr/local/lib/libh.a phil(a)faraday:/home/phil 54> find /lib /usr/lib /usr/local/lib -type f -print | egrep '\.a|\.so' | sortpath | xargs fgrep -l __fixunsxfdi /usr/lib/gcc/i486-slackware-linux/4.1.2/adalib/libgnat.a /usr/lib/gcc/i486-slackware-linux/4.1.2/libgcc.a /usr/lib/google-earth/libgcc_s.so.1 /usr/lib/libgcc_s.so.1 /usr/lib/libkdeinit_kcalc.so /usr/lib/liblftp-tasks.a /usr/local/lib/libh.a.0.8.3 /usr/local/lib/libh.a.0.8.4 /usr/local/lib/libh.a.0.8.5 /usr/local/lib/libh.a.0.9.0 /usr/local/lib/libh.a.0.9.0.OLD /usr/local/lib/libh.so.0.8.3 /usr/local/lib/libh.so.0.8.4 /usr/local/lib/libh.so.0.8.5 /usr/local/lib/libh.so.0.9.0 /usr/local/lib/libh.so.0.9.0.OLD phil(a)faraday:/home/phil 55> ==== END CAPTURE ============================================================ At number 50 both libc and libh are dynamically linked and the linking fails. At number 51 -static is specified and linking succeeds (presuambly everything is statically linked. With either libc and libh manually provided statically, the linking also succeeds (52 and 53). It seems this symbol __fixunsxfdi is linked into libc and libh, both. Could the fact that it is in both be the cause? How can I get it out of libh? What is __fixunsxfdi for, anyway? gcc (GCC) 4.1.2 GNU C Library stable release version 2.5, by Roland McGrath et al. Copyright (C) 2006 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. Compiled by GNU CC version 4.1.2. Compiled on a Linux >>2.6.21.5<< system on 2007-06-19. Available extensions: crypt add-on version 2.1 by Michael Glad and others GNU Libidn by Simon Josefsson GNU libio by Per Bothner NIS(YP)/NIS+ NSS modules 0.19 by Thorsten Kukuk Native POSIX Threads Library by Ulrich Drepper et al BIND-8.2.3-T5B Thread-local storage support included. When I do these linkages on an older Slackware system with gcc 3.4.6 and glibc 2.3.6 it works fine. Building libh on both systems works fine, as well. I'm curious what I did in the library to have caused __fixunsxfdi to be there, at least in the way that interferes with linking. -- |WARNING: Due to extreme spam, googlegroups.com is blocked. Due to ignorance | | by the abuse department, bellsouth.net is blocked. If you post to | | Usenet from these places, find another Usenet provider ASAP. | | Phil Howard KA9WGN (email for humans: first name in lower case at ipal.net) |
|
Pages: 1 Prev: Questions about getopt() (Linux) Next: interposing library calls - here is another one |