From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: by sourceware.org (Postfix, from userid 2140) id B69B03835765; Wed, 22 Jun 2022 05:22:44 +0000 (GMT) DKIM-Filter: OpenDKIM Filter v2.11.0 sourceware.org B69B03835765 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: Alexandre Oliva To: gcc-cvs@gcc.gnu.org, libstdc++-cvs@gcc.gnu.org Subject: [gcc(refs/users/aoliva/heads/testme)] libstdc++: testsuite: use -lbsd for net_ts on RTEMS X-Act-Checkin: gcc X-Git-Author: Alexandre Oliva X-Git-Refname: refs/users/aoliva/heads/testme X-Git-Oldrev: ccb50093fa082ae5551c60f18cb74da277292322 X-Git-Newrev: 9ed71d6e0d61623bbc1f18694946323230b6531e Message-Id: <20220622052244.B69B03835765@sourceware.org> Date: Wed, 22 Jun 2022 05:22:44 +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: Wed, 22 Jun 2022 05:22:44 -0000 https://gcc.gnu.org/g:9ed71d6e0d61623bbc1f18694946323230b6531e commit 9ed71d6e0d61623bbc1f18694946323230b6531e Author: Alexandre Oliva Date: Mon Jun 20 20:44:05 2022 -0300 libstdc++: testsuite: use -lbsd for net_ts on RTEMS Networking functions that net_ts tests rely on are defined in libbsd on RTEMS, so link with it. for libstdc++-v3/ChangeLog * testsuite/lib/dg-options.exp (add_options_for_net_ts): Add -lbsd for RTEMS targets. Diff: --- libstdc++-v3/testsuite/lib/dg-options.exp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/libstdc++-v3/testsuite/lib/dg-options.exp b/libstdc++-v3/testsuite/lib/dg-options.exp index 203bb0dfed5..15f37da468a 100644 --- a/libstdc++-v3/testsuite/lib/dg-options.exp +++ b/libstdc++-v3/testsuite/lib/dg-options.exp @@ -253,6 +253,12 @@ proc add_options_for_net_ts { flags } { # libsocket and libnsl for networking applications. if { [istarget *-*-solaris2*] } { return "$flags -lsocket -lnsl" + } elseif { [istarget *-*-rtems*] } { + # Adding -Wl,--gc-sections would enable a few more tests to + # link, but all of them fail at runtime anyway, because the + # io_context ctor calls pipe(), which always fails, and thus + # the ctor throws a system error. + return "$flags -lbsd" } return $flags }