INET Framework linker error about typeinfo for IPv6ExtensionHeader on Linux.

A linker error may occur when building INET with some versions of gcc 3.4.x on Linux. Also observed in a Debian based Ubuntu system (Breezy Badger, 64-bit).

The exact message is the following:

      typeinfo for IPv6ExtensionHeader: discarded in section
      `.gnu.linkonce.r._ZTI19IPv6ExtensionHeader' from
      collect2: ld returned 1 exit status

Another flavour of the same problem:

      ../Network/IPv6/IPv6Datagram.o: In function IPv6ExtensionHeader::extensionType() const': undefined reference to `typeinfo for IPv6ExtensionHeader' undefined reference to `typeinfo for IPv6ExtensionHeader'
      ../Network/IPv6/ more undefined references 
      to `typeinfo for IPv6ExtensionHeader' follow
      collect2: ld returned 1 exit status

I only experience this error if gcc-3.4 is used. Using gcc-4.0 (setting CC and CXX in OMNeT++'s configure.user) solves this problem for me. (vojta)


It helped us to unset the languages in Debian and INET compiled perfectly with gcc 3.3.5. Just type

      unset LANG; unset LANGUAGE

and try again. It should work like a charm then. -- Wolfgang, Thorsten

Works fine (SUSE 9.3)! One only has to re-link it (make clean not even needed). My original $LANG setting that caused the problem was en_US.UTF-8. Thanks Wolfgang! --Andras
Edit - History - Print - Recent Changes - Search
Page last modified on January 22, 2006, at 09:21 PM