public inbox for gcc-bugs@sourceware.org help / color / mirror / Atom feed
From: "slipcon at gmail dot com" <gcc-bugzilla@gcc.gnu.org> To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/58638] libstdc++ builds as non-PIC when --with-pic is specified Date: Thu, 08 Jan 2015 14:25:00 -0000 [thread overview] Message-ID: <bug-58638-4-DhkArolvrn@http.gcc.gnu.org/bugzilla/> (raw) In-Reply-To: <bug-58638-4@http.gcc.gnu.org/bugzilla/> https://gcc.gnu.org/bugzilla/show_bug.cgi?id=58638 Scott Lipcon <slipcon at gmail dot com> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |slipcon at gmail dot com --- Comment #9 from Scott Lipcon <slipcon at gmail dot com> --- We saw the same issue with gcc 4.9.2 on x86_64 Linux - we build the compiler with --disable-shared in order to be able to deliver our software on systems without libstdc++.so. Without the patches in this issue, we were unable to link our .sos to libstdc++.a because of the missing -fPIC. The patch I ended up using was a bit different than those in the comments below, but seems to be working for our installation: --- libstdc++-v3/configure.ac.orig 2015-01-08 08:40:40.480754159 -0500 +++ libstdc++-v3/configure.ac 2015-01-08 08:43:27.633844665 -0500 @@ -120,6 +120,11 @@ glibcxx_compiler_pic_flag="$lt_prog_compiler_pic_CXX" glibcxx_compiler_shared_flag="-D_GLIBCXX_SHARED" +elif test "${with_pic+set}" = set; then + glibcxx_lt_pic_flag="-prefer-pic" + glibcxx_compiler_pic_flag="$lt_prog_compiler_pic_CXX" + glibcxx_compiler_shared_flag= + else glibcxx_lt_pic_flag= glibcxx_compiler_pic_flag= I hope this gets applied to an official release at some point.
next prev parent reply other threads:[~2015-01-08 14:25 UTC|newest] Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top 2013-10-06 3:40 [Bug libstdc++/58638] New: " skunk at iskunk dot org 2013-10-07 6:19 ` [Bug libstdc++/58638] " skunk at iskunk dot org 2013-12-04 11:29 ` hjl.tools at gmail dot com 2014-05-21 10:23 ` redi at gcc dot gnu.org 2014-05-21 20:25 ` redi at gcc dot gnu.org 2014-05-21 21:09 ` skunk at iskunk dot org 2014-05-23 4:39 ` skunk at iskunk dot org 2015-01-08 14:25 ` slipcon at gmail dot com [this message] 2015-04-14 0:02 ` redi at gcc dot gnu.org 2022-08-01 22:27 ` pinskia at gcc dot gnu.org 2022-08-01 23:07 ` redi at gcc dot gnu.org
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=bug-58638-4-DhkArolvrn@http.gcc.gnu.org/bugzilla/ \ --to=gcc-bugzilla@gcc.gnu.org \ --cc=gcc-bugs@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).