This is the mail archive of the gcc-help@gcc.gnu.org mailing list for the GCC project.


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

Diagnosing linker errors?


I'm trying to figure out why I can't build Thunderbird with gcc 3.4.5
but I don't know enough about how linking works.

I'm getting this linker error with gcc 3.4.5 but not with 3.3.6:
/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/../../../../i686-pc-linux-gnu/bin/ld: warning: creating a DT_TEXTREL in object.
/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/../../../../i686-pc-linux-gnu/bin/ld:
../../content/xul/templates/src/libgkconxultmpl_s.a(nsXULTemplateBuilder.o)(.gnu.linkonce.t._ZN8nsTArrayIP18nsTemplateQuerySetEC1Ev+0x10): unresolvable relocation against symbol `nsTArray_base::sEmptyHdr'
/usr/lib/gcc/i686-pc-linux-gnu/3.4.5/../../../../i686-pc-linux-gnu/bin/ld: final link failed: Nonrepresentable section on output

That problem symbol is defined in the object nsTArray.o, so I tried
comparing that file generated by the two different compilers, and I
noticed at least one difference.

#objdump -rC nsTArray.o | grep EmptyHdr
00000010 R_386_GOTOFF      nsTArray_base::sEmptyHdr
                  ^^^
In the version generated by gcc 3.3.6 that GOTOFF is replaced by GOT32.

Could that difference be causing my link error?  If so, how would I
go about finding out why this difference happens?

Thanks for any clues!



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