public inbox for gcc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "pinskia at gmail dot com" <gcc-bugzilla@gcc.gnu.org>
To: gcc-bugs@gcc.gnu.org
Subject: [Bug bootstrap/54304] linking stage picks up system mpfr instead of in-tree version
Date: Fri, 17 Aug 2012 19:14:00 -0000	[thread overview]
Message-ID: <bug-54304-4-hM7f0qkROH@http.gcc.gnu.org/bugzilla/> (raw)
In-Reply-To: <bug-54304-4@http.gcc.gnu.org/bugzilla/>

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54304

--- Comment #1 from pinskia at gmail dot com <pinskia at gmail dot com> 2012-08-17 19:13:50 UTC ---
This is a darwin only issue.
On Aug 17, 2012 12:07 PM, "tobi at gcc dot gnu.org" <
gcc-bugzilla@gcc.gnu.org> wrote:

> http://gcc.gnu.org/bugzilla/show_bug.cgi?id=54304
>
>              Bug #: 54304
>            Summary: linking stage picks up system mpfr instead of in-tree
>                     version
>     Classification: Unclassified
>            Product: gcc
>            Version: 4.8.0
>             Status: UNCONFIRMED
>           Severity: normal
>           Priority: P3
>          Component: bootstrap
>         AssignedTo: unassigned@gcc.gnu.org
>         ReportedBy: tobi@gcc.gnu.org
>
>
> This is an old bug, I found mention of it all over the internet, and also
> on
> the gcc mailing list <http://gcc.gnu.org/ml/gcc-help/2011-04/msg00126.html
> >.
>
> What happens is that with an in-tree gmp, mpfr, mpc (I used
> contrib/download_prerequisites) the linking stage picks up the system
> libraries
> instead of the in-tree versions.  This causes a problem when the system
> libmpfr
> < 3.0.0 and the in-tree version is >= 3.0.0 and vice versa, because
> mpfr_get_z_exp was renamed to mpfr_get_z_2exp between the two (hidden
> behind a
> macro).  The error I'm seeing with today's tree is:
>
> /Users/tobi/src/gcc/build/./prev-gcc/g++
> -B/Users/tobi/src/gcc/build/./prev-gcc/
> -B/usr/local/x86_64-apple-darwin11.4.0/bin/ -nostdinc++
>
> -B/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/src/.libs
>
> -B/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/libsupc++/.libs
>
> -I/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/include/x86_64-apple-darwin11.4.0
>
> -I/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/include
> -I/Users/tobi/src/gcc/libstdc++-v3/libsupc++
>
> -L/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/src/.libs
>
> -L/Users/tobi/src/gcc/build/prev-x86_64-apple-darwin11.4.0/libstdc++-v3/libsupc++/.libs
>   -g -O2 -mdynamic-no-pic -gtoggle -DIN_GCC   -fno-exceptions -fno-rtti -W
> -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute
> -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings
> -Werror
> -fno-common  -DHAVE_CONFIG_H -static-libstdc++ -static-libgcc -Wl,-no_pie
> -o
> f951 \
>                 fortran/arith.o fortran/array.o fortran/bbt.o
> fortran/check.o
> fortran/class.o fortran/constructor.o fortran/cpp.o fortran/data.o
> fortran/decl.o fortran/dump-parse-tree.o fortran/error.o fortran/expr.o
> fortran/interface.o fortran/intrinsic.o fortran/io.o fortran/iresolve.o
> fortran/match.o fortran/matchexp.o fortran/misc.o fortran/module.o
> fortran/openmp.o fortran/options.o fortran/parse.o fortran/primary.o
> fortran/resolve.o fortran/scanner.o fortran/simplify.o fortran/st.o
> fortran/symbol.o fortran/target-memory.o darwin-f.o fortran/convert.o
> fortran/dependency.o fortran/f95-lang.o fortran/trans.o
> fortran/trans-array.o
> fortran/trans-common.o fortran/trans-const.o fortran/trans-decl.o
> fortran/trans-expr.o fortran/trans-intrinsic.o fortran/trans-io.o
> fortran/trans-openmp.o fortran/trans-stmt.o fortran/trans-types.o
> fortran/frontend-passes.o libbackend.a main.o tree-browser.o
> libcommon-target.a
> libcommon.a ../libcpp/libcpp.a ../libdecnumber/libdecnumber.a libcommon.a
> ../libcpp/libcpp.a -lintl -L/opt/local/lib -liconv
>  ../libiberty/libiberty.a
> ../libdecnumber/libdecnumber.a  attribs.o
> -L/Users/tobi/src/gcc/build/./gmp/.libs
> -L/Users/tobi/src/gcc/build/./mpfr/.libs
> -L/Users/tobi/src/gcc/build/./mpc/src/.libs -lmpc -lmpfr -lgmp   -L../zlib
> -lz
> Undefined symbols for architecture x86_64:
>   "_mpfr_get_z_exp", referenced from:
>       gfc_mpfr_to_mpz(__mpz_struct*, __mpfr_struct*, locus*)     in arith.o
> ld: symbol(s) not found for architecture x86_64
> collect2: error: ld returned 1 exit status
> make[3]: *** [f951] Error 1
> make[2]: *** [all-stage2-gcc] Error 2
> make[1]: *** [stage2-bubble] Error 2
> make: *** [all] Error 2
>
> (I mentioned this in the aftermath to PR54292)
>
> Cheers
>


  reply	other threads:[~2012-08-17 19:14 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-08-17 19:06 [Bug bootstrap/54304] New: " tobi at gcc dot gnu.org
2012-08-17 19:14 ` pinskia at gmail dot com [this message]
2012-08-17 19:24 ` [Bug bootstrap/54304] " tobi at gcc dot gnu.org
2012-08-17 19:27 ` glisse at gcc dot gnu.org
2012-08-17 19:30 ` tobi at gcc dot gnu.org
2012-08-17 19:31 ` tobi at gcc dot gnu.org
2012-08-17 19:33 ` tobi at gcc dot gnu.org
2012-08-17 19:36 ` tobi at gcc dot gnu.org
2012-08-17 19:39 ` tobi at gcc dot gnu.org
2012-08-17 19:40 ` glisse at gcc dot gnu.org
2012-08-17 20:56 ` tobi at gcc dot gnu.org
2012-08-17 21:22 ` glisse at gcc dot gnu.org
2012-08-17 21:36 ` tobi at gcc dot gnu.org
2012-08-17 22:06 ` glisse at gcc dot gnu.org
2012-08-17 22:25 ` tobi at gcc dot gnu.org
2015-06-04 16:18 ` egall at gwmail dot gwu.edu
2015-06-04 17:01 ` pinskia 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-54304-4-hM7f0qkROH@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: link
Be 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).