This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c/36481] New: gcc fails to build on Solaris x86 - it forgets the locations of libmpfr


I'm trying to compile gcc 4.3.1 on a Laptop running Solaris Express Community
Edition Build 89.


drkirkby@kingfisher:[~/build] $ cat /etc/release
                   Solaris Express Community Edition snv_89 X86
           Copyright 2008 Sun Microsystems, Inc.  All Rights Reserved.
                        Use is subject to license terms.
                              Assembled 06 May 2008


After configuring with these options (plenty of others tried)

 $ ../gcc-4.3.1/configure --with-as=/usr/ccs/bin/as --with-ld=/usr/ccs/bin/ld
--enable-shared --enable-languages=c,c++,fortran LD_LIBRARY_PATH=/usr/local/lib
--with-gmp=/usr/local --with-mpfr=/usr/local --with-mpfr-lib=/usr/local/lib
--with-mpfr-include=/usr/local/include --with-gmp-include=/usr/local/include
--with-gmp-lib=/usr/local/lib


gcc spends 15 minutes or so compiling, then bombs out with:

checking for i386-pc-solaris2.11-lipo... lipo
checking for i386-pc-solaris2.11-nm... /export/home/drkirkby/build/./gcc/nm
checking for i386-pc-solaris2.11-ranlib... ranlib
checking for i386-pc-solaris2.11-strip... strip
checking whether ln -s works... yes
checking for i386-pc-solaris2.11-gcc... /export/home/drkirkby/build/./gcc/xgcc
-B/export/home/drkirkby/build/./gcc/ -B/usr/local/i386-pc-solaris2.11/bin/
-B/usr/local/i386-pc-solaris2.11/lib/ -isystem
/usr/local/i386-pc-solaris2.11/include -isystem
/usr/local/i386-pc-solaris2.11/sys-include
checking for suffix of object files... configure: error: cannot compute suffix
of object files: cannot compile
See `config.log' for more details.
gmake[2]: *** [configure-stage1-target-libgcc] Error 1
gmake[2]: Leaving directory `/export/home/drkirkby/build'
gmake[1]: *** [stage1-bubble] Error 2
gmake[1]: Leaving directory `/ex


A search on the web for the "configure: error: cannot compute suffix of object
files: cannot compile" suggests setting LD_LIBRARY_PATH, as above. That does
not work. I've also tried

set LD_LIBRARY_PATH=/usr/local/lib
export LD_LIBRARY_PATH

but that does not work either.

The log file:

./i386-pc-solaris2.11/libgcc/config.log
(see end of message)

shows the linker can't seem to find the library libmpfr.so.1. But that does
exists. I've tried every option to configure that might tell the linker where
to find this library:

--with-mpfr=/usr/local
--with-mpfr-lib=/usr/local/lib
--with-mpfr-include=/usr/local/include

but it does not work.

In contrast, I can easily use that library if I compile with cc or gcc.

Neither of these present any error message.
drkirkby@kingfisher:[~] $ cc  -L/usr/local/lib -lmpfr  f.c
drkirkby@kingfisher:[~] $ gcc  -L/usr/local/lib -lmpfr  f.c

so the library is ok.

Here's the log file. Any idea why the building of gcc 4.3.1 is failing?


Target: i386-pc-solaris2.11
Configured with: ../gcc-4.3.1/configure --with-as=/usr/ccs/bin/as
--with-ld=/usr/ccs/bin/ld --enable-shared --enable-languages=c,c++,fortran
LD_LIBRARY_PATH=/usr/local/lib --with-gmp=/usr/local --with-mpfr=/usr/local
--with-mpfr-lib=/usr/local/lib --with-mpfr-include=/usr/local/include
--with-gmp-include=/usr/local/include --with-gmp-lib=/usr/local/lib
Thread model: posix
gcc version 4.3.1 (GCC)
configure:2374: $? = 0
configure:2376: /export/home/drkirkby/build/./gcc/xgcc
-B/export/home/drkirkby/build/./gcc/ -B/usr/local/i386-pc-solaris2.11/bin/
-B/usr/local/i386-pc-solaris2.11/lib/ -isystem
/usr/local/i386-pc-solaris2.11/include -isystem
/usr/local/i386-pc-solaris2.11/sys-include -V </dev/null >&5
xgcc: '-V' must come at the start of the command line
configure:2379: $? = 1
configure:2398: /export/home/drkirkby/build/./gcc/xgcc
-B/export/home/drkirkby/build/./gcc/ -B/usr/local/i386-pc-solaris2.11/bin/
-B/usr/local/i386-pc-solaris2.11/lib/ -isystem
/usr/local/i386-pc-solaris2.11/include -isystem
/usr/local/i386-pc-solaris2.11/sys-include -o conftest -g
-fkeep-inline-functions   conftest.c  >&5
ld.so.1: cc1: fatal: libmpfr.so.1: open failed: No such file or directory
xgcc: Internal error: Killed (program cc1)
Please submit a full bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
configure:2401: $? = 1
configure:2567: checking for suffix of object files
configure:2588: /export/home/drkirkby/build/./gcc/xgcc
-B/export/home/drkirkby/build/./gcc/ -B/usr/local/i386-pc-solaris2.11/bin/
-B/usr/local/i386-pc-solaris2.11/lib/ -isystem
/usr/local/i386-pc-solaris2.11/include -isystem
/usr/local/i386-pc-solaris2.11/sys-include -c -g -fkeep-inline-functions 
conftest.c >&5
ld.so.1: cc1: fatal: libmpfr.so.1: open failed: No such file or directory
xgcc: Internal error: Killed (program cc1)
Please submit a full bug report.
See <http://gcc.gnu.org/bugs.html> for instructions.
configure:2591: $? = 1
configure: failed program was:


Someone suggested I set CONFIG_SHELL to /bin/bash. That did not help. 
Also tried LDFLAGS='-L/usr/local/lib -R/usr/local/lib'
but again did not help.


-- 
           Summary: gcc fails to build on Solaris x86 - it forgets the
                    locations of libmpfr
           Product: gcc
           Version: 4.3.1
            Status: UNCONFIRMED
          Severity: blocker
          Priority: P3
         Component: c
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: david dot kirkby at onetel dot net


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


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]