https://gcc.gnu.org/bugzilla/show_bug.cgi?id=120905

--- Comment #17 from TCH <tch at protonmail dot com> ---
Okay, GCC6 now compiles and the resulting compiler can compile too. So, this is
the right way to do:

untxz gcc-6.5.0.tar.xz
cd gcc-6.5.0
patch -p0 < ../gcc6_solaris10.patch
cd ..
mkdir gcc6
cd gcc6
export LD_LIBRARY_PATH="$LD_LIBRARY_PATH"':/opt/csw/lib/'
../gcc-6.5.0/configure --prefix=/opt/gcc6 --build=sparc-sun-solaris2.10
--with-gnu-as --with-as=/usr/local/bin/as --enable-shared --disable-nls
--enable-languages=c,c++,objc --with-gmp=/opt/csw --with-mpfr=/opt/csw
--with-mpc=/opt/csw
make
make install

And then, when using the compiler:

export LD_LIBRARY_PATH="$LD_LIBRARY_PATH"':/opt/csw/lib/'
export PATH='/opt/gcc6/bin:'"$PATH"
gcc whatever.c

It may be better, if the exporting lines are put into '.profile'.

Thanks again for the help.

Reply via email to