winlibs_mingw
winlibs_mingw copied to clipboard
<typeinfo> has an issue with clang when -static-libstdc++
issue: operator== symbol get duplicated on linking phase when compile with -static-libstdc++
on clang target x86_64-w64-windows-gnu
workaround: by conditioning __clang__
with always inline attribute as seen in
Issues when building with clang (duplicate libstdc++.a symbols) https://github.com/msys2/MINGW-packages/issues/1677#issuecomment-242980310
Do you mean errors like this:
C:\mingw64\lib\libstdc++.a(bad_alloc.o): duplicate section `.rdata$_ZTSSt9exception[_ZTSSt9exception]' has different size
I get this when trying to build third-party software. Anything I can do?
I have the same problem. Hundreds of "sections of different size" and occasionally multiple definitions of operator == for type_info.
ld: C:/msys64/mingw64/lib\libstdc++.a(tinfo.o):(.text$_ZNKSt9type_infoeqERKS_+0x0): multiple definition of `std::type_info::operator==(std::type_info const&) const'; CMakeFiles/dm2.dir/src/script/script_f_map.cpp.obj:C://msys64/mingw64/include/c++/12.2.0/typeinfo:194: first defined here