public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Iain D Sandoe <iains@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-5007] modula-2, driver: Handle static-libstd++ for targets without static/dynamic Date: Thu, 5 Jan 2023 12:48:11 +0000 (GMT) [thread overview] Message-ID: <20230105124811.F16463858D28@sourceware.org> (raw) https://gcc.gnu.org/g:2421470867f198c3aa57e0a7ab0d473aac4cdd38 commit r13-5007-g2421470867f198c3aa57e0a7ab0d473aac4cdd38 Author: Iain Sandoe <iain@sandoe.co.uk> Date: Thu Dec 22 19:00:13 2022 +0000 modula-2, driver: Handle static-libstd++ for targets without static/dynamic The follows the pattern used in C++ and D drivers to pass -static-libstdc++ onto the target driver to allow spec substitution of static libraries. NOTE: The handling of Bstatic/dynamic and the possible use of static libgm2 libraries is unimplemented in this driver so far. Signed-off-by: Iain Sandoe <iain@sandoe.co.uk> gcc/m2/ChangeLog: * gm2spec.cc (lang_specific_driver): Pass -static-libstdc++ on to the target driver if the linker does not support Bstatic/dynamic. Diff: --- gcc/m2/gm2spec.cc | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/gcc/m2/gm2spec.cc b/gcc/m2/gm2spec.cc index 680dd3602ef..b9a5c4e79bb 100644 --- a/gcc/m2/gm2spec.cc +++ b/gcc/m2/gm2spec.cc @@ -767,7 +767,12 @@ lang_specific_driver (struct cl_decoded_option **in_decoded_options, case OPT_static_libstdc__: library = library >= 0 ? 2 : library; +#ifdef HAVE_LD_STATIC_DYNAMIC + /* Remove -static-libstdc++ from the command only if target supports + LD_STATIC_DYNAMIC. When not supported, it is left in so that a + back-end target can use outfile substitution. */ args[i] |= SKIPOPT; +#endif break; case OPT_stdlib_:
reply other threads:[~2023-01-05 12:48 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20230105124811.F16463858D28@sourceware.org \ --to=iains@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox; as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).