From 678d1d63de5ecf1b650dab10115fe22e7efb900f Mon Sep 17 00:00:00 2001 From: vasilito Date: Mon, 29 Jun 2026 14:24:15 +0300 Subject: [PATCH] =?UTF-8?q?fix:=20prefix=20=E2=80=94=20also=20patch=20basi?= =?UTF-8?q?c=5Fstring.h=20stold(strtold)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mk/prefix.mk | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mk/prefix.mk b/mk/prefix.mk index 97c9c33fb7..7ce734415b 100644 --- a/mk/prefix.mk +++ b/mk/prefix.mk @@ -116,7 +116,11 @@ else # Fix GCC 13 — relibc declares but doesn't implement strtold (long double). # GCC was built with _GLIBCXX_USE_C99_STDLIB=1 but relibc lacks the symbol. # Remove 'using ::strtold' from the C++ stdlib header to prevent compile errors. - sed -i '/using ::strtold;/d; /using ::__gnu_cxx::strtold;/d' "$(PREFIX)/gcc-install/$(GNU_TARGET)/include/c++"/*/cstdlib 2>/dev/null || true +# Also remove stold() from basic_string.h which references std::strtold. + export _GCC_CSTDLIB="$(PREFIX)/gcc-install/$(GNU_TARGET)/include/c++"/*/cstdlib; \ + sed -i '/using ::strtold;/d; /using ::__gnu_cxx::strtold;/d' $$_GCC_CSTDLIB 2>/dev/null || true; \ + STRHDR="$(PREFIX)/gcc-install/$(GNU_TARGET)/include/c++"/*/bits/basic_string.h; \ + sed -i '/inline long double/,/^#endif \/\/ _GLIBCXX_USE_C99_STDLIB/{ /stold(/,/^#endif/d; }' $$STRHDR 2>/dev/null || true # Propagate fresh relibc artifacts to the redoxer toolchain at # ~/.redoxer//toolchain/. The redoxer ships its own sysroot # snapshot from initial setup; without this sync the GCC driver inside