This is the mail archive of the
gcc-help@gcc.gnu.org
mailing list for the GCC project.
Re: Solaris 10: wchar_iso.h vs cwchar
2011/9/2 Marc Glisse <marc.glisse@inria.fr>:
> On Fri, 2 Sep 2011, Maciej BliziÅski wrote:
>
>> Here's the output:
>> http://netra.chopin.edu.pl/~maciej/limits.log
>
> That doesn't match the error in PPL. The only difference I can see is
> -I/opt/csw/include on the command line. Can you try again with it? (and
> maybe also -dD)
>
>> To get it to build, I need to specify a couple more:
>>
>> ${src}/configure \
>> Â--prefix=/opt/gcctest \
>> Â--enable-bootstrap \
>
> That one is the default.
OK, removed.
>> Â--enable-stage1-languages=c \
>
> Is that necessary?
Not sure, tested by removing.
>> Â--enable-languages=c,c++ \
>> Â--with-gnu-as \
>> Â--with-as=/opt/csw/bin/gas \
>> Â--without-gnu-ld \
>> Â--with-ld=/usr/ccs/bin/ld \
>> Â--with-mpfr=/opt/csw \
>> Â--with-gmp=/opt/csw \
>> Â--with-mpc=/opt/csw \
>> Â--with-libiconv-prefix=/opt/csw
>
> Those are fine.
Cool. I started the build and got this error in
gcc-objdir/sparc-sun-solaris2.10/libgcc/config.log:
configure:3246: checking for suffix of object files
configure:3268: /home/maciej/src/gcc-objdir/./gcc/xgcc
-B/home/maciej/src/gcc-objdir/./gcc/
-B/opt/gcctest/sparc-sun-solaris2.10/bin/ -B/opt/gc
isystem /opt/gcctest/sparc-sun-solaris2.10/include -isystem
/opt/gcctest/sparc-sun-solaris2.10/sys-include -c -g -O2
conftest.c >&5
ld.so.1: cc1: fatal: libmpc.so.2: open failed: No such file or directory
xgcc: internal compiler error: Killed (program cc1)
Please submit a full bug report,
with preprocessed source if appropriate.
See <http://gcc.gnu.org/bugs.html> for instructions.
configure:3272: $? = 4
Examining the cc1 binary:
maciej@netra ~/src $ /usr/ccs/bin/dump -Lv /home/maciej/src/gcc-objdir/./gcc/cc1
/home/maciej/src/gcc-objdir/./gcc/cc1:
**** DYNAMIC SECTION INFORMATION ****
.dynamic:
[INDEX] Tag Value
[1] NEEDED libmpc.so.2
[2] NEEDED libmpfr.so.4
[3] NEEDED libgmp.so.10
[4] NEEDED libc.so.1
[5] INIT 0x61f474
[6] FINI 0x61f490
[7] HASH 0x100e8
[8] STRTAB 0x3be5c
[9] STRSZ 0x24442
[10] SYMTAB 0x1eabc
[11] SYMENT 0x10
[12] CHECKSUM 0xc01b
[13] VERNEED 0x602a0
[14] VERNEEDNUM 0x1
[15] PLTSZ 0xa14
[16] PLTREL 0x7
[17] JMPREL 0x60320
[18] RELA 0x602c0
[19] RELASZ 0xa74
[20] RELAENT 0xc
[21] DEBUG 0
[22] FEATURE_1 PARINIT
[23] FLAGS 0
[24] FLAGS_1 0
[25] PLTGOT 0x6e7fe4
The binary seems to be missing the RPATH pointing at /opt/csw/lib.
The full script that drives the build is:
maciej@netra ~/src $ cat build_gcc.sh
#!/opt/csw/bin/bash
set -e
set -u
set -x
# To help configure find gcc and ar
export PATH=/opt/csw/gnu:$PATH
src="../gcc-4.6.1"
objdir="gcc-objdir"
rm -rf "${objdir}"
mkdir -p "${objdir}"
pushd ${objdir}
export CC=/opt/csw/gcc3/bin/gcc
${src}/configure \
--prefix=/opt/gcctest \
--enable-languages=c,c++ \
--with-gnu-as \
--with-as=/opt/csw/bin/gas \
--without-gnu-ld \
--with-ld=/usr/ccs/bin/ld \
--with-mpfr=/opt/csw \
--with-gmp=/opt/csw \
--with-mpc=/opt/csw \
--with-libiconv-prefix=/opt/csw
gmake
Any ideas why the RPATH might be missing?
Maciej