From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2181) id 1B31D3888C4F; Thu, 21 Apr 2022 12:34:00 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org 1B31D3888C4F MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="utf-8" From: Jonathan Wakely To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc r11-9918] libstdc++: Ensure C++20 std::stringstream definitions use correct ABI X-Act-Checkin: gcc X-Git-Author: Jonathan Wakely X-Git-Refname: refs/heads/releases/gcc-11 X-Git-Oldrev: 826992807570ebb7e4caee77e6035d82d4b952d9 X-Git-Newrev: 615cc91a99aaac737739644639dd9a27b1404b4a Message-Id: <20220421123400.1B31D3888C4F@sourceware.org> Date: Thu, 21 Apr 2022 12:34:00 +0000 (GMT) X-BeenThere: libstdc++-cvs@gcc.gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Libstdc++-cvs mailing list List-Unsubscribe: , List-Archive: List-Help: List-Subscribe: , X-List-Received-Date: Thu, 21 Apr 2022 12:34:00 -0000 https://gcc.gnu.org/g:615cc91a99aaac737739644639dd9a27b1404b4a commit r11-9918-g615cc91a99aaac737739644639dd9a27b1404b4a Author: Jonathan Wakely Date: Tue Nov 30 22:04:49 2021 +0000 libstdc++: Ensure C++20 std::stringstream definitions use correct ABI The definitions of the new C++20 members of std::stringstream etc are missing when --with-default-libstdcxx-abi=gcc4-compatible is used, because all the explicit instantiations in src/c++20/sstream-inst.cc are skipped. This ensures the contents of that file are compiled with the new ABI, so the same set of symbols are exported regardless of which ABI is active by default. libstdc++-v3/ChangeLog: * src/c++20/sstream-inst.cc (_GLIBCXX_USE_CXX11_ABI): Define to select new ABI. (cherry picked from commit 56b07badf052fb140c4636f6d77cfc02d1ac357c) Diff: --- libstdc++-v3/src/c++20/sstream-inst.cc | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/libstdc++-v3/src/c++20/sstream-inst.cc b/libstdc++-v3/src/c++20/sstream-inst.cc index b3fbd6ead44..55d1fe5234d 100644 --- a/libstdc++-v3/src/c++20/sstream-inst.cc +++ b/libstdc++-v3/src/c++20/sstream-inst.cc @@ -26,7 +26,9 @@ // ISO C++ 14882: // -// Instantiations in this file are only for the new SSO std::string ABI +// Instantiations in this file are only for the new SSO std::string ABI. +#define _GLIBCXX_USE_CXX11_ABI 1 + #include #if _GLIBCXX_USE_CXX11_ABI