cross-compiling libstdc++ and typeinfo

forumer@smartmobili.com forumer@smartmobili.com
Wed Sep 10 09:37:00 GMT 2008


Hi,

I am trying to cross-compile for arm-wince platforms libstdc++.
For now I have an issue with typeinfo :

In file included from
/cygdrive/c/cygwin/home/foo/cegcc-4.3.2/src/gcc/libstdc++-v3/include/precompiled/stdc++.h:102:
/cygdrive/c/cygwin/home/foo/cegcc-4.3.2/src/gcc/libstdc++-v3/libsupc++/typeinfo:117:6:
error: #error "Inline implementation of type_info comparision requires
merging of type_info objects"

When I look at this file I can see :

#ifndef __GXX_MERGED_TYPEINFO_NAMES
  #if !__GXX_WEAK__
    // If weak symbols are not supported, typeinfo names are not merged.
    #define __GXX_MERGED_TYPEINFO_NAMES 0
  #else
    // On platforms that support weak symbols, typeinfo names are merged.
    #define __GXX_MERGED_TYPEINFO_NAMES 1
  #endif
#endif

// By default follow the same rules as for __GXX_MERGED_TYPEINFO_NAMES.
#ifndef __GXX_TYPEINFO_EQUALITY_INLINE
  #if !__GXX_WEAK__
    #define __GXX_TYPEINFO_EQUALITY_INLINE 0
  #else
    #define __GXX_TYPEINFO_EQUALITY_INLINE 1
  #endif
#endif

...

#if !__GXX_TYPEINFO_EQUALITY_INLINE
    bool before(const type_info& __arg) const;

    // In old abi, or when weak symbols are not supported, there can
    // be multiple instances of a type_info object for one
    // type. Uniqueness must use the _name value, not object address.
    bool operator==(const type_info& __arg) const;
#else
  #if !__GXX_MERGED_TYPEINFO_NAMES
    #error "Inline implementation of type_info comparision requires merging
of type_info objects"
  #endif


So it seems that __GXX_MERGED_TYPEINFO_NAMES equals 0 for my target
(arm-unknown-wince)...
How can I fix that ?










More information about the Libstdc++ mailing list