Hi Jonathan,
>>>diff --git a/libstdc++-v3/config/abi/pre/gnu.ver
>>>b/libstdc++-v3/config/abi/pre/gnu.ver
>>>index 06892cd2d18..bf4d7338cb6 100644
>>>--- a/libstdc++-v3/config/abi/pre/gnu.ver
>>>+++ b/libstdc++-v3/config/abi/pre/gnu.ver
>>>@@ -2628,6 +2628,10 @@ GLIBCXX_3.4.36 {
>>>
>>>
>>> _ZNSt6chrono8__detail25__recent_leap_second_infoERNS_16leap_second_infoEj;
>>>
>>>+ # basic_string::allocate_at_least
>>>+
>>>_ZNSt7__cxx1112basic_stringI[cw]St11char_traitsI[cw]ESaI[cw]EE*_S_allocate_*;
>>>+
>>>_ZNSt7__cxx1112basic_stringI[cw]St11char_traitsI[cw]ESaI[cw]EE*_M_create_*;
>
> this part broke the Solaris build:
>
> ld: fatal: libstdc++-symbols.ver-sun: 7568: symbol
> '_ZNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEE19_M_create_and_placeEjj':
> symbol version conflict
> ld: fatal: libstdc++-symbols.ver-sun: 7570: symbol
> '_ZNSt7__cxx1112basic_stringIwSt11char_traitsIwESaIwEE19_M_create_and_placeEjj':
> symbol version conflict
>
> Both symbols are matched in GLIBCXX_3.4.21 and GLIBCXX_3.4.36:
>
> ##_ZNSt7__cxx1112basic_stringI[cw]St11char_traitsI[cw]ESaI[cw]EE1[68-9]*
> (glob)
>
> ##_ZNSt7__cxx1112basic_stringI[cw]St11char_traitsI[cw]ESaI[cw]EE*_M_create_*
> (glob)
>
> Changing the first to
>
> ##_ZNSt7__cxx1112basic_stringI[cw]St11char_traitsI[cw]ESaI[cw]EE1[68]*
> (glob)
>
> (i.e. omitting 9 from the final char set) allows the build to continue.
the patch also broke the Rust build on Linux/x86_64:
/var/gcc/regression/master/6.17.13-gcc-gas-gld/build/prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/basic_string.tcc:439:23:
error: unused variable '__limit' [-Werror=unused-variable]
Guarding the second definition of __limit like
diff --git a/libstdc++-v3/include/bits/basic_string.tcc
b/libstdc++-v3/include/bits/basic_string.tcc
--- a/libstdc++-v3/include/bits/basic_string.tcc
+++ b/libstdc++-v3/include/bits/basic_string.tcc
@@ -435,7 +435,7 @@ _GLIBCXX_BEGIN_NAMESPACE_VERSION
#ifdef __glibcxx_allocate_at_least // C++23
const size_type __limit = (__STDCPP_DEFAULT_NEW_ALIGNMENT__ - 1) /
sizeof(_CharT);
-#else
+#elif __cpp_exceptions
const size_type __limit = 0;
#endif
const size_type __length = length();
allows the build to continue, but it still fails later:
prev-x86_64-pc-linux-gnu/libstdc++-v3/include/bits/char_traits.h:432:56: error:
'void* __builtin_memcpy(void*, const void*, long unsigned int)' accessing
18446744073709551609 or more bytes at offsets 0 and 0 overlaps
9223372036854775795 bytes at offset -9223372036854775802 [-Werror=restrict]
432 | return static_cast<char_type*>(__builtin_memcpy(__s1, __s2,
__n));
Rainer
--
-----------------------------------------------------------------------------
Rainer Orth, Center for Biotechnology, Bielefeld University