On Sun, 2009-03-29 at 15:21 +0000, Joseph S. Myers wrote:
> On Sun, 29 Mar 2009, Laurent GUERBY wrote:
>
> > libbackend.a(builtins.o): In function `fold_builtin_1':
> > ../../trunk/gcc/builtins.c:10319: undefined reference to `mpfr_j0'
> > ../../trunk/gcc/builtins.c:10325: undefined reference to `mpfr_j1'
> > ../../trunk/gcc/builtins.c:10331: undefined reference to `mpfr_y0'
> > ../../trunk/gcc/builtins.c:10337: undefined reference to `mpfr_y1'
>
> It appears your problem is that the directory with libstdc++ in it also
> has an old MPFR version in it, so passing a -L option for it interferes
> with finding the right MPFR. In that case,
> --with-host-libstdc++=/usr/lib/libstdc++.so should work - you need to name
> the actual file to use for linking libstdc++ rather than giving -L and -l
> options.
With --with-host-libstdc++=/usr/lib/libstdc++.so.6 the build did
succeed, thanks for your advices.
gue...@gcc17:~/build-ppl$ ldd gcc/cc1
libstdc++.so.6 => /usr/lib/libstdc++.so.6 (0x00002aaaaabc3000)
libgcc_s.so.1 => /lib/libgcc_s.so.1 (0x00002aaaaadc1000)
libc.so.6 => /lib/libc.so.6 (0x00002aaaaaecf000)
libm.so.6 => /lib/libm.so.6 (0x00002aaaab10c000)
/lib64/ld-linux-x86-64.so.2 (0x00002aaaaaaab000)
Should we add to the documentation the steps to configure and
build an all-static but libstdc++ GCC (as in my first email)? Or less
ambitious in install.texi:
Typical values of @var{linker-args} might be
@samp{-lstdc++} or @samp{-Wl,-Bstatic,-lstdc++,-Bdynamic -lm}.
=>
Typical values of @var{linker-args} might be
@samp{/usr/lib/libstdc++.so.6}, @samp{-lstdc++} or
@samp{-Wl,-Bstatic,-lstdc++,-Bdynamic -lm}.
Sincerely,
Laurent