Commit 1f81cadf by Rainer Orth

doc: Update install.texi for GCC 10 on Solaris

This patch updates install.texi for GCC 10 on Solaris.  It includes some
general cleanup and updates and includes a couple of caveats, some of
them found when testing GCC 10.1.0 RC1 with only the bundled tools.

The reference to TGCware on the binaries page is gone because they only
provide binaries up to Solaris 9.

The note about configuring 64-bit Solaris/SPARC compilers with
--build=sparcv9-sun-solaris2.11 became necessary because upstream
config.guess silently reverted my patch to automatically detect this.  We
already had a bug report about a comparison failure caused by this issue.

Tested with make doc/gccinstall.info and doc/gccinstall.pdf and
inspection of the resulting files.

	* doc/install.texi: Replace Sun with Solaris as appropriate.
	(Tools/packages necessary for building GCC, Perl version between
	5.6.1 and 5.6.24): Remove Solaris 8 reference.
	(Installing GCC: Binaries, Solaris 2 (SPARC, Intel)): Remove
	TGCware reference.
	(Specific, i?86-*-solaris2*): Update version references for
	Solaris 11.3 and later.  Remove gas 2.26 caveat.
	(Specific, *-*-solaris2*): Update version references for
	Solaris 11.3 and later.  Remove boehm-gc reference.
	Document GMP, MPFR caveats on Solaris 11.3.
	(Specific, sparc-sun-solaris2*): Update Solaris 9 references.
	(Specific, sparc64-*-solaris2*): Likewise.
	Document --build requirement.
parent dcfafc02
2020-05-06 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* doc/install.texi: Replace Sun with Solaris as appropriate.
(Tools/packages necessary for building GCC, Perl version between
5.6.1 and 5.6.24): Remove Solaris 8 reference.
(Installing GCC: Binaries, Solaris 2 (SPARC, Intel)): Remove
TGCware reference.
(Specific, i?86-*-solaris2*): Update version references for
Solaris 11.3 and later. Remove gas 2.26 caveat.
(Specific, *-*-solaris2*): Update version references for
Solaris 11.3 and later. Remove boehm-gc reference.
Document GMP, MPFR caveats on Solaris 11.3.
(Specific, sparc-sun-solaris2*): Update Solaris 9 references.
(Specific, sparc64-*-solaris2*): Likewise.
Document --build requirement.
2020-05-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE> 2020-05-05 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* configure.ac <i[34567]86-*-*>: Add --32 to tls_as_opt on Solaris. * configure.ac <i[34567]86-*-*>: Add --32 to tls_as_opt on Solaris.
......
...@@ -349,9 +349,8 @@ systems' @command{tar} programs will also work, only try GNU ...@@ -349,9 +349,8 @@ systems' @command{tar} programs will also work, only try GNU
Necessary when targeting Darwin, building @samp{libstdc++}, Necessary when targeting Darwin, building @samp{libstdc++},
and not using @option{--disable-symvers}. and not using @option{--disable-symvers}.
Necessary when targeting Solaris 2 with Sun @command{ld} and not using Necessary when targeting Solaris 2 with Solaris @command{ld} and not using
@option{--disable-symvers}. The bundled @command{perl} in Solaris@tie{}8 @option{--disable-symvers}.
and up works.
Necessary when regenerating @file{Makefile} dependencies in libiberty. Necessary when regenerating @file{Makefile} dependencies in libiberty.
Necessary when regenerating @file{libiberty/functions.texi}. Necessary when regenerating @file{libiberty/functions.texi}.
...@@ -1016,7 +1015,7 @@ is the target system triple, such as @samp{sparc-sun-solaris2.7}, and ...@@ -1016,7 +1015,7 @@ is the target system triple, such as @samp{sparc-sun-solaris2.7}, and
@item @item
If the target system is the same that you are building on, check If the target system is the same that you are building on, check
operating system specific directories (e.g.@: @file{/usr/ccs/bin} on operating system specific directories (e.g.@: @file{/usr/ccs/bin} on
Sun Solaris 2). Solaris 2).
@item @item
Check in the @env{PATH} for a tool whose name is prefixed by the Check in the @env{PATH} for a tool whose name is prefixed by the
...@@ -3340,9 +3339,6 @@ Solaris 2 (SPARC, Intel): ...@@ -3340,9 +3339,6 @@ Solaris 2 (SPARC, Intel):
@itemize @itemize
@item @item
@uref{https://www.opencsw.org/,,OpenCSW} @uref{https://www.opencsw.org/,,OpenCSW}
@item
@uref{http://jupiterrise.com/tgcware/,,TGCware}
@end itemize @end itemize
@item @item
...@@ -4048,29 +4044,27 @@ found on @uref{http://www.bitwizard.nl/sig11/,,www.bitwizard.nl}. ...@@ -4048,29 +4044,27 @@ found on @uref{http://www.bitwizard.nl/sig11/,,www.bitwizard.nl}.
@end html @end html
@anchor{ix86-x-solaris2} @anchor{ix86-x-solaris2}
@heading i?86-*-solaris2* @heading i?86-*-solaris2*
Use this for Solaris 11 or later on x86 and x86-64 systems. Starting Use this for Solaris 11.3 or later on x86 and x86-64 systems. Starting
with GCC 4.7, there is also a 64-bit @samp{amd64-*-solaris2*} or with GCC 4.7, there is also a 64-bit @samp{amd64-*-solaris2*} or
@samp{x86_64-*-solaris2*} configuration that corresponds to @samp{x86_64-*-solaris2*} configuration that corresponds to
@samp{sparcv9-sun-solaris2*}. @samp{sparcv9-sun-solaris2*}.
It is recommended that you configure GCC to use the GNU assembler. The It is recommended that you configure GCC to use the GNU assembler. The
versions included in Solaris 11, from GNU binutils 2.19 or versions included in Solaris 11.3, from GNU binutils 2.23.1 or
newer (also available as @file{/usr/bin/gas} and newer (available as @file{/usr/bin/gas} and
@file{/usr/gnu/bin/as}), work fine. The current version, from GNU @file{/usr/gnu/bin/as}), work fine. The current version, from GNU
binutils 2.32, is known to work, but the version from GNU binutils 2.26 binutils 2.34, is known to work. Recent versions of the Solaris assembler in
must be avoided. Recent versions of the Solaris assembler in @file{/usr/bin/as} work almost as well, though.
@file{/usr/ccs/bin/as} work almost as well, though.
@c FIXME: as patch requirements?
For linking, the Solaris linker, is preferred. If you want to use the GNU For linking, the Solaris linker is preferred. If you want to use the GNU
linker instead, the version in Solaris 11, from GNU binutils 2.19 or linker instead, the version in Solaris 11.3, from GNU binutils 2.23.1 or
newer (also in @file{/usr/gnu/bin/ld} and @file{/usr/bin/gld}), works, newer (in @file{/usr/gnu/bin/ld} and @file{/usr/bin/gld}), works,
as does the latest version, from GNU binutils 2.32. as does the latest version, from GNU binutils 2.34.
To use GNU @command{as}, configure with the options To use GNU @command{as}, configure with the options
@option{--with-gnu-as --with-as=@//usr/@/gnu/@/bin/@/as}. It may be necessary @option{--with-gnu-as --with-as=@//usr/@/gnu/@/bin/@/as}. It may be necessary
to configure with @option{--without-gnu-ld --with-ld=@//usr/@/ccs/@/bin/@/ld} to to configure with @option{--without-gnu-ld --with-ld=@//usr/@/ccs/@/bin/@/ld} to
guarantee use of Sun @command{ld}. guarantee use of Solaris @command{ld}.
@c FIXME: why --without-gnu-ld --with-ld? @c FIXME: why --without-gnu-ld --with-ld?
@html @html
...@@ -4658,13 +4652,14 @@ Support for Solaris 10 has been removed in GCC 10. Support for Solaris ...@@ -4658,13 +4652,14 @@ Support for Solaris 10 has been removed in GCC 10. Support for Solaris
9 has been removed in GCC 5. Support for Solaris 8 has been removed in 9 has been removed in GCC 5. Support for Solaris 8 has been removed in
GCC 4.8. Support for Solaris 7 has been removed in GCC 4.6. GCC 4.8. Support for Solaris 7 has been removed in GCC 4.6.
Solaris 11 provides GCC 4.5.2, 4.7.3, and 4.8.2 as Solaris 11.3 provides GCC 4.5.2, 4.7.3, and 4.8.2 as
@command{/usr/gcc/4.5/bin/gcc} or similar. Alternatively, @command{/usr/gcc/4.5/bin/gcc} or similar. Newer Solaris versions
provide one or more of GCC 5, 7, and 9. Alternatively,
you can install a pre-built GCC to bootstrap and install GCC. See the you can install a pre-built GCC to bootstrap and install GCC. See the
@uref{binaries.html,,binaries page} for details. @uref{binaries.html,,binaries page} for details.
The Solaris 2 @command{/bin/sh} will often fail to configure The Solaris 2 @command{/bin/sh} will often fail to configure
@samp{libstdc++-v3}or @samp{boehm-gc}. We therefore recommend using the @samp{libstdc++-v3}. We therefore recommend using the
following initial sequence of commands following initial sequence of commands
@smallexample @smallexample
...@@ -4685,24 +4680,24 @@ Trying to use the linker and other tools in ...@@ -4685,24 +4680,24 @@ Trying to use the linker and other tools in
For example, the linker may hang indefinitely. The fix is to remove For example, the linker may hang indefinitely. The fix is to remove
@file{/usr/ucb} from your @env{PATH}. @file{/usr/ucb} from your @env{PATH}.
The build process works more smoothly with the legacy Sun tools so, if you The build process works more smoothly with the legacy Solaris tools so, if you
have @file{/usr/xpg4/bin} in your @env{PATH}, we recommend that you place have @file{/usr/xpg4/bin} in your @env{PATH}, we recommend that you place
@file{/usr/bin} before @file{/usr/xpg4/bin} for the duration of the build. @file{/usr/bin} before @file{/usr/xpg4/bin} for the duration of the build.
We recommend the use of the Solaris assembler or the GNU assembler, in We recommend the use of the Solaris assembler or the GNU assembler, in
conjunction with the Solaris linker. The GNU @command{as} conjunction with the Solaris linker. The GNU @command{as}
versions included in Solaris 11, versions included in Solaris 11.3,
from GNU binutils 2.19 or newer (also in @file{/usr/bin/gas} and from GNU binutils 2.23.1 or newer (in @file{/usr/bin/gas} and
@file{/usr/gnu/bin/as}), are known to work. @file{/usr/gnu/bin/as}), are known to work.
The current version, from GNU binutils 2.32, The current version, from GNU binutils 2.34,
is known to work as well. Note that your mileage may vary is known to work as well. Note that your mileage may vary
if you use a combination of the GNU tools and the Solaris tools: while the if you use a combination of the GNU tools and the Solaris tools: while the
combination GNU @command{as} + Sun @command{ld} should reasonably work, combination GNU @command{as} + Solaris @command{ld} should reasonably work,
the reverse combination Sun @command{as} + GNU @command{ld} may fail to the reverse combination Solaris @command{as} + GNU @command{ld} may fail to
build or cause memory corruption at runtime in some cases for C++ programs. build or cause memory corruption at runtime in some cases for C++ programs.
@c FIXME: still? @c FIXME: still?
GNU @command{ld} usually works as well. Again, the current GNU @command{ld} usually works as well. Again, the current
version (2.32) is known to work, but generally lacks platform specific version (2.34) is known to work, but generally lacks platform specific
features, so better stay with Solaris @command{ld}. To use the LTO linker features, so better stay with Solaris @command{ld}. To use the LTO linker
plugin (@option{-fuse-linker-plugin}) with GNU @command{ld}, GNU plugin (@option{-fuse-linker-plugin}) with GNU @command{ld}, GNU
binutils @emph{must} be configured with @option{--enable-largefile}. binutils @emph{must} be configured with @option{--enable-largefile}.
...@@ -4713,6 +4708,21 @@ GNU binutils. @samp{libstdc++} symbol versioning will be disabled if no ...@@ -4713,6 +4708,21 @@ GNU binutils. @samp{libstdc++} symbol versioning will be disabled if no
appropriate version is found. Solaris @command{c++filt} from the Solaris appropriate version is found. Solaris @command{c++filt} from the Solaris
Studio compilers does @emph{not} work. Studio compilers does @emph{not} work.
The versions of the GNU Multiple Precision Library (GMP), the MPFR
library and the MPC library bundled with Solaris 11.3 and later are
usually recent enough to match GCC's requirements. There are two
caveats:
@itemize @bullet
@item
While the version of the GMP library in Solaris 11.3 works with GCC, you
need to configure with @option{--with-gmp-include=/usr/include/gmp}.
@item
The version of the MPFR libary included in Solaris 11.3 is too old; you
need to provide a more recent one.
@end itemize
@html @html
<hr /> <hr />
@end html @end html
...@@ -4734,7 +4744,7 @@ in @uref{prerequisites.html,,the prerequisites}. ...@@ -4734,7 +4744,7 @@ in @uref{prerequisites.html,,the prerequisites}.
@anchor{sparc-sun-solaris2} @anchor{sparc-sun-solaris2}
@heading sparc-sun-solaris2* @heading sparc-sun-solaris2*
When GCC is configured to use GNU binutils 2.14 or later, the binaries When GCC is configured to use GNU binutils 2.14 or later, the binaries
produced are smaller than the ones produced using Sun's native tools; produced are smaller than the ones produced using Solaris native tools;
this difference is quite significant for binaries containing debugging this difference is quite significant for binaries containing debugging
information. information.
...@@ -4750,10 +4760,10 @@ When configuring the GNU Multiple Precision Library (GMP), the MPFR ...@@ -4750,10 +4760,10 @@ When configuring the GNU Multiple Precision Library (GMP), the MPFR
library or the MPC library on a Solaris 7 or later system, the canonical library or the MPC library on a Solaris 7 or later system, the canonical
target triplet must be specified as the @command{build} parameter on the target triplet must be specified as the @command{build} parameter on the
configure line. This target triplet can be obtained by invoking @command{./config.guess} in the toplevel source directory of GCC (and configure line. This target triplet can be obtained by invoking @command{./config.guess} in the toplevel source directory of GCC (and
not that of GMP or MPFR or MPC). For example on a Solaris 9 system: not that of GMP or MPFR or MPC). For example on a Solaris 11 system:
@smallexample @smallexample
% ./configure --build=sparc-sun-solaris2.9 --prefix=xxx % ./configure --build=sparc-sun-solaris2.11 --prefix=xxx
@end smallexample @end smallexample
@html @html
...@@ -4767,13 +4777,20 @@ not that of GMP or MPFR or MPC). For example on a Solaris 9 system: ...@@ -4767,13 +4777,20 @@ not that of GMP or MPFR or MPC). For example on a Solaris 9 system:
@end html @end html
@anchor{sparc64-x-solaris2} @anchor{sparc64-x-solaris2}
@heading sparc64-*-solaris2* @heading sparc64-*-solaris2*
When configuring a 64-bit-default GCC on Solaris/SPARC, you must use a
build compiler that generates 64-bit code, either by default or by
specifying @samp{CC='gcc -m64' CXX='gcc-m64'} to @command{configure}.
Additionally, you @emph{must} pass @option{--build=sparc64-sun-solaris2.11}
or @option{--build=sparcv9-sun-solaris2.11} because @file{config.guess}
misdetects this situation, which can cause build failures.
When configuring the GNU Multiple Precision Library (GMP), the MPFR When configuring the GNU Multiple Precision Library (GMP), the MPFR
library or the MPC library, the canonical target triplet must be specified library or the MPC library, the canonical target triplet must be specified
as the @command{build} parameter on the configure line. For example as the @command{build} parameter on the configure line. For example
on a Solaris 9 system: on a Solaris 11 system:
@smallexample @smallexample
% ./configure --build=sparc64-sun-solaris2.9 --prefix=xxx % ./configure --build=sparc64-sun-solaris2.11 --prefix=xxx
@end smallexample @end smallexample
@html @html
...@@ -4881,7 +4898,7 @@ can generate 64-bit x86-64 code with the @option{-m64} switch. Since ...@@ -4881,7 +4898,7 @@ can generate 64-bit x86-64 code with the @option{-m64} switch. Since
GCC 4.7, there is also a configuration that defaults to 64-bit code, but GCC 4.7, there is also a configuration that defaults to 64-bit code, but
can generate 32-bit code with @option{-m32}. To configure and build can generate 32-bit code with @option{-m32}. To configure and build
this way, you have to provide all support libraries like @file{libgmp} this way, you have to provide all support libraries like @file{libgmp}
as 64-bit code, configure with @option{--target=x86_64-pc-solaris2.1x} as 64-bit code, configure with @option{--target=x86_64-pc-solaris2.11}
and @samp{CC=gcc -m64}. and @samp{CC=gcc -m64}.
@html @html
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment