Re: Unable to build gcc-4.8.2 on sparcv9 Solaris 10.

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



10.12.2013 3:31, Don Krause kirjoitti:
On Thu, Dec 5, 2013 at 10:20 AM, Don Krause <dkrause@xxxxxxxxxxx> wrote:
I've been trying to build gcc-4.8.2 on Solaris 10 on Sparc.

The bootstrap process gives me an "internal compiler error"

./configure --prefix=/home/tools/solaris2013

make.

That churns for a couple hours. (yes, old and crappy equipment. No options here..)

Then:

../../../libgcc/libgcc2.c: In function '__muldi3':
../../../libgcc/libgcc2.c:549:17: internal compiler error: Segmentation Fault
   const DWunion uu = {.ll = u};


Well, I was successful at building 4.7.3 on my old Ultra 10, which is likely more than good enough for what I needed.

But, because the host isn't doing anything else, I'm now trying to build 4.8.2 again with 4.7.3. We'll see.



When the native build "churns for a couple hours" one possibility for making tools for Sparc/Solaris 10 could be via crosscompiling on some much quicker host. But unfortunately gcc-4.8.2 seems to be broken because the Canadian Cross process on an older CentOS 5.10 Linux/x86 system ended with :

g++ -c -Os -DIN_GCC -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -DHAVE_CONFIG_H -DGENERATOR_FILE -I. -Ibuild -I../../gcc -I../../gcc/build -I../../gcc/../include -I../../gcc/../libcpp/include -I/home/src/gcc-4.8.2/build/./gmp -I/home/src/gcc-4.8.2/gmp -I/home/src/gcc-4.8.2/build/./mpfr -I/home/src/gcc-4.8.2/mpfr -I/home/src/gcc-4.8.2/mpc/src -I../../gcc/../libdecnumber -I../../gcc/../libdecnumber/dpd -I../libdecnumber -I../../gcc/../libbacktrace \
                -o build/genconstants.o ../../gcc/genconstants.c
cc1plus: error: unrecognized command line option "-Wno-narrowing"
cc1plus: error: unrecognized command line option "-Wno-overlength-strings"
make[2]: *** [build/genconstants.o] Virhe 1
make[2]: Poistutaan hakemistosta "/home/src/gcc-4.8.2/build/gcc"
make[1]: *** [all-gcc] Virhe 2

The build G++ was the native g++-4.1.2 :

[root@localhost build]# g++ -v
Reading specs from /usr/lib/gcc/i386-redhat-linux/4.1.2/specs
Target: i386-redhat-linux
Configured with: ../configure --prefix=/usr --mandir=/usr/share/man --infodir=/usr/share/info --enable-shared --enable-threads=posix --enable-checking=release --with-system-zlib --enable-__cxa_atexit --disable-libunwind-exceptions --enable-libgcj-multifile --enable-languages=c,c++,objc,obj-c++,java,fortran,ada --enable-java-awt=gtk --disable-dssi --disable-plugin --with-java-home=/usr/lib/jvm/java-1.4.2-gcj-1.4.2.0/jre --with-cpu=generic --host=i386-redhat-linux
Thread model: posix
gcc version 4.1.2 20080704 (Red Hat 4.1.2-54)

which seemingly didn't grok the "-Wno-narrowing" and "-Wno-overlength-strings" options.
On a newer Linux/x86_64 system the build then ended later with :

make[2]: Siirrytään hakemistoon "/home/src/gcc-4.8.2/build/gcc"
sparc-solaris2.10-g++-4.8 -c -DGENERATOR_FILE -Os -DIN_GCC -fno-exceptions -fno-rtti -fasynchronous-unwind-tables -W -Wall -Wno-narrowing -Wwrite-strings -Wcast-qual -Wmissing-format-attribute -pedantic -Wno-long-long -Wno-variadic-macros -Wno-overlength-strings -DHAVE_CONFIG_H -I. -I. -I../../gcc -I../../gcc/. -I../../gcc/../include -I../../gcc/../libcpp/include -I/home/src/gcc-4.8.2/build/./gmp -I/home/src/gcc-4.8.2/gmp -I/home/src/gcc-4.8.2/build/./mpfr -I/home/src/gcc-4.8.2/mpfr -I/home/src/gcc-4.8.2/mpc/src -I../../gcc/../libdecnumber -I../../gcc/../libdecnumber/dpd -I../libdecnumber -I../../gcc/../libbacktrace ../../gcc/gengtype.c -o gengtype.o
In file included from ../../gcc/gengtype.c:25:0:
../../gcc/gengtype.c: In function 'void error_at_line(const fileloc*, const char*, ...)': ../../gcc/system.h:93:53: error: 'fputc_unlocked' was not declared in this scope
 #  define fputc(C, Stream) fputc_unlocked (C, Stream)
                                                     ^
../../gcc/gengtype.c:117:3: note: in expansion of macro 'fputc'
   fputc ('\n', stderr);
   ^
Googling with the error message gave an explanation and some patch:

http://git.yoctoproject.org/cgit.cgi/poky/plain/meta/recipes-devtools/gcc/gcc-4.8/0044-gengtypes.patch

Sad that this bug wasn't yet fixed in gcc-4.8.2 :(





[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux