1 This is gccinstall.info, produced by makeinfo version 6.5 from 2 install.texi. 3 4 Copyright (C) 1988-2022 Free Software Foundation, Inc. 5 6 Permission is granted to copy, distribute and/or modify this document 7 under the terms of the GNU Free Documentation License, Version 1.3 or 8 any later version published by the Free Software Foundation; with no 9 Invariant Sections, the Front-Cover texts being (a) (see below), and 10 with the Back-Cover Texts being (b) (see below). A copy of the license 11 is included in the section entitled "GNU Free Documentation License". 12 13 (a) The FSF's Front-Cover Text is: 14 15 A GNU Manual 16 17 (b) The FSF's Back-Cover Text is: 18 19 You have freedom to copy and modify this GNU Manual, like GNU 20 software. Copies published by the Free Software Foundation raise funds 21 for GNU development. 22 INFO-DIR-SECTION Software development 23 START-INFO-DIR-ENTRY 24 * gccinstall: (gccinstall). Installing the GNU Compiler Collection. 25 END-INFO-DIR-ENTRY 26 27 Copyright (C) 1988-2022 Free Software Foundation, Inc. 28 29 Permission is granted to copy, distribute and/or modify this document 30 under the terms of the GNU Free Documentation License, Version 1.3 or 31 any later version published by the Free Software Foundation; with no 32 Invariant Sections, the Front-Cover texts being (a) (see below), and 33 with the Back-Cover Texts being (b) (see below). A copy of the license 34 is included in the section entitled "GNU Free Documentation License". 35 36 (a) The FSF's Front-Cover Text is: 37 38 A GNU Manual 39 40 (b) The FSF's Back-Cover Text is: 41 42 You have freedom to copy and modify this GNU Manual, like GNU 43 software. Copies published by the Free Software Foundation raise funds 44 for GNU development. 45 46 47 File: gccinstall.info, Node: Top, Up: (dir) 48 49 * Menu: 50 51 * Installing GCC:: This document describes the generic installation 52 procedure for GCC as well as detailing some target 53 specific installation instructions. 54 55 * Specific:: Host/target specific installation notes for GCC. 56 * Binaries:: Where to get pre-compiled binaries. 57 58 * GNU Free Documentation License:: How you can copy and share this manual. 59 * Concept Index:: This index has two entries. 60 61 62 File: gccinstall.info, Node: Installing GCC, Next: Binaries, Up: Top 63 64 1 Installing GCC 65 **************** 66 67 The latest version of this document is always available at 68 https://gcc.gnu.org/install/. It refers to the current development 69 sources, instructions for specific released versions are included with 70 the sources. 71 72 This document describes the generic installation procedure for GCC as 73 well as detailing some target specific installation instructions. 74 75 GCC includes several components that previously were separate 76 distributions with their own installation instructions. This document 77 supersedes all package-specific installation instructions. 78 79 _Before_ starting the build/install procedure please check the *note 80 host/target specific installation notes: Specific. We recommend you 81 browse the entire generic installation instructions before you proceed. 82 83 Lists of successful builds for released versions of GCC are available 84 at <https://gcc.gnu.org/buildstat.html>. These lists are updated as new 85 information becomes available. 86 87 The installation procedure itself is broken into five steps. 88 89 * Menu: 90 91 * Prerequisites:: 92 * Downloading the source:: 93 * Configuration:: 94 * Building:: 95 * Testing:: (optional) 96 * Final install:: 97 98 Please note that GCC does not support 'make uninstall' and probably 99 won't do so in the near future as this would open a can of worms. 100 Instead, we suggest that you install GCC into a directory of its own and 101 simply remove that directory when you do not need that specific version 102 of GCC any longer, and, if shared libraries are installed there as well, 103 no more binaries exist that use them. 104 105 106 File: gccinstall.info, Node: Prerequisites, Next: Downloading the source, Up: Installing GCC 107 108 2 Prerequisites 109 *************** 110 111 GCC requires that various tools and packages be available for use in the 112 build procedure. Modifying GCC sources requires additional tools 113 described below. 114 115 Tools/packages necessary for building GCC 116 ========================================= 117 118 ISO C++11 compiler 119 Necessary to bootstrap GCC. GCC 4.8.3 or newer has sufficient 120 support for used C++11 features, with earlier GCC versions you 121 might run into implementation bugs. 122 123 Versions of GCC prior to 11 also allow bootstrapping with an ISO 124 C++98 compiler, versions of GCC prior to 4.8 also allow 125 bootstrapping with a ISO C89 compiler, and versions of GCC prior to 126 3.4 also allow bootstrapping with a traditional (K&R) C compiler. 127 128 To build all languages in a cross-compiler or other configuration 129 where 3-stage bootstrap is not performed, you need to start with an 130 existing GCC binary (version 4.8.3 or later) because source code 131 for language frontends other than C might use GCC extensions. 132 133 C standard library and headers 134 135 In order to build GCC, the C standard library and headers must be 136 present for all target variants for which target libraries will be 137 built (and not only the variant of the host C++ compiler). 138 139 This affects the popular 'x86_64-pc-linux-gnu' platform (among 140 other multilib targets), for which 64-bit ('x86_64') and 32-bit 141 ('i386') libc headers are usually packaged separately. If you do a 142 build of a native compiler on 'x86_64-pc-linux-gnu', make sure you 143 either have the 32-bit libc developer package properly installed 144 (the exact name of the package depends on your distro) or you must 145 build GCC as a 64-bit only compiler by configuring with the option 146 '--disable-multilib'. Otherwise, you may encounter an error such 147 as 'fatal error: gnu/stubs-32.h: No such file' 148 149 GNAT 150 151 In order to build GNAT, the Ada compiler, you need a working GNAT 152 compiler (GCC version 5.1 or later). 153 154 This includes GNAT tools such as 'gnatmake' and 'gnatlink', since 155 the Ada front end is written in Ada and uses some GNAT-specific 156 extensions. 157 158 In order to build a cross compiler, it is strongly recommended to 159 install the new compiler as native first, and then use it to build 160 the cross compiler. Other native compiler versions may work but 161 this is not guaranteed and will typically fail with hard to 162 understand compilation errors during the build. 163 164 Similarly, it is strongly recommended to use an older version of 165 GNAT to build GNAT. More recent versions of GNAT than the version 166 built are not guaranteed to work and will often fail during the 167 build with compilation errors. 168 169 Note that 'configure' does not test whether the GNAT installation 170 works and has a sufficiently recent version; if too old a GNAT 171 version is installed and '--enable-languages=ada' is used, the 172 build will fail. 173 174 'ADA_INCLUDE_PATH' and 'ADA_OBJECT_PATH' environment variables must 175 not be set when building the Ada compiler, the Ada tools, or the 176 Ada runtime libraries. You can check that your build environment 177 is clean by verifying that 'gnatls -v' lists only one explicit path 178 in each section. 179 180 GDC 181 182 In order to build GDC, the D compiler, you need a working GDC 183 compiler (GCC version 9.4 or later) and D runtime library, 184 'libphobos', as the D front end is written in D. 185 186 Versions of GDC prior to 12 can be built with an ISO C++11 187 compiler, which can then be installed and used to bootstrap newer 188 versions of the D front end. 189 190 It is strongly recommended to use an older version of GDC to build 191 GDC. More recent versions of GDC than the version built are not 192 guaranteed to work and will often fail during the build with 193 compilation errors relating to deprecations or removed features. 194 195 Note that 'configure' does not test whether the GDC installation 196 works and has a sufficiently recent version. Though the 197 implementation of the D front end does not make use of any 198 GDC-specific extensions, or novel features of the D language, if 199 too old a GDC version is installed and '--enable-languages=d' is 200 used, the build will fail. 201 202 On some targets, 'libphobos' isn't enabled by default, but compiles 203 and works if '--enable-libphobos' is used. Specifics are 204 documented for affected targets. 205 206 A "working" POSIX compatible shell, or GNU bash 207 208 Necessary when running 'configure' because some '/bin/sh' shells 209 have bugs and may crash when configuring the target libraries. In 210 other cases, '/bin/sh' or 'ksh' have disastrous corner-case 211 performance problems. This can cause target 'configure' runs to 212 literally take days to complete in some cases. 213 214 So on some platforms '/bin/ksh' is sufficient, on others it isn't. 215 See the host/target specific instructions for your platform, or use 216 'bash' to be sure. Then set 'CONFIG_SHELL' in your environment to 217 your "good" shell prior to running 'configure'/'make'. 218 219 'zsh' is not a fully compliant POSIX shell and will not work when 220 configuring GCC. 221 222 A POSIX or SVR4 awk 223 224 Necessary for creating some of the generated source files for GCC. 225 If in doubt, use a recent GNU awk version, as some of the older 226 ones are broken. GNU awk version 3.1.5 is known to work. 227 228 GNU binutils 229 230 Necessary in some circumstances, optional in others. See the 231 host/target specific instructions for your platform for the exact 232 requirements. 233 234 Note binutils 2.35 or newer is required for LTO to work correctly 235 with GNU libtool that includes doing a bootstrap with LTO enabled. 236 237 gzip version 1.2.4 (or later) or 238 bzip2 version 1.0.2 (or later) 239 240 Necessary to uncompress GCC 'tar' files when source code is 241 obtained via HTTPS mirror sites. 242 243 GNU make version 3.80 (or later) 244 245 You must have GNU make installed to build GCC. 246 247 GNU tar version 1.14 (or later) 248 249 Necessary (only on some platforms) to untar the source code. Many 250 systems' 'tar' programs will also work, only try GNU 'tar' if you 251 have problems. 252 253 Perl version between 5.6.1 and 5.6.24 254 255 Necessary when targeting Darwin, building 'libstdc++', and not 256 using '--disable-symvers'. Necessary when targeting Solaris 2 with 257 Solaris 'ld' and not using '--disable-symvers'. 258 259 Necessary when regenerating 'Makefile' dependencies in libiberty. 260 Necessary when regenerating 'libiberty/functions.texi'. Necessary 261 when generating manpages from Texinfo manuals. Used by various 262 scripts to generate some files included in the source repository 263 (mainly Unicode-related and rarely changing) from source tables. 264 265 Used by 'automake'. 266 267 If available, enables parallel testing of 'libgomp' in case that 268 'flock' is not available. 269 270 Several support libraries are necessary to build GCC, some are 271 required, others optional. While any sufficiently new version of 272 required tools usually work, library requirements are generally 273 stricter. Newer versions may work in some cases, but it's safer to use 274 the exact versions documented. We appreciate bug reports about problems 275 with newer versions, though. If your OS vendor provides packages for 276 the support libraries then using those packages may be the simplest way 277 to install the libraries. 278 279 GNU Multiple Precision Library (GMP) version 4.3.2 (or later) 280 281 Necessary to build GCC. If a GMP source distribution is found in a 282 subdirectory of your GCC sources named 'gmp', it will be built 283 together with GCC. Alternatively, if GMP is already installed but 284 it is not in your library search path, you will have to configure 285 with the '--with-gmp' configure option. See also '--with-gmp-lib' 286 and '--with-gmp-include'. The in-tree build is only supported with 287 the GMP version that download_prerequisites installs. 288 289 MPFR Library version 3.1.0 (or later) 290 291 Necessary to build GCC. It can be downloaded from 292 <https://www.mpfr.org>. If an MPFR source distribution is found in 293 a subdirectory of your GCC sources named 'mpfr', it will be built 294 together with GCC. Alternatively, if MPFR is already installed but 295 it is not in your default library search path, the '--with-mpfr' 296 configure option should be used. See also '--with-mpfr-lib' and 297 '--with-mpfr-include'. The in-tree build is only supported with 298 the MPFR version that download_prerequisites installs. 299 300 MPC Library version 1.0.1 (or later) 301 302 Necessary to build GCC. It can be downloaded from 303 <https://www.multiprecision.org/mpc/>. If an MPC source 304 distribution is found in a subdirectory of your GCC sources named 305 'mpc', it will be built together with GCC. Alternatively, if MPC is 306 already installed but it is not in your default library search 307 path, the '--with-mpc' configure option should be used. See also 308 '--with-mpc-lib' and '--with-mpc-include'. The in-tree build is 309 only supported with the MPC version that download_prerequisites 310 installs. 311 312 isl Library version 0.15 or later. 313 314 Necessary to build GCC with the Graphite loop optimizations. It 315 can be downloaded from 316 <https://gcc.gnu.org/pub/gcc/infrastructure/>. If an isl source 317 distribution is found in a subdirectory of your GCC sources named 318 'isl', it will be built together with GCC. Alternatively, the 319 '--with-isl' configure option should be used if isl is not 320 installed in your default library search path. 321 322 zstd Library. 323 324 Necessary to build GCC with zstd compression used for LTO bytecode. 325 The library is searched in your default library patch search. 326 Alternatively, the '--with-zstd' configure option should be used. 327 328 Tools/packages necessary for modifying GCC 329 ========================================== 330 331 autoconf version 2.69 332 GNU m4 version 1.4.6 (or later) 333 334 Necessary when modifying 'configure.ac', 'aclocal.m4', etc. to 335 regenerate 'configure' and 'config.in' files. 336 337 automake version 1.15.1 338 339 Necessary when modifying a 'Makefile.am' file to regenerate its 340 associated 'Makefile.in'. 341 342 Much of GCC does not use automake, so directly edit the 343 'Makefile.in' file. Specifically this applies to the 'gcc', 344 'intl', 'libcpp', 'libiberty', 'libobjc' directories as well as any 345 of their subdirectories. 346 347 For directories that use automake, GCC requires the latest release 348 in the 1.15 series, which is currently 1.15.1. When regenerating a 349 directory to a newer version, please update all the directories 350 using an older 1.15 to the latest released version. 351 352 gettext version 0.14.5 (or later) 353 354 Needed to regenerate 'gcc.pot'. 355 356 gperf version 2.7.2 (or later) 357 358 Necessary when modifying 'gperf' input files, e.g. 359 'gcc/cp/cfns.gperf' to regenerate its associated header file, e.g. 360 'gcc/cp/cfns.h'. 361 362 DejaGnu version 1.5.3 (or later) 363 Expect 364 Tcl 365 366 Necessary to run the GCC testsuite; see the section on testing for 367 details. 368 369 autogen version 5.5.4 (or later) and 370 guile version 1.4.1 (or later) 371 372 Necessary to regenerate 'fixinc/fixincl.x' from 373 'fixinc/inclhack.def' and 'fixinc/*.tpl'. 374 375 Necessary to run 'make check' for 'fixinc'. 376 377 Necessary to regenerate the top level 'Makefile.in' file from 378 'Makefile.tpl' and 'Makefile.def'. 379 380 Flex version 2.5.4 (or later) 381 382 Necessary when modifying '*.l' files. 383 384 Necessary to build GCC during development because the generated 385 output files are not included in the version-controlled source 386 repository. They are included in releases. 387 388 Texinfo version 4.7 (or later) 389 390 Necessary for running 'makeinfo' when modifying '*.texi' files to 391 test your changes. 392 393 Necessary for running 'make dvi' or 'make pdf' to create printable 394 documentation in DVI or PDF format. Texinfo version 4.8 or later 395 is required for 'make pdf'. 396 397 Necessary to build GCC documentation during development because the 398 generated output files are not included in the repository. They 399 are included in releases. 400 401 TeX (any working version) 402 403 Necessary for running 'texi2dvi' and 'texi2pdf', which are used 404 when running 'make dvi' or 'make pdf' to create DVI or PDF files, 405 respectively. 406 407 Sphinx version 1.0 (or later) 408 409 Necessary to regenerate 'jit/docs/_build/texinfo' from the '.rst' 410 files in the directories below 'jit/docs'. 411 412 git (any version) 413 SSH (any version) 414 415 Necessary to access the source repository. Public releases and 416 weekly snapshots of the development sources are also available via 417 HTTPS. 418 419 GNU diffutils version 2.7 (or later) 420 421 Useful when submitting patches for the GCC source code. 422 423 patch version 2.5.4 (or later) 424 425 Necessary when applying patches, created with 'diff', to one's own 426 sources. 427 428 429 File: gccinstall.info, Node: Downloading the source, Next: Configuration, Prev: Prerequisites, Up: Installing GCC 430 431 3 Downloading GCC 432 ***************** 433 434 GCC is distributed via git and via HTTPS as tarballs compressed with 435 'gzip' or 'bzip2'. 436 437 Please refer to the releases web page for information on how to 438 obtain GCC. 439 440 The source distribution includes the C, C++, Objective-C, Fortran, 441 and Ada (in the case of GCC 3.1 and later) compilers, as well as runtime 442 libraries for C++, Objective-C, and Fortran. For previous versions 443 these were downloadable as separate components such as the core GCC 444 distribution, which included the C language front end and shared 445 components, and language-specific distributions including the language 446 front end and the language runtime (where appropriate). 447 448 If you also intend to build binutils (either to upgrade an existing 449 installation or for use in place of the corresponding tools of your OS), 450 unpack the binutils distribution either in the same directory or a 451 separate one. In the latter case, add symbolic links to any components 452 of the binutils you intend to build alongside the compiler ('bfd', 453 'binutils', 'gas', 'gprof', 'ld', 'opcodes', ...) to the directory 454 containing the GCC sources. 455 456 Likewise the GMP, MPFR and MPC libraries can be automatically built 457 together with GCC. You may simply run the 458 'contrib/download_prerequisites' script in the GCC source directory to 459 set up everything. Otherwise unpack the GMP, MPFR and/or MPC source 460 distributions in the directory containing the GCC sources and rename 461 their directories to 'gmp', 'mpfr' and 'mpc', respectively (or use 462 symbolic links with the same name). 463 464 465 File: gccinstall.info, Node: Configuration, Next: Building, Prev: Downloading the source, Up: Installing GCC 466 467 4 Installing GCC: Configuration 468 ******************************* 469 470 Like most GNU software, GCC must be configured before it can be built. 471 This document describes the recommended configuration procedure for both 472 native and cross targets. 473 474 We use SRCDIR to refer to the toplevel source directory for GCC; we 475 use OBJDIR to refer to the toplevel build/object directory. 476 477 If you obtained the sources by cloning the repository, SRCDIR must 478 refer to the top 'gcc' directory, the one where the 'MAINTAINERS' file 479 can be found, and not its 'gcc' subdirectory, otherwise the build will 480 fail. 481 482 If either SRCDIR or OBJDIR is located on an automounted NFS file 483 system, the shell's built-in 'pwd' command will return temporary 484 pathnames. Using these can lead to various sorts of build problems. To 485 avoid this issue, set the 'PWDCMD' environment variable to an 486 automounter-aware 'pwd' command, e.g., 'pawd' or 'amq -w', during the 487 configuration and build phases. 488 489 First, we *highly* recommend that GCC be built into a separate 490 directory from the sources which does *not* reside within the source 491 tree. This is how we generally build GCC; building where SRCDIR == 492 OBJDIR should still work, but doesn't get extensive testing; building 493 where OBJDIR is a subdirectory of SRCDIR is unsupported. 494 495 If you have previously built GCC in the same directory for a 496 different target machine, do 'make distclean' to delete all files that 497 might be invalid. One of the files this deletes is 'Makefile'; if 'make 498 distclean' complains that 'Makefile' does not exist or issues a message 499 like "don't know how to make distclean" it probably means that the 500 directory is already suitably clean. However, with the recommended 501 method of building in a separate OBJDIR, you should simply use a 502 different OBJDIR for each target. 503 504 Second, when configuring a native system, either 'cc' or 'gcc' must 505 be in your path or you must set 'CC' in your environment before running 506 configure. Otherwise the configuration scripts may fail. 507 508 To configure GCC: 509 510 % mkdir OBJDIR 511 % cd OBJDIR 512 % SRCDIR/configure [OPTIONS] [TARGET] 513 514 Distributor options 515 =================== 516 517 If you will be distributing binary versions of GCC, with modifications 518 to the source code, you should use the options described in this section 519 to make clear that your version contains modifications. 520 521 '--with-pkgversion=VERSION' 522 Specify a string that identifies your package. You may wish to 523 include a build number or build date. This version string will be 524 included in the output of 'gcc --version'. This suffix does not 525 replace the default version string, only the 'GCC' part. 526 527 The default value is 'GCC'. 528 529 '--with-bugurl=URL' 530 Specify the URL that users should visit if they wish to report a 531 bug. You are of course welcome to forward bugs reported to you to 532 the FSF, if you determine that they are not bugs in your 533 modifications. 534 535 The default value refers to the FSF's GCC bug tracker. 536 537 '--with-documentation-root-url=URL' 538 Specify the URL root that contains GCC option documentation. The 539 URL should end with a '/' character. 540 541 The default value is https://gcc.gnu.org/onlinedocs/. 542 543 '--with-changes-root-url=URL' 544 Specify the URL root that contains information about changes in GCC 545 releases like 'gcc-VERSION/changes.html'. The URL should end with 546 a '/' character. 547 548 The default value is https://gcc.gnu.org/. 549 550 Host, Build and Target specification 551 ==================================== 552 553 Specify the host, build and target machine configurations. You do this 554 when you run the 'configure' script. 555 556 The "build" machine is the system which you are using, the "host" 557 machine is the system where you want to run the resulting compiler 558 (normally the build machine), and the "target" machine is the system for 559 which you want the compiler to generate code. 560 561 If you are building a compiler to produce code for the machine it 562 runs on (a native compiler), you normally do not need to specify any 563 operands to 'configure'; it will try to guess the type of machine you 564 are on and use that as the build, host and target machines. So you 565 don't need to specify a configuration when building a native compiler 566 unless 'configure' cannot figure out what your configuration is or 567 guesses wrong. 568 569 In those cases, specify the build machine's "configuration name" with 570 the '--host' option; the host and target will default to be the same as 571 the host machine. 572 573 Here is an example: 574 575 ./configure --host=x86_64-pc-linux-gnu 576 577 A configuration name may be canonical or it may be more or less 578 abbreviated ('config.sub' script produces canonical versions). 579 580 A canonical configuration name has three parts, separated by dashes. 581 It looks like this: 'CPU-COMPANY-SYSTEM'. 582 583 Here are the possible CPU types: 584 585 aarch64, aarch64_be, alpha, alpha64, amdgcn, arc, arceb, arm, 586 armeb, avr, bfin, bpf, cr16, cris, csky, epiphany, fido, fr30, frv, 587 ft32, h8300, hppa, hppa2.0, hppa64, i486, i686, ia64, iq2000, lm32, 588 loongarch64, m32c, m32r, m32rle, m68k, mcore, microblaze, 589 microblazeel, mips, mips64, mips64el, mips64octeon, mips64orion, 590 mips64vr, mipsel, mipsisa32, mipsisa32r2, mipsisa64, mipsisa64r2, 591 mipsisa64r2el, mipsisa64sb1, mipsisa64sr71k, mipstx39, mmix, 592 mn10300, moxie, msp430, nds32be, nds32le, nios2, nvptx, or1k, 593 pdp11, powerpc, powerpc64, powerpc64le, powerpcle, pru, riscv32, 594 riscv32be, riscv64, riscv64be, rl78, rx, s390, s390x, sh, shle, 595 sparc, sparc64, tic6x, tilegx, tilegxbe, tilepro, v850, v850e, 596 v850e1, vax, visium, x86_64, xstormy16, xtensa 597 598 Here is a list of system types: 599 600 aixVERSION, amdhsa, aout, cygwin, darwinVERSION, eabi, eabialtivec, 601 eabisim, eabisimaltivec, elf, elf32, elfbare, elfoabi, 602 freebsdVERSION, gnu, hpux, hpuxVERSION, kfreebsd-gnu, 603 kopensolaris-gnu, linux-androideabi, linux-gnu, linux-gnu_altivec, 604 linux-musl, linux-uclibc, lynxos, mingw32, mingw32crt, mmixware, 605 msdosdjgpp, netbsd, netbsdelfVERSION, nto-qnx, openbsd, rtems, 606 solarisVERSION, symbianelf, tpf, uclinux, uclinux_eabi, vms, 607 vxworks, vxworksae, vxworksmils 608 609 Options specification 610 ===================== 611 612 Use OPTIONS to override several configure time options for GCC. A list 613 of supported OPTIONS follows; 'configure --help' may list other options, 614 but those not listed below may not work and should not normally be used. 615 616 Note that each '--enable' option has a corresponding '--disable' 617 option and that each '--with' option has a corresponding '--without' 618 option. 619 620 '--prefix=DIRNAME' 621 Specify the toplevel installation directory. This is the 622 recommended way to install the tools into a directory other than 623 the default. The toplevel installation directory defaults to 624 '/usr/local'. 625 626 We *highly* recommend against DIRNAME being the same or a 627 subdirectory of OBJDIR or vice versa. If specifying a directory 628 beneath a user's home directory tree, some shells will not expand 629 DIRNAME correctly if it contains the '~' metacharacter; use '$HOME' 630 instead. 631 632 The following standard 'autoconf' options are supported. Normally 633 you should not need to use these options. 634 '--exec-prefix=DIRNAME' 635 Specify the toplevel installation directory for 636 architecture-dependent files. The default is 'PREFIX'. 637 638 '--bindir=DIRNAME' 639 Specify the installation directory for the executables called 640 by users (such as 'gcc' and 'g++'). The default is 641 'EXEC-PREFIX/bin'. 642 643 '--libdir=DIRNAME' 644 Specify the installation directory for object code libraries 645 and internal data files of GCC. The default is 646 'EXEC-PREFIX/lib'. 647 648 '--libexecdir=DIRNAME' 649 Specify the installation directory for internal executables of 650 GCC. The default is 'EXEC-PREFIX/libexec'. 651 652 '--with-slibdir=DIRNAME' 653 Specify the installation directory for the shared libgcc 654 library. The default is 'LIBDIR'. 655 656 '--datarootdir=DIRNAME' 657 Specify the root of the directory tree for read-only 658 architecture-independent data files referenced by GCC. The 659 default is 'PREFIX/share'. 660 661 '--infodir=DIRNAME' 662 Specify the installation directory for documentation in info 663 format. The default is 'DATAROOTDIR/info'. 664 665 '--datadir=DIRNAME' 666 Specify the installation directory for some 667 architecture-independent data files referenced by GCC. The 668 default is 'DATAROOTDIR'. 669 670 '--docdir=DIRNAME' 671 Specify the installation directory for documentation files 672 (other than Info) for GCC. The default is 'DATAROOTDIR/doc'. 673 674 '--htmldir=DIRNAME' 675 Specify the installation directory for HTML documentation 676 files. The default is 'DOCDIR'. 677 678 '--pdfdir=DIRNAME' 679 Specify the installation directory for PDF documentation 680 files. The default is 'DOCDIR'. 681 682 '--mandir=DIRNAME' 683 Specify the installation directory for manual pages. The 684 default is 'DATAROOTDIR/man'. (Note that the manual pages are 685 only extracts from the full GCC manuals, which are provided in 686 Texinfo format. The manpages are derived by an automatic 687 conversion process from parts of the full manual.) 688 689 '--with-gxx-include-dir=DIRNAME' 690 Specify the installation directory for G++ header files. The 691 default depends on other configuration options, and differs 692 between cross and native configurations. 693 694 '--with-specs=SPECS' 695 Specify additional command line driver SPECS. This can be 696 useful if you need to turn on a non-standard feature by 697 default without modifying the compiler's source code, for 698 instance 699 '--with-specs=%{!fcommon:%{!fno-common:-fno-common}}'. *Note 700 Specifying subprocesses and the switches to pass to them: 701 (gcc)Spec Files, 702 703 '--program-prefix=PREFIX' 704 GCC supports some transformations of the names of its programs when 705 installing them. This option prepends PREFIX to the names of 706 programs to install in BINDIR (see above). For example, specifying 707 '--program-prefix=foo-' would result in 'gcc' being installed as 708 '/usr/local/bin/foo-gcc'. 709 710 '--program-suffix=SUFFIX' 711 Appends SUFFIX to the names of programs to install in BINDIR (see 712 above). For example, specifying '--program-suffix=-3.1' would 713 result in 'gcc' being installed as '/usr/local/bin/gcc-3.1'. 714 715 '--program-transform-name=PATTERN' 716 Applies the 'sed' script PATTERN to be applied to the names of 717 programs to install in BINDIR (see above). PATTERN has to consist 718 of one or more basic 'sed' editing commands, separated by 719 semicolons. For example, if you want the 'gcc' program name to be 720 transformed to the installed program '/usr/local/bin/myowngcc' and 721 the 'g++' program name to be transformed to 722 '/usr/local/bin/gspecial++' without changing other program names, 723 you could use the pattern 724 '--program-transform-name='s/^gcc$/myowngcc/; s/^g++$/gspecial++/'' 725 to achieve this effect. 726 727 All three options can be combined and used together, resulting in 728 more complex conversion patterns. As a basic rule, PREFIX (and 729 SUFFIX) are prepended (appended) before further transformations can 730 happen with a special transformation script PATTERN. 731 732 As currently implemented, this option only takes effect for native 733 builds; cross compiler binaries' names are not transformed even 734 when a transformation is explicitly asked for by one of these 735 options. 736 737 For native builds, some of the installed programs are also 738 installed with the target alias in front of their name, as in 739 'i686-pc-linux-gnu-gcc'. All of the above transformations happen 740 before the target alias is prepended to the name--so, specifying 741 '--program-prefix=foo-' and 'program-suffix=-3.1', the resulting 742 binary would be installed as 743 '/usr/local/bin/i686-pc-linux-gnu-foo-gcc-3.1'. 744 745 As a last shortcoming, none of the installed Ada programs are 746 transformed yet, which will be fixed in some time. 747 748 '--with-local-prefix=DIRNAME' 749 Specify the installation directory for local include files. The 750 default is '/usr/local'. Specify this option if you want the 751 compiler to search directory 'DIRNAME/include' for locally 752 installed header files _instead_ of '/usr/local/include'. 753 754 You should specify '--with-local-prefix' *only* if your site has a 755 different convention (not '/usr/local') for where to put 756 site-specific files. 757 758 The default value for '--with-local-prefix' is '/usr/local' 759 regardless of the value of '--prefix'. Specifying '--prefix' has 760 no effect on which directory GCC searches for local header files. 761 This may seem counterintuitive, but actually it is logical. 762 763 The purpose of '--prefix' is to specify where to _install GCC_. The 764 local header files in '/usr/local/include'--if you put any in that 765 directory--are not part of GCC. They are part of other 766 programs--perhaps many others. (GCC installs its own header files 767 in another directory which is based on the '--prefix' value.) 768 769 Both the local-prefix include directory and the GCC-prefix include 770 directory are part of GCC's "system include" directories. Although 771 these two directories are not fixed, they need to be searched in 772 the proper order for the correct processing of the include_next 773 directive. The local-prefix include directory is searched before 774 the GCC-prefix include directory. Another characteristic of system 775 include directories is that pedantic warnings are turned off for 776 headers in these directories. 777 778 Some autoconf macros add '-I DIRECTORY' options to the compiler 779 command line, to ensure that directories containing installed 780 packages' headers are searched. When DIRECTORY is one of GCC's 781 system include directories, GCC will ignore the option so that 782 system directories continue to be processed in the correct order. 783 This may result in a search order different from what was specified 784 but the directory will still be searched. 785 786 GCC automatically searches for ordinary libraries using 787 'GCC_EXEC_PREFIX'. Thus, when the same installation prefix is used 788 for both GCC and packages, GCC will automatically search for both 789 headers and libraries. This provides a configuration that is easy 790 to use. GCC behaves in a manner similar to that when it is 791 installed as a system compiler in '/usr'. 792 793 Sites that need to install multiple versions of GCC may not want to 794 use the above simple configuration. It is possible to use the 795 '--program-prefix', '--program-suffix' and 796 '--program-transform-name' options to install multiple versions 797 into a single directory, but it may be simpler to use different 798 prefixes and the '--with-local-prefix' option to specify the 799 location of the site-specific files for each version. It will then 800 be necessary for users to specify explicitly the location of local 801 site libraries (e.g., with 'LIBRARY_PATH'). 802 803 The same value can be used for both '--with-local-prefix' and 804 '--prefix' provided it is not '/usr'. This can be used to avoid 805 the default search of '/usr/local/include'. 806 807 *Do not* specify '/usr' as the '--with-local-prefix'! The 808 directory you use for '--with-local-prefix' *must not* contain any 809 of the system's standard header files. If it did contain them, 810 certain programs would be miscompiled (including GNU Emacs, on 811 certain targets), because this would override and nullify the 812 header file corrections made by the 'fixincludes' script. 813 814 Indications are that people who use this option use it based on 815 mistaken ideas of what it is for. People use it as if it specified 816 where to install part of GCC. Perhaps they make this assumption 817 because installing GCC creates the directory. 818 819 '--with-gcc-major-version-only' 820 Specifies that GCC should use only the major number rather than 821 MAJOR.MINOR.PATCHLEVEL in filesystem paths. 822 823 '--with-native-system-header-dir=DIRNAME' 824 Specifies that DIRNAME is the directory that contains native system 825 header files, rather than '/usr/include'. This option is most 826 useful if you are creating a compiler that should be isolated from 827 the system as much as possible. It is most commonly used with the 828 '--with-sysroot' option and will cause GCC to search DIRNAME inside 829 the system root specified by that option. 830 831 '--enable-shared[=PACKAGE[,...]]' 832 Build shared versions of libraries, if shared libraries are 833 supported on the target platform. Unlike GCC 2.95.x and earlier, 834 shared libraries are enabled by default on all platforms that 835 support shared libraries. 836 837 If a list of packages is given as an argument, build shared 838 libraries only for the listed packages. For other packages, only 839 static libraries will be built. Package names currently recognized 840 in the GCC tree are 'libgcc' (also known as 'gcc'), 'libstdc++' 841 (not 'libstdc++-v3'), 'libffi', 'zlib', 'boehm-gc', 'ada', 842 'libada', 'libgo', 'libobjc', and 'libphobos'. Note 'libiberty' 843 does not support shared libraries at all. 844 845 Use '--disable-shared' to build only static libraries. Note that 846 '--disable-shared' does not accept a list of package names as 847 argument, only '--enable-shared' does. 848 849 Contrast with '--enable-host-shared', which affects _host_ code. 850 851 '--enable-host-shared' 852 Specify that the _host_ code should be built into 853 position-independent machine code (with -fPIC), allowing it to be 854 used within shared libraries, but yielding a slightly slower 855 compiler. 856 857 This option is required when building the libgccjit.so library. 858 859 Contrast with '--enable-shared', which affects _target_ libraries. 860 861 '--with-gnu-as' 862 Specify that the compiler should assume that the assembler it finds 863 is the GNU assembler. However, this does not modify the rules to 864 find an assembler and will result in confusion if the assembler 865 found is not actually the GNU assembler. (Confusion may also 866 result if the compiler finds the GNU assembler but has not been 867 configured with '--with-gnu-as'.) If you have more than one 868 assembler installed on your system, you may want to use this option 869 in connection with '--with-as=PATHNAME' or 870 '--with-build-time-tools=PATHNAME'. 871 872 The following systems are the only ones where it makes a difference 873 whether you use the GNU assembler. On any other system, 874 '--with-gnu-as' has no effect. 875 876 * 'hppa1.0-ANY-ANY' 877 * 'hppa1.1-ANY-ANY' 878 * 'sparc-sun-solaris2.ANY' 879 * 'sparc64-ANY-solaris2.ANY' 880 881 '--with-as=PATHNAME' 882 Specify that the compiler should use the assembler pointed to by 883 PATHNAME, rather than the one found by the standard rules to find 884 an assembler, which are: 885 * Unless GCC is being built with a cross compiler, check the 886 'LIBEXEC/gcc/TARGET/VERSION' directory. LIBEXEC defaults to 887 'EXEC-PREFIX/libexec'; EXEC-PREFIX defaults to PREFIX, which 888 defaults to '/usr/local' unless overridden by the 889 '--prefix=PATHNAME' switch described above. TARGET is the 890 target system triple, such as 'sparc-sun-solaris2.7', and 891 VERSION denotes the GCC version, such as 3.0. 892 893 * If the target system is the same that you are building on, 894 check operating system specific directories (e.g. 895 '/usr/ccs/bin' on Solaris 2). 896 897 * Check in the 'PATH' for a tool whose name is prefixed by the 898 target system triple. 899 900 * Check in the 'PATH' for a tool whose name is not prefixed by 901 the target system triple, if the host and target system triple 902 are the same (in other words, we use a host tool if it can be 903 used for the target as well). 904 905 You may want to use '--with-as' if no assembler is installed in the 906 directories listed above, or if you have multiple assemblers 907 installed and want to choose one that is not found by the above 908 rules. 909 910 '--with-gnu-ld' 911 Same as '--with-gnu-as' but for the linker. 912 913 '--with-ld=PATHNAME' 914 Same as '--with-as' but for the linker. 915 916 '--with-dsymutil=PATHNAME' 917 Same as '--with-as' but for the debug linker (only used on Darwin 918 platforms so far). 919 920 '--with-tls=DIALECT' 921 Specify the default TLS dialect, for systems were there is a 922 choice. For ARM targets, possible values for DIALECT are 'gnu' or 923 'gnu2', which select between the original GNU dialect and the GNU 924 TLS descriptor-based dialect. 925 926 '--enable-multiarch' 927 Specify whether to enable or disable multiarch support. The 928 default is to check for glibc start files in a multiarch location, 929 and enable it if the files are found. The auto detection is 930 enabled for native builds, and for cross builds configured with 931 '--with-sysroot', and without '--with-native-system-header-dir'. 932 More documentation about multiarch can be found at 933 <https://wiki.debian.org/Multiarch>. 934 935 '--enable-sjlj-exceptions' 936 Force use of the 'setjmp'/'longjmp'-based scheme for exceptions. 937 'configure' ordinarily picks the correct value based on the 938 platform. Only use this option if you are sure you need a 939 different setting. 940 941 '--enable-vtable-verify' 942 Specify whether to enable or disable the vtable verification 943 feature. Enabling this feature causes libstdc++ to be built with 944 its virtual calls in verifiable mode. This means that, when linked 945 with libvtv, every virtual call in libstdc++ will verify the vtable 946 pointer through which the call will be made before actually making 947 the call. If not linked with libvtv, the verifier will call stub 948 functions (in libstdc++ itself) and do nothing. If vtable 949 verification is disabled, then libstdc++ is not built with its 950 virtual calls in verifiable mode at all. However the libvtv 951 library will still be built (see '--disable-libvtv' to turn off 952 building libvtv). '--disable-vtable-verify' is the default. 953 954 '--disable-gcov' 955 Specify that the run-time library used for coverage analysis and 956 associated host tools should not be built. 957 958 '--disable-multilib' 959 Specify that multiple target libraries to support different target 960 variants, calling conventions, etc. should not be built. The 961 default is to build a predefined set of them. 962 963 Some targets provide finer-grained control over which multilibs are 964 built (e.g., '--disable-softfloat'): 965 'arm-*-*' 966 fpu, 26bit, underscore, interwork, biendian, nofmult. 967 968 'm68*-*-*' 969 softfloat, m68881, m68000, m68020. 970 971 'mips*-*-*' 972 single-float, biendian, softfloat. 973 974 'msp430-*-*' 975 no-exceptions 976 977 'powerpc*-*-*, rs6000*-*-*' 978 aix64, pthread, softfloat, powercpu, powerpccpu, powerpcos, 979 biendian, sysv, aix. 980 981 '--with-multilib-list=LIST' 982 '--without-multilib-list' 983 Specify what multilibs to build. LIST is a comma separated list of 984 values, possibly consisting of a single value. Currently only 985 implemented for aarch64*-*-*, arm*-*-*, loongarch64-*-*, 986 riscv*-*-*, sh*-*-* and x86-64-*-linux*. The accepted values and 987 meaning for each target is given below. 988 989 'aarch64*-*-*' 990 LIST is a comma separated list of 'ilp32', and 'lp64' to 991 enable ILP32 and LP64 run-time libraries, respectively. If 992 LIST is empty, then there will be no multilibs and only the 993 default run-time library will be built. If LIST is 'default' 994 or -with-multilib-list= is not specified, then the default set 995 of libraries is selected based on the value of '--target'. 996 997 'arm*-*-*' 998 LIST is a comma separated list of 'aprofile' and 'rmprofile' 999 to build multilibs for A or R and M architecture profiles 1000 respectively. Note that, due to some limitation of the 1001 current multilib framework, using the combined 1002 'aprofile,rmprofile' multilibs selects in some cases a less 1003 optimal multilib than when using the multilib profile for the 1004 architecture targetted. The special value 'default' is also 1005 accepted and is equivalent to omitting the option, i.e., only 1006 the default run-time library will be enabled. 1007 1008 LIST may instead contain '@name', to use the multilib 1009 configuration Makefile fragment 'name' in 'gcc/config/arm' in 1010 the source tree (it is part of the corresponding sources, 1011 after all). It is recommended, but not required, that files 1012 used for this purpose to be named starting with 't-ml-', to 1013 make their intended purpose self-evident, in line with GCC 1014 conventions. Such files enable custom, user-chosen multilib 1015 lists to be configured. Whether multiple such files can be 1016 used together depends on the contents of the supplied files. 1017 See 'gcc/config/arm/t-multilib' and its supplementary 1018 'gcc/config/arm/t-*profile' files for an example of what such 1019 Makefile fragments might look like for this version of GCC. 1020 The macros expected to be defined in these fragments are not 1021 stable across GCC releases, so make sure they define the 1022 'MULTILIB'-related macros expected by the version of GCC you 1023 are building. *Note Target Makefile Fragments: (gccint)Target 1024 Fragment. 1025 1026 The table below gives the combination of ISAs, architectures, 1027 FPUs and floating-point ABIs for which multilibs are built for 1028 each predefined profile. The union of these options is 1029 considered when specifying both 'aprofile' and 'rmprofile'. 1030 1031 Option aprofile rmprofile 1032 ISAs '-marm' and '-mthumb' 1033 '-mthumb' 1034 Architecturesdefault default architecture 1035 architecture '-march=armv6s-m' 1036 '-march=armv7-a' '-march=armv7-m' 1037 '-march=armv7ve' '-march=armv7e-m' 1038 '-march=armv8-a' '-march=armv8-m.base' 1039 '-march=armv8-m.main' 1040 '-march=armv7' 1041 FPUs none none 1042 '-mfpu=vfpv3-d16' '-mfpu=vfpv3-d16' 1043 '-mfpu=neon' '-mfpu=fpv4-sp-d16' 1044 '-mfpu=vfpv4-d16' '-mfpu=fpv5-sp-d16' 1045 '-mfpu=neon-vfpv4' '-mfpu=fpv5-d16' 1046 '-mfpu=neon-fp-armv8' 1047 floating-point'-mfloat-abi=soft' '-mfloat-abi=soft' 1048 ABIs '-mfloat-abi=softfp' '-mfloat-abi=softfp' 1049 '-mfloat-abi=hard' '-mfloat-abi=hard' 1050 1051 'loongarch*-*-*' 1052 LIST is a comma-separated list of the following ABI 1053 identifiers: 'lp64d[/base]' 'lp64f[/base]' 'lp64d[/base]', 1054 where the '/base' suffix may be omitted, to enable their 1055 respective run-time libraries. If LIST is empty or 'default', 1056 or if '--with-multilib-list' is not specified, then the 1057 default ABI as specified by '--with-abi' or implied by 1058 '--target' is selected. 1059 1060 'riscv*-*-*' 1061 LIST is a single ABI name. The target architecture must be 1062 either 'rv32gc' or 'rv64gc'. This will build a single 1063 multilib for the specified architecture and ABI pair. If 1064 '--with-multilib-list' is not given, then a default set of 1065 multilibs is selected based on the value of '--target'. This 1066 is usually a large set of multilibs. 1067 1068 'sh*-*-*' 1069 LIST is a comma separated list of CPU names. These must be of 1070 the form 'sh*' or 'm*' (in which case they match the compiler 1071 option for that processor). The list should not contain any 1072 endian options - these are handled by '--with-endian'. 1073 1074 If LIST is empty, then there will be no multilibs for extra 1075 processors. The multilib for the secondary endian remains 1076 enabled. 1077 1078 As a special case, if an entry in the list starts with a '!' 1079 (exclamation point), then it is added to the list of excluded 1080 multilibs. Entries of this sort should be compatible with 1081 'MULTILIB_EXCLUDES' (once the leading '!' has been stripped). 1082 1083 If '--with-multilib-list' is not given, then a default set of 1084 multilibs is selected based on the value of '--target'. This 1085 is usually the complete set of libraries, but some targets 1086 imply a more specialized subset. 1087 1088 Example 1: to configure a compiler for SH4A only, but 1089 supporting both endians, with little endian being the default: 1090 --with-cpu=sh4a --with-endian=little,big --with-multilib-list= 1091 1092 Example 2: to configure a compiler for both SH4A and 1093 SH4AL-DSP, but with only little endian SH4AL: 1094 --with-cpu=sh4a --with-endian=little,big \ 1095 --with-multilib-list=sh4al,!mb/m4al 1096 1097 'x86-64-*-linux*' 1098 LIST is a comma separated list of 'm32', 'm64' and 'mx32' to 1099 enable 32-bit, 64-bit and x32 run-time libraries, 1100 respectively. If LIST is empty, then there will be no 1101 multilibs and only the default run-time library will be 1102 enabled. 1103 1104 If '--with-multilib-list' is not given, then only 32-bit and 1105 64-bit run-time libraries will be enabled. 1106 1107 '--with-multilib-generator=CONFIG' 1108 Specify what multilibs to build. CONFIG is a semicolon separated 1109 list of values, possibly consisting of a single value. Currently 1110 only implemented for riscv*-*-elf*. The accepted values and 1111 meanings are given below. 1112 1113 Every config is constructed with four components: architecture 1114 string, ABI, reuse rule with architecture string and reuse rule 1115 with sub-extension. 1116 1117 Example 1: Add multi-lib suppport for rv32i with ilp32. 1118 rv32i-ilp32-- 1119 1120 Example 2: Add multi-lib suppport for rv32i with ilp32 and 1121 rv32imafd with ilp32. 1122 rv32i-ilp32--;rv32imafd-ilp32-- 1123 1124 Example 3: Add multi-lib suppport for rv32i with ilp32; rv32im with 1125 ilp32 and rv32ic with ilp32 will reuse this multi-lib set. 1126 rv32i-ilp32-rv32im-c 1127 1128 Example 4: Add multi-lib suppport for rv64ima with lp64; rv64imaf 1129 with lp64, rv64imac with lp64 and rv64imafc with lp64 will reuse 1130 this multi-lib set. 1131 rv64ima-lp64--f,c,fc 1132 1133 '--with-multilib-generator' have an optional configuration argument 1134 '--cmodel=val' for code model, this option will expand with other 1135 config options, VAL is a comma separated list of possible code 1136 model, currently we support medlow and medany. 1137 1138 Example 5: Add multi-lib suppport for rv64ima with lp64; rv64ima 1139 with lp64 and medlow code model 1140 rv64ima-lp64--;--cmodel=medlow 1141 1142 Example 6: Add multi-lib suppport for rv64ima with lp64; rv64ima 1143 with lp64 and medlow code model; rv64ima with lp64 and medany code 1144 model 1145 rv64ima-lp64--;--cmodel=medlow,medany 1146 1147 '--with-endian=ENDIANS' 1148 Specify what endians to use. Currently only implemented for 1149 sh*-*-*. 1150 1151 ENDIANS may be one of the following: 1152 'big' 1153 Use big endian exclusively. 1154 'little' 1155 Use little endian exclusively. 1156 'big,little' 1157 Use big endian by default. Provide a multilib for little 1158 endian. 1159 'little,big' 1160 Use little endian by default. Provide a multilib for big 1161 endian. 1162 1163 '--enable-threads' 1164 Specify that the target supports threads. This affects the 1165 Objective-C compiler and runtime library, and exception handling 1166 for other languages like C++. On some systems, this is the 1167 default. 1168 1169 In general, the best (and, in many cases, the only known) threading 1170 model available will be configured for use. Beware that on some 1171 systems, GCC has not been taught what threading models are 1172 generally available for the system. In this case, 1173 '--enable-threads' is an alias for '--enable-threads=single'. 1174 1175 '--disable-threads' 1176 Specify that threading support should be disabled for the system. 1177 This is an alias for '--enable-threads=single'. 1178 1179 '--enable-threads=LIB' 1180 Specify that LIB is the thread support library. This affects the 1181 Objective-C compiler and runtime library, and exception handling 1182 for other languages like C++. The possibilities for LIB are: 1183 1184 'aix' 1185 AIX thread support. 1186 'dce' 1187 DCE thread support. 1188 'lynx' 1189 LynxOS thread support. 1190 'mipssde' 1191 MIPS SDE thread support. 1192 'no' 1193 This is an alias for 'single'. 1194 'posix' 1195 Generic POSIX/Unix98 thread support. 1196 'rtems' 1197 RTEMS thread support. 1198 'single' 1199 Disable thread support, should work for all platforms. 1200 'tpf' 1201 TPF thread support. 1202 'vxworks' 1203 VxWorks thread support. 1204 'win32' 1205 Microsoft Win32 API thread support. 1206 1207 '--enable-tls' 1208 Specify that the target supports TLS (Thread Local Storage). 1209 Usually configure can correctly determine if TLS is supported. In 1210 cases where it guesses incorrectly, TLS can be explicitly enabled 1211 or disabled with '--enable-tls' or '--disable-tls'. This can 1212 happen if the assembler supports TLS but the C library does not, or 1213 if the assumptions made by the configure test are incorrect. 1214 1215 '--disable-tls' 1216 Specify that the target does not support TLS. This is an alias for 1217 '--enable-tls=no'. 1218 1219 '--disable-tm-clone-registry' 1220 Disable TM clone registry in libgcc. It is enabled in libgcc by 1221 default. This option helps to reduce code size for embedded 1222 targets which do not use transactional memory. 1223 1224 '--with-cpu=CPU' 1225 '--with-cpu-32=CPU' 1226 '--with-cpu-64=CPU' 1227 Specify which cpu variant the compiler should generate code for by 1228 default. CPU will be used as the default value of the '-mcpu=' 1229 switch. This option is only supported on some targets, including 1230 ARC, ARM, i386, M68k, PowerPC, and SPARC. It is mandatory for ARC. 1231 The '--with-cpu-32' and '--with-cpu-64' options specify separate 1232 default CPUs for 32-bit and 64-bit modes; these options are only 1233 supported for aarch64, i386, x86-64, PowerPC, and SPARC. 1234 1235 '--with-schedule=CPU' 1236 '--with-arch=CPU' 1237 '--with-arch-32=CPU' 1238 '--with-arch-64=CPU' 1239 '--with-tune=CPU' 1240 '--with-tune-32=CPU' 1241 '--with-tune-64=CPU' 1242 '--with-abi=ABI' 1243 '--with-fpu=TYPE' 1244 '--with-float=TYPE' 1245 These configure options provide default values for the 1246 '-mschedule=', '-march=', '-mtune=', '-mabi=', and '-mfpu=' options 1247 and for '-mhard-float' or '-msoft-float'. As with '--with-cpu', 1248 which switches will be accepted and acceptable values of the 1249 arguments depend on the target. 1250 1251 '--with-mode=MODE' 1252 Specify if the compiler should default to '-marm' or '-mthumb'. 1253 This option is only supported on ARM targets. 1254 1255 '--with-stack-offset=NUM' 1256 This option sets the default for the -mstack-offset=NUM option, and 1257 will thus generally also control the setting of this option for 1258 libraries. This option is only supported on Epiphany targets. 1259 1260 '--with-fpmath=ISA' 1261 This options sets '-mfpmath=sse' by default and specifies the 1262 default ISA for floating-point arithmetics. You can select either 1263 'sse' which enables '-msse2' or 'avx' which enables '-mavx' by 1264 default. This option is only supported on i386 and x86-64 targets. 1265 1266 '--with-fp-32=MODE' 1267 On MIPS targets, set the default value for the '-mfp' option when 1268 using the o32 ABI. The possibilities for MODE are: 1269 '32' 1270 Use the o32 FP32 ABI extension, as with the '-mfp32' 1271 command-line option. 1272 'xx' 1273 Use the o32 FPXX ABI extension, as with the '-mfpxx' 1274 command-line option. 1275 '64' 1276 Use the o32 FP64 ABI extension, as with the '-mfp64' 1277 command-line option. 1278 In the absence of this configuration option the default is to use 1279 the o32 FP32 ABI extension. 1280 1281 '--with-odd-spreg-32' 1282 On MIPS targets, set the '-modd-spreg' option by default when using 1283 the o32 ABI. 1284 1285 '--without-odd-spreg-32' 1286 On MIPS targets, set the '-mno-odd-spreg' option by default when 1287 using the o32 ABI. This is normally used in conjunction with 1288 '--with-fp-32=64' in order to target the o32 FP64A ABI extension. 1289 1290 '--with-nan=ENCODING' 1291 On MIPS targets, set the default encoding convention to use for the 1292 special not-a-number (NaN) IEEE 754 floating-point data. The 1293 possibilities for ENCODING are: 1294 'legacy' 1295 Use the legacy encoding, as with the '-mnan=legacy' 1296 command-line option. 1297 '2008' 1298 Use the 754-2008 encoding, as with the '-mnan=2008' 1299 command-line option. 1300 To use this configuration option you must have an assembler version 1301 installed that supports the '-mnan=' command-line option too. In 1302 the absence of this configuration option the default convention is 1303 the legacy encoding, as when neither of the '-mnan=2008' and 1304 '-mnan=legacy' command-line options has been used. 1305 1306 '--with-divide=TYPE' 1307 Specify how the compiler should generate code for checking for 1308 division by zero. This option is only supported on the MIPS 1309 target. The possibilities for TYPE are: 1310 'traps' 1311 Division by zero checks use conditional traps (this is the 1312 default on systems that support conditional traps). 1313 'breaks' 1314 Division by zero checks use the break instruction. 1315 1316 '--with-llsc' 1317 On MIPS targets, make '-mllsc' the default when no '-mno-llsc' 1318 option is passed. This is the default for Linux-based targets, as 1319 the kernel will emulate them if the ISA does not provide them. 1320 1321 '--without-llsc' 1322 On MIPS targets, make '-mno-llsc' the default when no '-mllsc' 1323 option is passed. 1324 1325 '--with-synci' 1326 On MIPS targets, make '-msynci' the default when no '-mno-synci' 1327 option is passed. 1328 1329 '--without-synci' 1330 On MIPS targets, make '-mno-synci' the default when no '-msynci' 1331 option is passed. This is the default. 1332 1333 '--with-lxc1-sxc1' 1334 On MIPS targets, make '-mlxc1-sxc1' the default when no 1335 '-mno-lxc1-sxc1' option is passed. This is the default. 1336 1337 '--without-lxc1-sxc1' 1338 On MIPS targets, make '-mno-lxc1-sxc1' the default when no 1339 '-mlxc1-sxc1' option is passed. The indexed load/store 1340 instructions are not directly a problem but can lead to unexpected 1341 behaviour when deployed in an application intended for a 32-bit 1342 address space but run on a 64-bit processor. The issue is seen 1343 because all known MIPS 64-bit Linux kernels execute o32 and n32 1344 applications with 64-bit addressing enabled which affects the 1345 overflow behaviour of the indexed addressing mode. GCC will assume 1346 that ordinary 32-bit arithmetic overflow behaviour is the same 1347 whether performed as an 'addu' instruction or as part of the 1348 address calculation in 'lwxc1' type instructions. This assumption 1349 holds true in a pure 32-bit environment and can hold true in a 1350 64-bit environment if the address space is accurately set to be 1351 32-bit for o32 and n32. 1352 1353 '--with-madd4' 1354 On MIPS targets, make '-mmadd4' the default when no '-mno-madd4' 1355 option is passed. This is the default. 1356 1357 '--without-madd4' 1358 On MIPS targets, make '-mno-madd4' the default when no '-mmadd4' 1359 option is passed. The 'madd4' instruction family can be 1360 problematic when targeting a combination of cores that implement 1361 these instructions differently. There are two known cores that 1362 implement these as fused operations instead of unfused (where 1363 unfused is normally expected). Disabling these instructions is the 1364 only way to ensure compatible code is generated; this will incur a 1365 performance penalty. 1366 1367 '--with-mips-plt' 1368 On MIPS targets, make use of copy relocations and PLTs. These 1369 features are extensions to the traditional SVR4-based MIPS ABIs and 1370 require support from GNU binutils and the runtime C library. 1371 1372 '--with-stack-clash-protection-guard-size=SIZE' 1373 On certain targets this option sets the default stack clash 1374 protection guard size as a power of two in bytes. On AArch64 SIZE 1375 is required to be either 12 (4KB) or 16 (64KB). 1376 1377 '--with-isa-spec=ISA-SPEC-STRING' 1378 On RISC-V targets specify the default version of the RISC-V 1379 Unprivileged (formerly User-Level) ISA specification to produce 1380 code conforming to. The possibilities for ISA-SPEC-STRING are: 1381 '2.2' 1382 Produce code conforming to version 2.2. 1383 '20190608' 1384 Produce code conforming to version 20190608. 1385 '20191213' 1386 Produce code conforming to version 20191213. 1387 In the absence of this configuration option the default version is 1388 20191213. 1389 1390 '--enable-__cxa_atexit' 1391 Define if you want to use __cxa_atexit, rather than atexit, to 1392 register C++ destructors for local statics and global objects. 1393 This is essential for fully standards-compliant handling of 1394 destructors, but requires __cxa_atexit in libc. This option is 1395 currently only available on systems with GNU libc. When enabled, 1396 this will cause '-fuse-cxa-atexit' to be passed by default. 1397 1398 '--enable-gnu-indirect-function' 1399 Define if you want to enable the 'ifunc' attribute. This option is 1400 currently only available on systems with GNU libc on certain 1401 targets. 1402 1403 '--enable-target-optspace' 1404 Specify that target libraries should be optimized for code space 1405 instead of code speed. This is the default for the m32r platform. 1406 1407 '--with-cpp-install-dir=DIRNAME' 1408 Specify that the user visible 'cpp' program should be installed in 1409 'PREFIX/DIRNAME/cpp', in addition to BINDIR. 1410 1411 '--enable-comdat' 1412 Enable COMDAT group support. This is primarily used to override 1413 the automatically detected value. 1414 1415 '--enable-initfini-array' 1416 Force the use of sections '.init_array' and '.fini_array' (instead 1417 of '.init' and '.fini') for constructors and destructors. Option 1418 '--disable-initfini-array' has the opposite effect. If neither 1419 option is specified, the configure script will try to guess whether 1420 the '.init_array' and '.fini_array' sections are supported and, if 1421 they are, use them. 1422 1423 '--enable-link-mutex' 1424 When building GCC, use a mutex to avoid linking the compilers for 1425 multiple languages at the same time, to avoid thrashing on build 1426 systems with limited free memory. The default is not to use such a 1427 mutex. 1428 1429 '--enable-link-serialization' 1430 When building GCC, use make dependencies to serialize linking the 1431 compilers for multiple languages, to avoid thrashing on build 1432 systems with limited free memory. The default is not to add such 1433 dependencies and thus with parallel make potentially link different 1434 compilers concurrently. If the argument is a positive integer, 1435 allow that number of concurrent link processes for the large 1436 binaries. 1437 1438 '--enable-maintainer-mode' 1439 The build rules that regenerate the Autoconf and Automake output 1440 files as well as the GCC master message catalog 'gcc.pot' are 1441 normally disabled. This is because it can only be rebuilt if the 1442 complete source tree is present. If you have changed the sources 1443 and want to rebuild the catalog, configuring with 1444 '--enable-maintainer-mode' will enable this. Note that you need a 1445 recent version of the 'gettext' tools to do so. 1446 1447 '--disable-bootstrap' 1448 For a native build, the default configuration is to perform a 1449 3-stage bootstrap of the compiler when 'make' is invoked, testing 1450 that GCC can compile itself correctly. If you want to disable this 1451 process, you can configure with '--disable-bootstrap'. 1452 1453 '--enable-bootstrap' 1454 In special cases, you may want to perform a 3-stage build even if 1455 the target and host triplets are different. This is possible when 1456 the host can run code compiled for the target (e.g. host is 1457 i686-linux, target is i486-linux). Starting from GCC 4.2, to do 1458 this you have to configure explicitly with '--enable-bootstrap'. 1459 1460 '--enable-generated-files-in-srcdir' 1461 Neither the .c and .h files that are generated from Bison and flex 1462 nor the info manuals and man pages that are built from the .texi 1463 files are present in the repository development tree. When 1464 building GCC from that development tree, or from one of our 1465 snapshots, those generated files are placed in your build 1466 directory, which allows for the source to be in a readonly 1467 directory. 1468 1469 If you configure with '--enable-generated-files-in-srcdir' then 1470 those generated files will go into the source directory. This is 1471 mainly intended for generating release or prerelease tarballs of 1472 the GCC sources, since it is not a requirement that the users of 1473 source releases to have flex, Bison, or makeinfo. 1474 1475 '--enable-version-specific-runtime-libs' 1476 Specify that runtime libraries should be installed in the compiler 1477 specific subdirectory ('LIBDIR/gcc') rather than the usual places. 1478 In addition, 'libstdc++''s include files will be installed into 1479 'LIBDIR' unless you overruled it by using 1480 '--with-gxx-include-dir=DIRNAME'. Using this option is 1481 particularly useful if you intend to use several versions of GCC in 1482 parallel. The default is 'yes' for 'libada', and 'no' for the 1483 remaining libraries. 1484 1485 '--with-aix-soname='aix', 'svr4' or 'both'' 1486 Traditional AIX shared library versioning (versioned 'Shared 1487 Object' files as members of unversioned 'Archive Library' files 1488 named 'lib.a') causes numerous headaches for package managers. 1489 However, 'Import Files' as members of 'Archive Library' files allow 1490 for *filename-based versioning* of shared libraries as seen on 1491 Linux/SVR4, where this is called the "SONAME". But as they prevent 1492 static linking, 'Import Files' may be used with 'Runtime Linking' 1493 only, where the linker does search for 'libNAME.so' before 1494 'libNAME.a' library filenames with the '-lNAME' linker flag. 1495 1496 For detailed information please refer to the AIX ld Command 1497 reference. 1498 1499 As long as shared library creation is enabled, upon: 1500 '--with-aix-soname=aix' 1501 '--with-aix-soname=both' 1502 A (traditional AIX) 'Shared Archive Library' file is created: 1503 * using the 'libNAME.a' filename scheme 1504 * with the 'Shared Object' file as archive member named 1505 'libNAME.so.V' (except for 'libgcc_s', where the 'Shared 1506 Object' file is named 'shr.o' for backwards 1507 compatibility), which 1508 - is used for runtime loading from inside the 1509 'libNAME.a' file 1510 - is used for dynamic loading via 1511 'dlopen("libNAME.a(libNAME.so.V)", RTLD_MEMBER)' 1512 - is used for shared linking 1513 - is used for static linking, so no separate 'Static 1514 Archive Library' file is needed 1515 '--with-aix-soname=both' 1516 '--with-aix-soname=svr4' 1517 A (second) 'Shared Archive Library' file is created: 1518 * using the 'libNAME.so.V' filename scheme 1519 * with the 'Shared Object' file as archive member named 1520 'shr.o', which 1521 - is created with the '-G linker flag' 1522 - has the 'F_LOADONLY' flag set 1523 - is used for runtime loading from inside the 1524 'libNAME.so.V' file 1525 - is used for dynamic loading via 1526 'dlopen("libNAME.so.V(shr.o)", RTLD_MEMBER)' 1527 * with the 'Import File' as archive member named 'shr.imp', 1528 which 1529 - refers to 'libNAME.so.V(shr.o)' as the "SONAME", to 1530 be recorded in the 'Loader Section' of subsequent 1531 binaries 1532 - indicates whether 'libNAME.so.V(shr.o)' is 32 or 64 1533 bit 1534 - lists all the public symbols exported by 1535 'lib.so.V(shr.o)', eventually decorated with the 1536 ''weak' Keyword' 1537 - is necessary for shared linking against 1538 'lib.so.V(shr.o)' 1539 A symbolic link using the 'libNAME.so' filename scheme is 1540 created: 1541 * pointing to the 'libNAME.so.V' 'Shared Archive Library' 1542 file 1543 * to permit the 'ld Command' to find 'lib.so.V(shr.imp)' 1544 via the '-lNAME' argument (requires 'Runtime Linking' to 1545 be enabled) 1546 * to permit dynamic loading of 'lib.so.V(shr.o)' without 1547 the need to specify the version number via 1548 'dlopen("libNAME.so(shr.o)", RTLD_MEMBER)' 1549 1550 As long as static library creation is enabled, upon: 1551 '--with-aix-soname=svr4' 1552 A 'Static Archive Library' is created: 1553 * using the 'libNAME.a' filename scheme 1554 * with all the 'Static Object' files as archive members, 1555 which 1556 - are used for static linking 1557 1558 While the aix-soname='svr4' option does not create 'Shared Object' 1559 files as members of unversioned 'Archive Library' files any more, 1560 package managers still are responsible to transfer 'Shared Object' 1561 files found as member of a previously installed unversioned 1562 'Archive Library' file into the newly installed 'Archive Library' 1563 file with the same filename. 1564 1565 _WARNING:_ Creating 'Shared Object' files with 'Runtime Linking' 1566 enabled may bloat the TOC, eventually leading to 'TOC overflow' 1567 errors, requiring the use of either the '-Wl,-bbigtoc' linker flag 1568 (seen to break with the 'GDB' debugger) or some of the TOC-related 1569 compiler flags, *Note RS/6000 and PowerPC Options: (gcc)RS/6000 and 1570 PowerPC Options. 1571 1572 '--with-aix-soname' is currently supported by 'libgcc_s' only, so 1573 this option is still experimental and not for normal use yet. 1574 1575 Default is the traditional behavior '--with-aix-soname='aix''. 1576 1577 '--enable-languages=LANG1,LANG2,...' 1578 Specify that only a particular subset of compilers and their 1579 runtime libraries should be built. For a list of valid values for 1580 LANGN you can issue the following command in the 'gcc' directory of 1581 your GCC source tree: 1582 grep ^language= */config-lang.in 1583 Currently, you can use any of the following: 'all', 'default', 1584 'ada', 'c', 'c++', 'd', 'fortran', 'go', 'jit', 'lto', 'objc', 1585 'obj-c++'. Building the Ada compiler has special requirements, see 1586 below. If you do not pass this flag, or specify the option 1587 'default', then the default languages available in the 'gcc' 1588 sub-tree will be configured. Ada, D, Go, Jit, and Objective-C++ 1589 are not default languages. LTO is not a default language, but is 1590 built by default because '--enable-lto' is enabled by default. The 1591 other languages are default languages. If 'all' is specified, then 1592 all available languages are built. An exception is 'jit' language, 1593 which requires '--enable-host-shared' to be included with 'all'. 1594 1595 '--enable-stage1-languages=LANG1,LANG2,...' 1596 Specify that a particular subset of compilers and their runtime 1597 libraries should be built with the system C compiler during stage 1 1598 of the bootstrap process, rather than only in later stages with the 1599 bootstrapped C compiler. The list of valid values is the same as 1600 for '--enable-languages', and the option 'all' will select all of 1601 the languages enabled by '--enable-languages'. This option is 1602 primarily useful for GCC development; for instance, when a 1603 development version of the compiler cannot bootstrap due to 1604 compiler bugs, or when one is debugging front ends other than the C 1605 front end. When this option is used, one can then build the target 1606 libraries for the specified languages with the stage-1 compiler by 1607 using 'make stage1-bubble all-target', or run the testsuite on the 1608 stage-1 compiler for the specified languages using 'make 1609 stage1-start check-gcc'. 1610 1611 '--disable-libada' 1612 Specify that the run-time libraries and tools used by GNAT should 1613 not be built. This can be useful for debugging, or for 1614 compatibility with previous Ada build procedures, when it was 1615 required to explicitly do a 'make -C gcc gnatlib_and_tools'. 1616 1617 '--disable-libsanitizer' 1618 Specify that the run-time libraries for the various sanitizers 1619 should not be built. 1620 1621 '--disable-libssp' 1622 Specify that the run-time libraries for stack smashing protection 1623 should not be built or linked against. On many targets library 1624 support is provided by the C library instead. 1625 1626 '--disable-libquadmath' 1627 Specify that the GCC quad-precision math library should not be 1628 built. On some systems, the library is required to be linkable 1629 when building the Fortran front end, unless 1630 '--disable-libquadmath-support' is used. 1631 1632 '--disable-libquadmath-support' 1633 Specify that the Fortran front end and 'libgfortran' do not add 1634 support for 'libquadmath' on systems supporting it. 1635 1636 '--disable-libgomp' 1637 Specify that the GNU Offloading and Multi Processing Runtime 1638 Library should not be built. 1639 1640 '--disable-libvtv' 1641 Specify that the run-time libraries used by vtable verification 1642 should not be built. 1643 1644 '--with-dwarf2' 1645 Specify that the compiler should use DWARF 2 debugging information 1646 as the default. 1647 1648 '--with-advance-toolchain=AT' 1649 On 64-bit PowerPC Linux systems, configure the compiler to use the 1650 header files, library files, and the dynamic linker from the 1651 Advance Toolchain release AT instead of the default versions that 1652 are provided by the Linux distribution. In general, this option is 1653 intended for the developers of GCC, and it is not intended for 1654 general use. 1655 1656 '--enable-targets=all' 1657 '--enable-targets=TARGET_LIST' 1658 Some GCC targets, e.g. powerpc64-linux, build bi-arch compilers. 1659 These are compilers that are able to generate either 64-bit or 1660 32-bit code. Typically, the corresponding 32-bit target, e.g. 1661 powerpc-linux for powerpc64-linux, only generates 32-bit code. 1662 This option enables the 32-bit target to be a bi-arch compiler, 1663 which is useful when you want a bi-arch compiler that defaults to 1664 32-bit, and you are building a bi-arch or multi-arch binutils in a 1665 combined tree. On mips-linux, this will build a tri-arch compiler 1666 (ABI o32/n32/64), defaulted to o32. Currently, this option only 1667 affects sparc-linux, powerpc-linux, x86-linux, mips-linux and 1668 s390-linux. 1669 1670 '--enable-default-pie' 1671 Turn on '-fPIE' and '-pie' by default. 1672 1673 '--enable-secureplt' 1674 This option enables '-msecure-plt' by default for powerpc-linux. 1675 *Note RS/6000 and PowerPC Options: (gcc)RS/6000 and PowerPC 1676 Options, 1677 1678 '--enable-default-ssp' 1679 Turn on '-fstack-protector-strong' by default. 1680 1681 '--enable-cld' 1682 This option enables '-mcld' by default for 32-bit x86 targets. 1683 *Note i386 and x86-64 Options: (gcc)i386 and x86-64 Options, 1684 1685 '--enable-large-address-aware' 1686 The '--enable-large-address-aware' option arranges for MinGW 1687 executables to be linked using the '--large-address-aware' option, 1688 that enables the use of more than 2GB of memory. If GCC is 1689 configured with this option, its effects can be reversed by passing 1690 the '-Wl,--disable-large-address-aware' option to the so-configured 1691 compiler driver. 1692 1693 '--enable-win32-registry' 1694 '--enable-win32-registry=KEY' 1695 '--disable-win32-registry' 1696 The '--enable-win32-registry' option enables Microsoft 1697 Windows-hosted GCC to look up installations paths in the registry 1698 using the following key: 1699 1700 HKEY_LOCAL_MACHINE\SOFTWARE\Free Software Foundation\KEY 1701 1702 KEY defaults to GCC version number, and can be overridden by the 1703 '--enable-win32-registry=KEY' option. Vendors and distributors who 1704 use custom installers are encouraged to provide a different key, 1705 perhaps one comprised of vendor name and GCC version number, to 1706 avoid conflict with existing installations. This feature is 1707 enabled by default, and can be disabled by 1708 '--disable-win32-registry' option. This option has no effect on 1709 the other hosts. 1710 1711 '--nfp' 1712 Specify that the machine does not have a floating point unit. This 1713 option only applies to 'm68k-sun-sunosN'. On any other system, 1714 '--nfp' has no effect. 1715 1716 '--enable-werror' 1717 '--disable-werror' 1718 '--enable-werror=yes' 1719 '--enable-werror=no' 1720 When you specify this option, it controls whether certain files in 1721 the compiler are built with '-Werror' in bootstrap stage2 and 1722 later. If you don't specify it, '-Werror' is turned on for the 1723 main development trunk. However it defaults to off for release 1724 branches and final releases. The specific files which get 1725 '-Werror' are controlled by the Makefiles. 1726 1727 '--enable-checking' 1728 '--disable-checking' 1729 '--enable-checking=LIST' 1730 This option controls performing internal consistency checks in the 1731 compiler. It does not change the generated code, but adds error 1732 checking of the requested complexity. This slows down the compiler 1733 and may only work properly if you are building the compiler with 1734 GCC. 1735 1736 When the option is not specified, the active set of checks depends 1737 on context. Namely, bootstrap stage 1 defaults to 1738 '--enable-checking=yes', builds from release branches or release 1739 archives default to '--enable-checking=release', and otherwise 1740 '--enable-checking=yes,extra' is used. When the option is 1741 specified without a LIST, the result is the same as 1742 '--enable-checking=yes'. Likewise, '--disable-checking' is 1743 equivalent to '--enable-checking=no'. 1744 1745 The categories of checks available in LIST are 'yes' (most common 1746 checks 'assert,misc,gc,gimple,rtlflag,runtime,tree,types'), 'no' 1747 (no checks at all), 'all' (all but 'valgrind'), 'release' (cheapest 1748 checks 'assert,runtime') or 'none' (same as 'no'). 'release' 1749 checks are always on and to disable them '--disable-checking' or 1750 '--enable-checking=no[,<other checks>]' must be explicitly 1751 requested. Disabling assertions makes the compiler and runtime 1752 slightly faster but increases the risk of undetected internal 1753 errors causing wrong code to be generated. 1754 1755 Individual checks can be enabled with these flags: 'assert', 'df', 1756 'extra', 'fold', 'gc', 'gcac', 'gimple', 'misc', 'rtl', 'rtlflag', 1757 'runtime', 'tree', 'types' and 'valgrind'. 'extra' extends 'misc' 1758 checking with extra checks that might affect code generation and 1759 should therefore not differ between stage1 and later stages in 1760 bootstrap. 1761 1762 The 'valgrind' check requires the external 'valgrind' simulator, 1763 available from <https://valgrind.org>. The 'rtl' checks are 1764 expensive and the 'df', 'gcac' and 'valgrind' checks are very 1765 expensive. 1766 1767 '--disable-stage1-checking' 1768 '--enable-stage1-checking' 1769 '--enable-stage1-checking=LIST' 1770 This option affects only bootstrap build. If no 1771 '--enable-checking' option is specified the stage1 compiler is 1772 built with 'yes' checking enabled, otherwise the stage1 checking 1773 flags are the same as specified by '--enable-checking'. To build 1774 the stage1 compiler with different checking options use 1775 '--enable-stage1-checking'. The list of checking options is the 1776 same as for '--enable-checking'. If your system is too slow or too 1777 small to bootstrap a released compiler with checking for stage1 1778 enabled, you can use '--disable-stage1-checking' to disable 1779 checking for the stage1 compiler. 1780 1781 '--enable-coverage' 1782 '--enable-coverage=LEVEL' 1783 With this option, the compiler is built to collect self coverage 1784 information, every time it is run. This is for internal 1785 development purposes, and only works when the compiler is being 1786 built with gcc. The LEVEL argument controls whether the compiler 1787 is built optimized or not, values are 'opt' and 'noopt'. For 1788 coverage analysis you want to disable optimization, for performance 1789 analysis you want to enable optimization. When coverage is 1790 enabled, the default level is without optimization. 1791 1792 '--enable-gather-detailed-mem-stats' 1793 When this option is specified more detailed information on memory 1794 allocation is gathered. This information is printed when using 1795 '-fmem-report'. 1796 1797 '--enable-valgrind-annotations' 1798 Mark selected memory related operations in the compiler when run 1799 under valgrind to suppress false positives. 1800 1801 '--enable-nls' 1802 '--disable-nls' 1803 The '--enable-nls' option enables Native Language Support (NLS), 1804 which lets GCC output diagnostics in languages other than American 1805 English. Native Language Support is enabled by default if not 1806 doing a canadian cross build. The '--disable-nls' option disables 1807 NLS. 1808 1809 '--with-included-gettext' 1810 If NLS is enabled, the '--with-included-gettext' option causes the 1811 build procedure to prefer its copy of GNU 'gettext'. 1812 1813 '--with-catgets' 1814 If NLS is enabled, and if the host lacks 'gettext' but has the 1815 inferior 'catgets' interface, the GCC build procedure normally 1816 ignores 'catgets' and instead uses GCC's copy of the GNU 'gettext' 1817 library. The '--with-catgets' option causes the build procedure to 1818 use the host's 'catgets' in this situation. 1819 1820 '--with-libiconv-prefix=DIR' 1821 Search for libiconv header files in 'DIR/include' and libiconv 1822 library files in 'DIR/lib'. 1823 1824 '--enable-obsolete' 1825 Enable configuration for an obsoleted system. If you attempt to 1826 configure GCC for a system (build, host, or target) which has been 1827 obsoleted, and you do not specify this flag, configure will halt 1828 with an error message. 1829 1830 All support for systems which have been obsoleted in one release of 1831 GCC is removed entirely in the next major release, unless someone 1832 steps forward to maintain the port. 1833 1834 '--enable-decimal-float' 1835 '--enable-decimal-float=yes' 1836 '--enable-decimal-float=no' 1837 '--enable-decimal-float=bid' 1838 '--enable-decimal-float=dpd' 1839 '--disable-decimal-float' 1840 Enable (or disable) support for the C decimal floating point 1841 extension that is in the IEEE 754-2008 standard. This is enabled 1842 by default only on PowerPC, i386, and x86_64 GNU/Linux systems. 1843 Other systems may also support it, but require the user to 1844 specifically enable it. You can optionally control which decimal 1845 floating point format is used (either 'bid' or 'dpd'). The 'bid' 1846 (binary integer decimal) format is default on i386 and x86_64 1847 systems, and the 'dpd' (densely packed decimal) format is default 1848 on PowerPC systems. 1849 1850 '--enable-fixed-point' 1851 '--disable-fixed-point' 1852 Enable (or disable) support for C fixed-point arithmetic. This 1853 option is enabled by default for some targets (such as MIPS) which 1854 have hardware-support for fixed-point operations. On other 1855 targets, you may enable this option manually. 1856 1857 '--with-long-double-128' 1858 Specify if 'long double' type should be 128-bit by default on 1859 selected GNU/Linux architectures. If using 1860 '--without-long-double-128', 'long double' will be by default 1861 64-bit, the same as 'double' type. When neither of these configure 1862 options are used, the default will be 128-bit 'long double' when 1863 built against GNU C Library 2.4 and later, 64-bit 'long double' 1864 otherwise. 1865 1866 '--with-long-double-format=ibm' 1867 '--with-long-double-format=ieee' 1868 Specify whether 'long double' uses the IBM extended double format 1869 or the IEEE 128-bit floating point format on PowerPC Linux systems. 1870 This configuration switch will only work on little endian PowerPC 1871 Linux systems and on big endian 64-bit systems where the default 1872 cpu is at least power7 (i.e. '--with-cpu=power7', 1873 '--with-cpu=power8', or '--with-cpu=power9' is used). 1874 1875 If you use the '--with-long-double-64' configuration option, the 1876 '--with-long-double-format=ibm' and 1877 '--with-long-double-format=ieee' options are ignored. 1878 1879 The default 'long double' format is to use IBM extended double. 1880 Until all of the libraries are converted to use IEEE 128-bit 1881 floating point, it is not recommended to use 1882 '--with-long-double-format=ieee'. 1883 1884 '--enable-fdpic' 1885 On SH Linux systems, generate ELF FDPIC code. 1886 1887 '--with-gmp=PATHNAME' 1888 '--with-gmp-include=PATHNAME' 1889 '--with-gmp-lib=PATHNAME' 1890 '--with-mpfr=PATHNAME' 1891 '--with-mpfr-include=PATHNAME' 1892 '--with-mpfr-lib=PATHNAME' 1893 '--with-mpc=PATHNAME' 1894 '--with-mpc-include=PATHNAME' 1895 '--with-mpc-lib=PATHNAME' 1896 If you want to build GCC but do not have the GMP library, the MPFR 1897 library and/or the MPC library installed in a standard location and 1898 do not have their sources present in the GCC source tree then you 1899 can explicitly specify the directory where they are installed 1900 ('--with-gmp=GMPINSTALLDIR', '--with-mpfr=MPFRINSTALLDIR', 1901 '--with-mpc=MPCINSTALLDIR'). The '--with-gmp=GMPINSTALLDIR' option 1902 is shorthand for '--with-gmp-lib=GMPINSTALLDIR/lib' and 1903 '--with-gmp-include=GMPINSTALLDIR/include'. Likewise the 1904 '--with-mpfr=MPFRINSTALLDIR' option is shorthand for 1905 '--with-mpfr-lib=MPFRINSTALLDIR/lib' and 1906 '--with-mpfr-include=MPFRINSTALLDIR/include', also the 1907 '--with-mpc=MPCINSTALLDIR' option is shorthand for 1908 '--with-mpc-lib=MPCINSTALLDIR/lib' and 1909 '--with-mpc-include=MPCINSTALLDIR/include'. If these shorthand 1910 assumptions are not correct, you can use the explicit include and 1911 lib options directly. You might also need to ensure the shared 1912 libraries can be found by the dynamic linker when building and 1913 using GCC, for example by setting the runtime shared library path 1914 variable ('LD_LIBRARY_PATH' on GNU/Linux and Solaris systems). 1915 1916 These flags are applicable to the host platform only. When 1917 building a cross compiler, they will not be used to configure 1918 target libraries. 1919 1920 '--with-isl=PATHNAME' 1921 '--with-isl-include=PATHNAME' 1922 '--with-isl-lib=PATHNAME' 1923 If you do not have the isl library installed in a standard location 1924 and you want to build GCC, you can explicitly specify the directory 1925 where it is installed ('--with-isl=ISLINSTALLDIR'). The 1926 '--with-isl=ISLINSTALLDIR' option is shorthand for 1927 '--with-isl-lib=ISLINSTALLDIR/lib' and 1928 '--with-isl-include=ISLINSTALLDIR/include'. If this shorthand 1929 assumption is not correct, you can use the explicit include and lib 1930 options directly. 1931 1932 These flags are applicable to the host platform only. When 1933 building a cross compiler, they will not be used to configure 1934 target libraries. 1935 1936 '--with-stage1-ldflags=FLAGS' 1937 This option may be used to set linker flags to be used when linking 1938 stage 1 of GCC. These are also used when linking GCC if configured 1939 with '--disable-bootstrap'. If '--with-stage1-libs' is not set to 1940 a value, then the default is '-static-libstdc++ -static-libgcc', if 1941 supported. 1942 1943 '--with-stage1-libs=LIBS' 1944 This option may be used to set libraries to be used when linking 1945 stage 1 of GCC. These are also used when linking GCC if configured 1946 with '--disable-bootstrap'. 1947 1948 '--with-boot-ldflags=FLAGS' 1949 This option may be used to set linker flags to be used when linking 1950 stage 2 and later when bootstrapping GCC. If -with-boot-libs is not 1951 is set to a value, then the default is '-static-libstdc++ 1952 -static-libgcc'. 1953 1954 '--with-boot-libs=LIBS' 1955 This option may be used to set libraries to be used when linking 1956 stage 2 and later when bootstrapping GCC. 1957 1958 '--with-debug-prefix-map=MAP' 1959 Convert source directory names using '-fdebug-prefix-map' when 1960 building runtime libraries. 'MAP' is a space-separated list of 1961 maps of the form 'OLD=NEW'. 1962 1963 '--enable-linker-build-id' 1964 Tells GCC to pass '--build-id' option to the linker for all final 1965 links (links performed without the '-r' or '--relocatable' option), 1966 if the linker supports it. If you specify 1967 '--enable-linker-build-id', but your linker does not support 1968 '--build-id' option, a warning is issued and the 1969 '--enable-linker-build-id' option is ignored. The default is off. 1970 1971 '--with-linker-hash-style=CHOICE' 1972 Tells GCC to pass '--hash-style=CHOICE' option to the linker for 1973 all final links. CHOICE can be one of 'sysv', 'gnu', and 'both' 1974 where 'sysv' is the default. 1975 1976 '--enable-gnu-unique-object' 1977 '--disable-gnu-unique-object' 1978 Tells GCC to use the gnu_unique_object relocation for C++ template 1979 static data members and inline function local statics. Enabled by 1980 default for a toolchain with an assembler that accepts it and GLIBC 1981 2.11 or above, otherwise disabled. 1982 1983 '--with-diagnostics-color=CHOICE' 1984 Tells GCC to use CHOICE as the default for '-fdiagnostics-color=' 1985 option (if not used explicitly on the command line). CHOICE can be 1986 one of 'never', 'auto', 'always', and 'auto-if-env' where 'auto' is 1987 the default. 'auto-if-env' makes '-fdiagnostics-color=auto' the 1988 default if 'GCC_COLORS' is present and non-empty in the environment 1989 of the compiler, and '-fdiagnostics-color=never' otherwise. 1990 1991 '--with-diagnostics-urls=CHOICE' 1992 Tells GCC to use CHOICE as the default for '-fdiagnostics-urls=' 1993 option (if not used explicitly on the command line). CHOICE can be 1994 one of 'never', 'auto', 'always', and 'auto-if-env' where 'auto' is 1995 the default. 'auto-if-env' makes '-fdiagnostics-urls=auto' the 1996 default if 'GCC_URLS' or 'TERM_URLS' is present and non-empty in 1997 the environment of the compiler, and '-fdiagnostics-urls=never' 1998 otherwise. 1999 2000 '--enable-lto' 2001 '--disable-lto' 2002 Enable support for link-time optimization (LTO). This is enabled by 2003 default, and may be disabled using '--disable-lto'. 2004 2005 '--enable-linker-plugin-configure-flags=FLAGS' 2006 '--enable-linker-plugin-flags=FLAGS' 2007 By default, linker plugins (such as the LTO plugin) are built for 2008 the host system architecture. For the case that the linker has a 2009 different (but run-time compatible) architecture, these flags can 2010 be specified to build plugins that are compatible to the linker. 2011 For example, if you are building GCC for a 64-bit x86_64 2012 ('x86_64-pc-linux-gnu') host system, but have a 32-bit x86 2013 GNU/Linux ('i686-pc-linux-gnu') linker executable (which is 2014 executable on the former system), you can configure GCC as follows 2015 for getting compatible linker plugins: 2016 2017 % SRCDIR/configure \ 2018 --host=x86_64-pc-linux-gnu \ 2019 --enable-linker-plugin-configure-flags=--host=i686-pc-linux-gnu \ 2020 --enable-linker-plugin-flags='CC=gcc\ -m32\ -Wl,-rpath,[...]/i686-pc-linux-gnu/lib' 2021 2022 '--with-plugin-ld=PATHNAME' 2023 Enable an alternate linker to be used at link-time optimization 2024 (LTO) link time when '-fuse-linker-plugin' is enabled. This linker 2025 should have plugin support such as gold starting with version 2.20 2026 or GNU ld starting with version 2.21. See '-fuse-linker-plugin' 2027 for details. 2028 2029 '--enable-canonical-system-headers' 2030 '--disable-canonical-system-headers' 2031 Enable system header path canonicalization for 'libcpp'. This can 2032 produce shorter header file paths in diagnostics and dependency 2033 output files, but these changed header paths may conflict with some 2034 compilation environments. Enabled by default, and may be disabled 2035 using '--disable-canonical-system-headers'. 2036 2037 '--with-glibc-version=MAJOR.MINOR' 2038 Tell GCC that when the GNU C Library (glibc) is used on the target 2039 it will be version MAJOR.MINOR or later. Normally this can be 2040 detected from the C library's header files, but this option may be 2041 needed when bootstrapping a cross toolchain without the header 2042 files available for building the initial bootstrap compiler. 2043 2044 If GCC is configured with some multilibs that use glibc and some 2045 that do not, this option applies only to the multilibs that use 2046 glibc. However, such configurations may not work well as not all 2047 the relevant configuration in GCC is on a per-multilib basis. 2048 2049 '--enable-as-accelerator-for=TARGET' 2050 Build as offload target compiler. Specify offload host triple by 2051 TARGET. 2052 2053 '--enable-offload-targets=TARGET1[=PATH1],...,TARGETN[=PATHN]' 2054 Enable offloading to targets TARGET1, ..., TARGETN. Offload 2055 compilers are expected to be already installed. Default search 2056 path for them is 'EXEC-PREFIX', but it can be changed by specifying 2057 paths PATH1, ..., PATHN. 2058 2059 % SRCDIR/configure \ 2060 --enable-offload-targets=x86_64-intelmicemul-linux-gnu=/path/to/x86_64/compiler,nvptx-none 2061 2062 '--enable-offload-defaulted' 2063 2064 Tell GCC that configured but not installed offload compilers and 2065 libgomp plugins are silently ignored. Useful for distribution 2066 compilers where those are in separate optional packages and where 2067 the presence or absence of those optional packages should determine 2068 the actual supported offloading target set rather than the GCC 2069 configure-time selection. 2070 2071 '--with-hsa-runtime=PATHNAME' 2072 '--with-hsa-runtime-include=PATHNAME' 2073 '--with-hsa-runtime-lib=PATHNAME' 2074 2075 If you configure GCC with offloading which uses an HSA run-time 2076 such as AMDGCN but do not have the HSA run-time library installed 2077 in a standard location then you can explicitly specify the 2078 directory where they are installed. The 2079 '--with-hsa-runtime=HSAINSTALLDIR' option is a shorthand for 2080 '--with-hsa-runtime-lib=HSAINSTALLDIR/lib' and 2081 '--with-hsa-runtime-include=HSAINSTALLDIR/include'. 2082 2083 '--enable-cet' 2084 '--disable-cet' 2085 Enable building target run-time libraries with control-flow 2086 instrumentation, see '-fcf-protection' option. When '--enable-cet' 2087 is specified target libraries are configured to add 2088 '-fcf-protection' and, if needed, other target specific options to 2089 a set of building options. 2090 2091 '--enable-cet=auto' is default. CET is enabled on Linux/x86 if 2092 target binutils supports 'Intel CET' instructions and disabled 2093 otherwise. In this case, the target libraries are configured to 2094 get additional '-fcf-protection' option. 2095 2096 '--with-riscv-attribute='yes', 'no' or 'default'' 2097 Generate RISC-V attribute by default, in order to record extra 2098 build information in object. 2099 2100 The option is disabled by default. It is enabled on RISC-V/ELF 2101 (bare-metal) target if target binutils supported. 2102 2103 '--enable-s390-excess-float-precision' 2104 '--disable-s390-excess-float-precision' 2105 On s390(x) targets, enable treatment of float expressions with 2106 double precision when in standards-compliant mode (e.g., when 2107 '--std=c99' or '-fexcess-precision=standard' are given). 2108 2109 For a native build and cross compiles that have target headers, the 2110 option's default is derived from glibc's behavior. When glibc 2111 clamps float_t to double, GCC follows and enables the option. For 2112 other cross compiles, the default is disabled. 2113 2114 '--with-zstd=PATHNAME' 2115 '--with-zstd-include=PATHNAME' 2116 '--with-zstd-lib=PATHNAME' 2117 If you do not have the 'zstd' library installed in a standard 2118 location and you want to build GCC, you can explicitly specify the 2119 directory where it is installed ('--with-zstd=ZSTDINSTALLDIR'). 2120 The '--with-zstd=ZSTDINSTALLDIR' option is shorthand for 2121 '--with-zstd-lib=ZSTDINSTALLDIR/lib' and 2122 '--with-zstd-include=ZSTDINSTALLDIR/include'. If this shorthand 2123 assumption is not correct, you can use the explicit include and lib 2124 options directly. 2125 2126 These flags are applicable to the host platform only. When 2127 building a cross compiler, they will not be used to configure 2128 target libraries. 2129 2130 Cross-Compiler-Specific Options 2131 ------------------------------- 2132 2133 The following options only apply to building cross compilers. 2134 2135 '--with-toolexeclibdir=DIR' 2136 Specify the installation directory for libraries built with a cross 2137 compiler. The default is '${gcc_tooldir}/lib'. 2138 2139 '--with-sysroot' 2140 '--with-sysroot=DIR' 2141 Tells GCC to consider DIR as the root of a tree that contains (a 2142 subset of) the root filesystem of the target operating system. 2143 Target system headers, libraries and run-time object files will be 2144 searched for in there. More specifically, this acts as if 2145 '--sysroot=DIR' was added to the default options of the built 2146 compiler. The specified directory is not copied into the install 2147 tree, unlike the options '--with-headers' and '--with-libs' that 2148 this option obsoletes. The default value, in case '--with-sysroot' 2149 is not given an argument, is '${gcc_tooldir}/sys-root'. If the 2150 specified directory is a subdirectory of '${exec_prefix}', then it 2151 will be found relative to the GCC binaries if the installation tree 2152 is moved. 2153 2154 This option affects the system root for the compiler used to build 2155 target libraries (which runs on the build system) and the compiler 2156 newly installed with 'make install'; it does not affect the 2157 compiler which is used to build GCC itself. 2158 2159 If you specify the '--with-native-system-header-dir=DIRNAME' option 2160 then the compiler will search that directory within DIRNAME for 2161 native system headers rather than the default '/usr/include'. 2162 2163 '--with-build-sysroot' 2164 '--with-build-sysroot=DIR' 2165 Tells GCC to consider DIR as the system root (see '--with-sysroot') 2166 while building target libraries, instead of the directory specified 2167 with '--with-sysroot'. This option is only useful when you are 2168 already using '--with-sysroot'. You can use '--with-build-sysroot' 2169 when you are configuring with '--prefix' set to a directory that is 2170 different from the one in which you are installing GCC and your 2171 target libraries. 2172 2173 This option affects the system root for the compiler used to build 2174 target libraries (which runs on the build system); it does not 2175 affect the compiler which is used to build GCC itself. 2176 2177 If you specify the '--with-native-system-header-dir=DIRNAME' option 2178 then the compiler will search that directory within DIRNAME for 2179 native system headers rather than the default '/usr/include'. 2180 2181 '--with-headers' 2182 '--with-headers=DIR' 2183 Deprecated in favor of '--with-sysroot'. Specifies that target 2184 headers are available when building a cross compiler. The DIR 2185 argument specifies a directory which has the target include files. 2186 These include files will be copied into the 'gcc' install 2187 directory. _This option with the DIR argument is required_ when 2188 building a cross compiler, if 'PREFIX/TARGET/sys-include' doesn't 2189 pre-exist. If 'PREFIX/TARGET/sys-include' does pre-exist, the DIR 2190 argument may be omitted. 'fixincludes' will be run on these files 2191 to make them compatible with GCC. 2192 2193 '--without-headers' 2194 Tells GCC not use any target headers from a libc when building a 2195 cross compiler. When crossing to GNU/Linux, you need the headers 2196 so GCC can build the exception handling for libgcc. 2197 2198 '--with-libs' 2199 '--with-libs="DIR1 DIR2 ... DIRN"' 2200 Deprecated in favor of '--with-sysroot'. Specifies a list of 2201 directories which contain the target runtime libraries. These 2202 libraries will be copied into the 'gcc' install directory. If the 2203 directory list is omitted, this option has no effect. 2204 2205 '--with-newlib' 2206 Specifies that 'newlib' is being used as the target C library. 2207 This causes '__eprintf' to be omitted from 'libgcc.a' on the 2208 assumption that it will be provided by 'newlib'. 2209 2210 '--with-avrlibc' 2211 Only supported for the AVR target. Specifies that 'AVR-Libc' is 2212 being used as the target C library. This causes float support 2213 functions like '__addsf3' to be omitted from 'libgcc.a' on the 2214 assumption that it will be provided by 'libm.a'. For more 2215 technical details, cf. PR54461. It is not supported for RTEMS 2216 configurations, which currently use newlib. The option is 2217 supported since version 4.7.2 and is the default in 4.8.0 and 2218 newer. 2219 2220 '--with-double={32|64|32,64|64,32}' 2221 '--with-long-double={32|64|32,64|64,32|double}' 2222 Only supported for the AVR target since version 10. Specify the 2223 default layout available for the C/C++ 'double' and 'long double' 2224 type, respectively. The following rules apply: 2225 * The first value after the '=' specifies the default layout (in 2226 bits) of the type and also the default for the '-mdouble=' 2227 resp. '-mlong-double=' compiler option. 2228 * If more than one value is specified, respective multilib 2229 variants are available, and '-mdouble=' resp. 2230 '-mlong-double=' acts as a multilib option. 2231 * If '--with-long-double=double' is specified, 'double' and 2232 'long double' will have the same layout. 2233 * The defaults are '--with-long-double=64,32' and 2234 '--with-double=32,64'. The default 'double' layout imposed by 2235 the latter is compatible with older versions of the compiler 2236 that implement 'double' as a 32-bit type, which does not 2237 comply to the language standard. 2238 Not all combinations of '--with-double=' and '--with-long-double=' 2239 are valid. For example, the combination '--with-double=32,64' 2240 '--with-long-double=32' will be rejected because the first option 2241 specifies the availability of multilibs for 'double', whereas the 2242 second option implies that 'long double' -- and hence also 'double' 2243 -- is always 32 bits wide. 2244 2245 '--with-double-comparison={tristate|bool|libf7}' 2246 Only supported for the AVR target since version 10. Specify what 2247 result format is returned by library functions that compare 64-bit 2248 floating point values ('DFmode'). The GCC default is 'tristate'. 2249 If the floating point implementation returns a boolean instead, set 2250 it to 'bool'. 2251 2252 '--with-libf7={libgcc|math|math-symbols|no}' 2253 Only supported for the AVR target since version 10. Specify to 2254 which degree code from LibF7 is included in libgcc. LibF7 is an 2255 ad-hoc, AVR-specific, 64-bit floating point emulation written in C 2256 and (inline) assembly. 'libgcc' adds support for functions that 2257 one would usually expect in libgcc like double addition, double 2258 comparisons and double conversions. 'math' also adds routines that 2259 one would expect in 'libm.a', but with '__' (two underscores) 2260 prepended to the symbol names as specified by 'math.h'. 2261 'math-symbols' also defines weak aliases for the functions declared 2262 in 'math.h'. However, '--with-libf7' won't install no 'math.h' 2263 header file whatsoever, this file must come from elsewhere. This 2264 option sets '--with-double-comparison' to 'bool'. 2265 2266 '--with-nds32-lib=LIBRARY' 2267 Specifies that LIBRARY setting is used for building 'libgcc.a'. 2268 Currently, the valid LIBRARY is 'newlib' or 'mculib'. This option 2269 is only supported for the NDS32 target. 2270 2271 '--with-build-time-tools=DIR' 2272 Specifies where to find the set of target tools (assembler, linker, 2273 etc.) that will be used while building GCC itself. This option 2274 can be useful if the directory layouts are different between the 2275 system you are building GCC on, and the system where you will 2276 deploy it. 2277 2278 For example, on an 'ia64-hp-hpux' system, you may have the GNU 2279 assembler and linker in '/usr/bin', and the native tools in a 2280 different path, and build a toolchain that expects to find the 2281 native tools in '/usr/bin'. 2282 2283 When you use this option, you should ensure that DIR includes 'ar', 2284 'as', 'ld', 'nm', 'ranlib' and 'strip' if necessary, and possibly 2285 'objdump'. Otherwise, GCC may use an inconsistent set of tools. 2286 2287 Overriding 'configure' test results 2288 ................................... 2289 2290 Sometimes, it might be necessary to override the result of some 2291 'configure' test, for example in order to ease porting to a new system 2292 or work around a bug in a test. The toplevel 'configure' script 2293 provides three variables for this: 2294 2295 'build_configargs' 2296 The contents of this variable is passed to all build 'configure' 2297 scripts. 2298 2299 'host_configargs' 2300 The contents of this variable is passed to all host 'configure' 2301 scripts. 2302 2303 'target_configargs' 2304 The contents of this variable is passed to all target 'configure' 2305 scripts. 2306 2307 In order to avoid shell and 'make' quoting issues for complex 2308 overrides, you can pass a setting for 'CONFIG_SITE' and set variables in 2309 the site file. 2310 2311 Objective-C-Specific Options 2312 ---------------------------- 2313 2314 The following options apply to the build of the Objective-C runtime 2315 library. 2316 2317 '--enable-objc-gc' 2318 Specify that an additional variant of the GNU Objective-C runtime 2319 library is built, using an external build of the 2320 Boehm-Demers-Weiser garbage collector 2321 (<https://www.hboehm.info/gc/>). This library needs to be 2322 available for each multilib variant, unless configured with 2323 '--enable-objc-gc='auto'' in which case the build of the additional 2324 runtime library is skipped when not available and the build 2325 continues. 2326 2327 '--with-target-bdw-gc=LIST' 2328 '--with-target-bdw-gc-include=LIST' 2329 '--with-target-bdw-gc-lib=LIST' 2330 Specify search directories for the garbage collector header files 2331 and libraries. LIST is a comma separated list of key value pairs 2332 of the form 'MULTILIBDIR=PATH', where the default multilib key is 2333 named as '.' (dot), or is omitted (e.g. 2334 '--with-target-bdw-gc=/opt/bdw-gc,32=/opt-bdw-gc32'). 2335 2336 The options '--with-target-bdw-gc-include' and 2337 '--with-target-bdw-gc-lib' must always be specified together for 2338 each multilib variant and they take precedence over 2339 '--with-target-bdw-gc'. If '--with-target-bdw-gc-include' is 2340 missing values for a multilib, then the value for the default 2341 multilib is used (e.g. 2342 '--with-target-bdw-gc-include=/opt/bdw-gc/include' 2343 '--with-target-bdw-gc-lib=/opt/bdw-gc/lib64,32=/opt-bdw-gc/lib32'). 2344 If none of these options are specified, the library is assumed in 2345 default locations. 2346 2347 D-Specific Options 2348 ------------------ 2349 2350 The following options apply to the build of the D runtime library. 2351 2352 '--enable-libphobos-checking' 2353 '--disable-libphobos-checking' 2354 '--enable-libphobos-checking=LIST' 2355 This option controls whether run-time checks and contracts are 2356 compiled into the D runtime library. When the option is not 2357 specified, the library is built with 'release' checking. When the 2358 option is specified without a LIST, the result is the same as 2359 '--enable-libphobos-checking=yes'. Likewise, 2360 '--disable-libphobos-checking' is equivalent to 2361 '--enable-libphobos-checking=no'. 2362 2363 The categories of checks available in LIST are 'yes' (compiles 2364 libphobos with '-fno-release'), 'no' (compiles libphobos with 2365 '-frelease'), 'all' (same as 'yes'), 'none' or 'release' (same as 2366 'no'). 2367 2368 Individual checks available in LIST are 'assert' (compiles 2369 libphobos with an extra option '-fassert'). 2370 2371 '--with-libphobos-druntime-only' 2372 '--with-libphobos-druntime-only=CHOICE' 2373 Specify whether to build only the core D runtime library 2374 (druntime), or both the core and standard library (phobos) into 2375 libphobos. This is useful for targets that have full support in 2376 druntime, but no or incomplete support in phobos. CHOICE can be 2377 one of 'auto', 'yes', and 'no' where 'auto' is the default. 2378 2379 When the option is not specified, the default choice 'auto' means 2380 that it is inferred whether the target has support for the phobos 2381 standard library. When the option is specified without a CHOICE, 2382 the result is the same as '--with-libphobos-druntime-only=yes'. 2383 2384 '--with-target-system-zlib' 2385 Use installed 'zlib' rather than that included with GCC. This 2386 needs to be available for each multilib variant, unless configured 2387 with '--with-target-system-zlib='auto'' in which case the 2388 GCC included 'zlib' is only used when the system installed library 2389 is not available. 2390 2391 2392 File: gccinstall.info, Node: Building, Next: Testing, Prev: Configuration, Up: Installing GCC 2393 2394 5 Building 2395 ********** 2396 2397 Now that GCC is configured, you are ready to build the compiler and 2398 runtime libraries. 2399 2400 Some commands executed when making the compiler may fail (return a 2401 nonzero status) and be ignored by 'make'. These failures, which are 2402 often due to files that were not found, are expected, and can safely be 2403 ignored. 2404 2405 It is normal to have compiler warnings when compiling certain files. 2406 Unless you are a GCC developer, you can generally ignore these warnings 2407 unless they cause compilation to fail. Developers should attempt to fix 2408 any warnings encountered, however they can temporarily continue past 2409 warnings-as-errors by specifying the configure flag '--disable-werror'. 2410 2411 On certain old systems, defining certain environment variables such 2412 as 'CC' can interfere with the functioning of 'make'. 2413 2414 If you encounter seemingly strange errors when trying to build the 2415 compiler in a directory other than the source directory, it could be 2416 because you have previously configured the compiler in the source 2417 directory. Make sure you have done all the necessary preparations. 2418 2419 If you build GCC on a BSD system using a directory stored in an old 2420 System V file system, problems may occur in running 'fixincludes' if the 2421 System V file system doesn't support symbolic links. These problems 2422 result in a failure to fix the declaration of 'size_t' in 'sys/types.h'. 2423 If you find that 'size_t' is a signed type and that type mismatches 2424 occur, this could be the cause. 2425 2426 The solution is not to use such a directory for building GCC. 2427 2428 Similarly, when building from the source repository or snapshots, or 2429 if you modify '*.l' files, you need the Flex lexical analyzer generator 2430 installed. If you do not modify '*.l' files, releases contain the 2431 Flex-generated files and you do not need Flex installed to build them. 2432 There is still one Flex-based lexical analyzer (part of the build 2433 machinery, not of GCC itself) that is used even if you only build the C 2434 front end. 2435 2436 When building from the source repository or snapshots, or if you 2437 modify Texinfo documentation, you need version 4.7 or later of Texinfo 2438 installed if you want Info documentation to be regenerated. Releases 2439 contain Info documentation pre-built for the unmodified documentation in 2440 the release. 2441 2442 5.1 Building a native compiler 2443 ============================== 2444 2445 For a native build, the default configuration is to perform a 3-stage 2446 bootstrap of the compiler when 'make' is invoked. This will build the 2447 entire GCC system and ensure that it compiles itself correctly. It can 2448 be disabled with the '--disable-bootstrap' parameter to 'configure', but 2449 bootstrapping is suggested because the compiler will be tested more 2450 completely and could also have better performance. 2451 2452 The bootstrapping process will complete the following steps: 2453 2454 * Build tools necessary to build the compiler. 2455 2456 * Perform a 3-stage bootstrap of the compiler. This includes 2457 building three times the target tools for use by the compiler such 2458 as binutils (bfd, binutils, gas, gprof, ld, and opcodes) if they 2459 have been individually linked or moved into the top level GCC 2460 source tree before configuring. 2461 2462 * Perform a comparison test of the stage2 and stage3 compilers. 2463 2464 * Build runtime libraries using the stage3 compiler from the previous 2465 step. 2466 2467 If you are short on disk space you might consider 'make 2468 bootstrap-lean' instead. The sequence of compilation is the same 2469 described above, but object files from the stage1 and stage2 of the 2470 3-stage bootstrap of the compiler are deleted as soon as they are no 2471 longer needed. 2472 2473 If you wish to use non-default GCC flags when compiling the stage2 2474 and stage3 compilers, set 'BOOT_CFLAGS' on the command line when doing 2475 'make'. For example, if you want to save additional space during the 2476 bootstrap and in the final installation as well, you can build the 2477 compiler binaries without debugging information as in the following 2478 example. This will save roughly 40% of disk space both for the 2479 bootstrap and the final installation. (Libraries will still contain 2480 debugging information.) 2481 2482 make BOOT_CFLAGS='-O' bootstrap 2483 2484 You can place non-default optimization flags into 'BOOT_CFLAGS'; they 2485 are less well tested here than the default of '-g -O2', but should still 2486 work. In a few cases, you may find that you need to specify special 2487 flags such as '-msoft-float' here to complete the bootstrap; or, if the 2488 native compiler miscompiles the stage1 compiler, you may need to work 2489 around this, by choosing 'BOOT_CFLAGS' to avoid the parts of the stage1 2490 compiler that were miscompiled, or by using 'make bootstrap4' to 2491 increase the number of stages of bootstrap. 2492 2493 'BOOT_CFLAGS' does not apply to bootstrapped target libraries. Since 2494 these are always compiled with the compiler currently being 2495 bootstrapped, you can use 'CFLAGS_FOR_TARGET' to modify their 2496 compilation flags, as for non-bootstrapped target libraries. Again, if 2497 the native compiler miscompiles the stage1 compiler, you may need to 2498 work around this by avoiding non-working parts of the stage1 compiler. 2499 Use 'STAGE1_TFLAGS' to this end. 2500 2501 If you used the flag '--enable-languages=...' to restrict the 2502 compilers to be built, only those you've actually enabled will be built. 2503 This will of course only build those runtime libraries, for which the 2504 particular compiler has been built. Please note, that re-defining 2505 'LANGUAGES' when calling 'make' *does not* work anymore! 2506 2507 If the comparison of stage2 and stage3 fails, this normally indicates 2508 that the stage2 compiler has compiled GCC incorrectly, and is therefore 2509 a potentially serious bug which you should investigate and report. (On 2510 a few systems, meaningful comparison of object files is impossible; they 2511 always appear "different". If you encounter this problem, you will need 2512 to disable comparison in the 'Makefile'.) 2513 2514 If you do not want to bootstrap your compiler, you can configure with 2515 '--disable-bootstrap'. In particular cases, you may want to bootstrap 2516 your compiler even if the target system is not the same as the one you 2517 are building on: for example, you could build a 2518 'powerpc-unknown-linux-gnu' toolchain on a 'powerpc64-unknown-linux-gnu' 2519 host. In this case, pass '--enable-bootstrap' to the configure script. 2520 2521 'BUILD_CONFIG' can be used to bring in additional customization to 2522 the build. It can be set to a whitespace-separated list of names. For 2523 each such 'NAME', top-level 'config/NAME.mk' will be included by the 2524 top-level 'Makefile', bringing in any settings it contains. The default 2525 'BUILD_CONFIG' can be set using the configure option 2526 '--with-build-config=NAME...'. Some examples of supported build 2527 configurations are: 2528 2529 'bootstrap-O1' 2530 Removes any '-O'-started option from 'BOOT_CFLAGS', and adds '-O1' 2531 to it. 'BUILD_CONFIG=bootstrap-O1' is equivalent to 2532 'BOOT_CFLAGS='-g -O1''. 2533 2534 'bootstrap-O3' 2535 'bootstrap-Og' 2536 Analogous to 'bootstrap-O1'. 2537 2538 'bootstrap-lto' 2539 Enables Link-Time Optimization for host tools during bootstrapping. 2540 'BUILD_CONFIG=bootstrap-lto' is equivalent to adding '-flto' to 2541 'BOOT_CFLAGS'. This option assumes that the host supports the 2542 linker plugin (e.g. GNU ld version 2.21 or later or GNU gold 2543 version 2.21 or later). 2544 2545 'bootstrap-lto-noplugin' 2546 This option is similar to 'bootstrap-lto', but is intended for 2547 hosts that do not support the linker plugin. Without the linker 2548 plugin static libraries are not compiled with link-time 2549 optimizations. Since the GCC middle end and back end are in 2550 'libbackend.a' this means that only the front end is actually LTO 2551 optimized. 2552 2553 'bootstrap-lto-lean' 2554 This option is similar to 'bootstrap-lto', but is intended for 2555 faster build by only using LTO in the final bootstrap stage. With 2556 'make profiledbootstrap' the LTO frontend is trained only on 2557 generator files. 2558 2559 'bootstrap-debug' 2560 Verifies that the compiler generates the same executable code, 2561 whether or not it is asked to emit debug information. To this end, 2562 this option builds stage2 host programs without debug information, 2563 and uses 'contrib/compare-debug' to compare them with the stripped 2564 stage3 object files. If 'BOOT_CFLAGS' is overridden so as to not 2565 enable debug information, stage2 will have it, and stage3 won't. 2566 This option is enabled by default when GCC bootstrapping is 2567 enabled, if 'strip' can turn object files compiled with and without 2568 debug info into identical object files. In addition to better test 2569 coverage, this option makes default bootstraps faster and leaner. 2570 2571 'bootstrap-debug-big' 2572 Rather than comparing stripped object files, as in 2573 'bootstrap-debug', this option saves internal compiler dumps during 2574 stage2 and stage3 and compares them as well, which helps catch 2575 additional potential problems, but at a great cost in terms of disk 2576 space. It can be specified in addition to 'bootstrap-debug'. 2577 2578 'bootstrap-debug-lean' 2579 This option saves disk space compared with 'bootstrap-debug-big', 2580 but at the expense of some recompilation. Instead of saving the 2581 dumps of stage2 and stage3 until the final compare, it uses 2582 '-fcompare-debug' to generate, compare and remove the dumps during 2583 stage3, repeating the compilation that already took place in 2584 stage2, whose dumps were not saved. 2585 2586 'bootstrap-debug-lib' 2587 This option tests executable code invariance over debug information 2588 generation on target libraries, just like 'bootstrap-debug-lean' 2589 tests it on host programs. It builds stage3 libraries with 2590 '-fcompare-debug', and it can be used along with any of the 2591 'bootstrap-debug' options above. 2592 2593 There aren't '-lean' or '-big' counterparts to this option because 2594 most libraries are only build in stage3, so bootstrap compares 2595 would not get significant coverage. Moreover, the few libraries 2596 built in stage2 are used in stage3 host programs, so we wouldn't 2597 want to compile stage2 libraries with different options for 2598 comparison purposes. 2599 2600 'bootstrap-debug-ckovw' 2601 Arranges for error messages to be issued if the compiler built on 2602 any stage is run without the option '-fcompare-debug'. This is 2603 useful to verify the full '-fcompare-debug' testing coverage. It 2604 must be used along with 'bootstrap-debug-lean' and 2605 'bootstrap-debug-lib'. 2606 2607 'bootstrap-cet' 2608 This option enables Intel CET for host tools during bootstrapping. 2609 'BUILD_CONFIG=bootstrap-cet' is equivalent to adding 2610 '-fcf-protection' to 'BOOT_CFLAGS'. This option assumes that the 2611 host supports Intel CET (e.g. GNU assembler version 2.30 or later). 2612 2613 'bootstrap-time' 2614 Arranges for the run time of each program started by the GCC 2615 driver, built in any stage, to be logged to 'time.log', in the top 2616 level of the build tree. 2617 2618 'bootstrap-asan' 2619 Compiles GCC itself using Address Sanitization in order to catch 2620 invalid memory accesses within the GCC code. 2621 2622 'bootstrap-hwasan' 2623 Compiles GCC itself using HWAddress Sanitization in order to catch 2624 invalid memory accesses within the GCC code. This option is only 2625 available on AArch64 systems that are running Linux kernel version 2626 5.4 or later. 2627 2628 5.2 Building a cross compiler 2629 ============================= 2630 2631 When building a cross compiler, it is not generally possible to do a 2632 3-stage bootstrap of the compiler. This makes for an interesting 2633 problem as parts of GCC can only be built with GCC. 2634 2635 To build a cross compiler, we recommend first building and installing 2636 a native compiler. You can then use the native GCC compiler to build 2637 the cross compiler. The installed native compiler needs to be GCC 2638 version 2.95 or later. 2639 2640 Assuming you have already installed a native copy of GCC and 2641 configured your cross compiler, issue the command 'make', which performs 2642 the following steps: 2643 2644 * Build host tools necessary to build the compiler. 2645 2646 * Build target tools for use by the compiler such as binutils (bfd, 2647 binutils, gas, gprof, ld, and opcodes) if they have been 2648 individually linked or moved into the top level GCC source tree 2649 before configuring. 2650 2651 * Build the compiler (single stage only). 2652 2653 * Build runtime libraries using the compiler from the previous step. 2654 2655 Note that if an error occurs in any step the make process will exit. 2656 2657 If you are not building GNU binutils in the same source tree as GCC, 2658 you will need a cross-assembler and cross-linker installed before 2659 configuring GCC. Put them in the directory 'PREFIX/TARGET/bin'. Here 2660 is a table of the tools you should put in this directory: 2661 2662 'as' 2663 This should be the cross-assembler. 2664 2665 'ld' 2666 This should be the cross-linker. 2667 2668 'ar' 2669 This should be the cross-archiver: a program which can manipulate 2670 archive files (linker libraries) in the target machine's format. 2671 2672 'ranlib' 2673 This should be a program to construct a symbol table in an archive 2674 file. 2675 2676 The installation of GCC will find these programs in that directory, 2677 and copy or link them to the proper place to for the cross-compiler to 2678 find them when run later. 2679 2680 The easiest way to provide these files is to build the Binutils 2681 package. Configure it with the same '--host' and '--target' options 2682 that you use for configuring GCC, then build and install them. They 2683 install their executables automatically into the proper directory. 2684 Alas, they do not support all the targets that GCC supports. 2685 2686 If you are not building a C library in the same source tree as GCC, 2687 you should also provide the target libraries and headers before 2688 configuring GCC, specifying the directories with '--with-sysroot' or 2689 '--with-headers' and '--with-libs'. Many targets also require "start 2690 files" such as 'crt0.o' and 'crtn.o' which are linked into each 2691 executable. There may be several alternatives for 'crt0.o', for use 2692 with profiling or other compilation options. Check your target's 2693 definition of 'STARTFILE_SPEC' to find out what start files it uses. 2694 2695 5.3 Building in parallel 2696 ======================== 2697 2698 GNU Make 3.80 and above, which is necessary to build GCC, support 2699 building in parallel. To activate this, you can use 'make -j 2' instead 2700 of 'make'. You can also specify a bigger number, and in most cases 2701 using a value greater than the number of processors in your machine will 2702 result in fewer and shorter I/O latency hits, thus improving overall 2703 throughput; this is especially true for slow drives and network 2704 filesystems. 2705 2706 5.4 Building the Ada compiler 2707 ============================= 2708 2709 *note GNAT-prerequisite::. 2710 2711 5.5 Building the D compiler 2712 =========================== 2713 2714 *note GDC-prerequisite::. 2715 2716 5.6 Building with profile feedback 2717 ================================== 2718 2719 It is possible to use profile feedback to optimize the compiler itself. 2720 This should result in a faster compiler binary. Experiments done on x86 2721 using gcc 3.3 showed approximately 7 percent speedup on compiling C 2722 programs. To bootstrap the compiler with profile feedback, use 'make 2723 profiledbootstrap'. 2724 2725 When 'make profiledbootstrap' is run, it will first build a 'stage1' 2726 compiler. This compiler is used to build a 'stageprofile' compiler 2727 instrumented to collect execution counts of instruction and branch 2728 probabilities. Training run is done by building 'stagetrain' compiler. 2729 Finally a 'stagefeedback' compiler is built using the information 2730 collected. 2731 2732 Unlike standard bootstrap, several additional restrictions apply. 2733 The compiler used to build 'stage1' needs to support a 64-bit integral 2734 type. It is recommended to only use GCC for this. 2735 2736 On Linux/x86_64 hosts with some restrictions (no virtualization) it 2737 is also possible to do autofdo build with 'make autoprofiledback'. This 2738 uses Linux perf to sample branches in the binary and then rebuild it 2739 with feedback derived from the profile. Linux perf and the 'autofdo' 2740 toolkit needs to be installed for this. 2741 2742 Only the profile from the current build is used, so when an error 2743 occurs it is recommended to clean before restarting. Otherwise the code 2744 quality may be much worse. 2745 2746 2747 File: gccinstall.info, Node: Testing, Next: Final install, Prev: Building, Up: Installing GCC 2748 2749 6 Installing GCC: Testing 2750 ************************* 2751 2752 Before you install GCC, we encourage you to run the testsuites and to 2753 compare your results with results from a similar configuration that have 2754 been submitted to the gcc-testresults mailing list. Some of these 2755 archived results are linked from the build status lists at 2756 <https://gcc.gnu.org/buildstat.html>, although not everyone who reports 2757 a successful build runs the testsuites and submits the results. This 2758 step is optional and may require you to download additional software, 2759 but it can give you confidence in your new GCC installation or point out 2760 problems before you install and start using your new GCC. 2761 2762 First, you must have downloaded the testsuites. These are part of 2763 the full distribution, but if you downloaded the "core" compiler plus 2764 any front ends, you must download the testsuites separately. 2765 2766 Second, you must have the testing tools installed. This includes 2767 DejaGnu, Tcl, and Expect; the DejaGnu site has links to these. Some 2768 optional tests also require Python3 and pytest module. 2769 2770 If the directories where 'runtest' and 'expect' were installed are 2771 not in the 'PATH', you may need to set the following environment 2772 variables appropriately, as in the following example (which assumes that 2773 DejaGnu has been installed under '/usr/local'): 2774 2775 TCL_LIBRARY = /usr/local/share/tcl8.0 2776 DEJAGNULIBS = /usr/local/share/dejagnu 2777 2778 (On systems such as Cygwin, these paths are required to be actual 2779 paths, not mounts or links; presumably this is due to some lack of 2780 portability in the DejaGnu code.) 2781 2782 Finally, you can run the testsuite (which may take a long time): 2783 cd OBJDIR; make -k check 2784 2785 This will test various components of GCC, such as compiler front ends 2786 and runtime libraries. While running the testsuite, DejaGnu might emit 2787 some harmless messages resembling 'WARNING: Couldn't find the global 2788 config file.' or 'WARNING: Couldn't find tool init file' that can be 2789 ignored. 2790 2791 If you are testing a cross-compiler, you may want to run the 2792 testsuite on a simulator as described at 2793 <https://gcc.gnu.org/simtest-howto.html>. 2794 2795 6.1 How can you run the testsuite on selected tests? 2796 ==================================================== 2797 2798 In order to run sets of tests selectively, there are targets 'make 2799 check-gcc' and language specific 'make check-c', 'make check-c++', 'make 2800 check-d' 'make check-fortran', 'make check-ada', 'make check-objc', 2801 'make check-obj-c++', 'make check-lto' in the 'gcc' subdirectory of the 2802 object directory. You can also just run 'make check' in a subdirectory 2803 of the object directory. 2804 2805 A more selective way to just run all 'gcc' execute tests in the 2806 testsuite is to use 2807 2808 make check-gcc RUNTESTFLAGS="execute.exp OTHER-OPTIONS" 2809 2810 Likewise, in order to run only the 'g++' "old-deja" tests in the 2811 testsuite with filenames matching '9805*', you would use 2812 2813 make check-g++ RUNTESTFLAGS="old-deja.exp=9805* OTHER-OPTIONS" 2814 2815 The file-matching expression following FILENAME'.exp=' is treated as 2816 a series of whitespace-delimited glob expressions so that multiple 2817 patterns may be passed, although any whitespace must either be escaped 2818 or surrounded by single quotes if multiple expressions are desired. For 2819 example, 2820 2821 make check-g++ RUNTESTFLAGS="old-deja.exp=9805*\ virtual2.c OTHER-OPTIONS" 2822 make check-g++ RUNTESTFLAGS="'old-deja.exp=9805* virtual2.c' OTHER-OPTIONS" 2823 2824 The '*.exp' files are located in the testsuite directories of the GCC 2825 source, the most important ones being 'compile.exp', 'execute.exp', 2826 'dg.exp' and 'old-deja.exp'. To get a list of the possible '*.exp' 2827 files, pipe the output of 'make check' into a file and look at the 2828 'Running ... .exp' lines. 2829 2830 6.2 Passing options and running multiple testsuites 2831 =================================================== 2832 2833 You can pass multiple options to the testsuite using the 2834 '--target_board' option of DejaGNU, either passed as part of 2835 'RUNTESTFLAGS', or directly to 'runtest' if you prefer to work outside 2836 the makefiles. For example, 2837 2838 make check-g++ RUNTESTFLAGS="--target_board=unix/-O3/-fmerge-constants" 2839 2840 will run the standard 'g++' testsuites ("unix" is the target name for 2841 a standard native testsuite situation), passing '-O3 -fmerge-constants' 2842 to the compiler on every test, i.e., slashes separate options. 2843 2844 You can run the testsuites multiple times using combinations of 2845 options with a syntax similar to the brace expansion of popular shells: 2846 2847 ..."--target_board=arm-sim\{-mhard-float,-msoft-float\}\{-O1,-O2,-O3,\}" 2848 2849 (Note the empty option caused by the trailing comma in the final 2850 group.) The following will run each testsuite eight times using the 2851 'arm-sim' target, as if you had specified all possible combinations 2852 yourself: 2853 2854 --target_board='arm-sim/-mhard-float/-O1 \ 2855 arm-sim/-mhard-float/-O2 \ 2856 arm-sim/-mhard-float/-O3 \ 2857 arm-sim/-mhard-float \ 2858 arm-sim/-msoft-float/-O1 \ 2859 arm-sim/-msoft-float/-O2 \ 2860 arm-sim/-msoft-float/-O3 \ 2861 arm-sim/-msoft-float' 2862 2863 They can be combined as many times as you wish, in arbitrary ways. 2864 This list: 2865 2866 ..."--target_board=unix/-Wextra\{-O3,-fno-strength\}\{-fomit-frame,\}" 2867 2868 will generate four combinations, all involving '-Wextra'. 2869 2870 The disadvantage to this method is that the testsuites are run in 2871 serial, which is a waste on multiprocessor systems. For users with GNU 2872 Make and a shell which performs brace expansion, you can run the 2873 testsuites in parallel by having the shell perform the combinations and 2874 'make' do the parallel runs. Instead of using '--target_board', use a 2875 special makefile target: 2876 2877 make -jN check-TESTSUITE//TEST-TARGET/OPTION1/OPTION2/... 2878 2879 For example, 2880 2881 make -j3 check-gcc//sh-hms-sim/{-m1,-m2,-m3,-m3e,-m4}/{,-nofpu} 2882 2883 will run three concurrent "make-gcc" testsuites, eventually testing 2884 all ten combinations as described above. Note that this is currently 2885 only supported in the 'gcc' subdirectory. (To see how this works, try 2886 typing 'echo' before the example given here.) 2887 2888 6.3 How to interpret test results 2889 ================================= 2890 2891 The result of running the testsuite are various '*.sum' and '*.log' 2892 files in the testsuite subdirectories. The '*.log' files contain a 2893 detailed log of the compiler invocations and the corresponding results, 2894 the '*.sum' files summarize the results. These summaries contain status 2895 codes for all tests: 2896 2897 * PASS: the test passed as expected 2898 * XPASS: the test unexpectedly passed 2899 * FAIL: the test unexpectedly failed 2900 * XFAIL: the test failed as expected 2901 * UNSUPPORTED: the test is not supported on this platform 2902 * ERROR: the testsuite detected an error 2903 * WARNING: the testsuite detected a possible problem 2904 2905 It is normal for some tests to report unexpected failures. At the 2906 current time the testing harness does not allow fine grained control 2907 over whether or not a test is expected to fail. This problem should be 2908 fixed in future releases. 2909 2910 6.4 Submitting test results 2911 =========================== 2912 2913 If you want to report the results to the GCC project, use the 2914 'contrib/test_summary' shell script. Start it in the OBJDIR with 2915 2916 SRCDIR/contrib/test_summary -p your_commentary.txt \ 2917 -m gcc-testresults (a] gcc.gnu.org |sh 2918 2919 This script uses the 'Mail' program to send the results, so make sure 2920 it is in your 'PATH'. The file 'your_commentary.txt' is prepended to 2921 the testsuite summary and should contain any special remarks you have on 2922 your results or your build environment. Please do not edit the 2923 testsuite result block or the subject line, as these messages may be 2924 automatically processed. 2925 2926 2927 File: gccinstall.info, Node: Final install, Prev: Testing, Up: Installing GCC 2928 2929 7 Installing GCC: Final installation 2930 ************************************ 2931 2932 Now that GCC has been built (and optionally tested), you can install it 2933 with 2934 cd OBJDIR && make install 2935 2936 We strongly recommend to install into a target directory where there 2937 is no previous version of GCC present. Also, the GNAT runtime should 2938 not be stripped, as this would break certain features of the debugger 2939 that depend on this debugging information (catching Ada exceptions for 2940 instance). 2941 2942 That step completes the installation of GCC; user level binaries can 2943 be found in 'PREFIX/bin' where PREFIX is the value you specified with 2944 the '--prefix' to configure (or '/usr/local' by default). (If you 2945 specified '--bindir', that directory will be used instead; otherwise, if 2946 you specified '--exec-prefix', 'EXEC-PREFIX/bin' will be used.) Headers 2947 for the C++ library are installed in 'PREFIX/include'; libraries in 2948 'LIBDIR' (normally 'PREFIX/lib'); internal parts of the compiler in 2949 'LIBDIR/gcc' and 'LIBEXECDIR/gcc'; documentation in info format in 2950 'INFODIR' (normally 'PREFIX/info'). 2951 2952 When installing cross-compilers, GCC's executables are not only 2953 installed into 'BINDIR', that is, 'EXEC-PREFIX/bin', but additionally 2954 into 'EXEC-PREFIX/TARGET-ALIAS/bin', if that directory exists. 2955 Typically, such "tooldirs" hold target-specific binutils, including 2956 assembler and linker. 2957 2958 Installation into a temporary staging area or into a 'chroot' jail 2959 can be achieved with the command 2960 2961 make DESTDIR=PATH-TO-ROOTDIR install 2962 2963 where PATH-TO-ROOTDIR is the absolute path of a directory relative to 2964 which all installation paths will be interpreted. Note that the 2965 directory specified by 'DESTDIR' need not exist yet; it will be created 2966 if necessary. 2967 2968 There is a subtle point with tooldirs and 'DESTDIR': If you relocate 2969 a cross-compiler installation with e.g. 'DESTDIR=ROOTDIR', then the 2970 directory 'ROOTDIR/EXEC-PREFIX/TARGET-ALIAS/bin' will be filled with 2971 duplicated GCC executables only if it already exists, it will not be 2972 created otherwise. This is regarded as a feature, not as a bug, because 2973 it gives slightly more control to the packagers using the 'DESTDIR' 2974 feature. 2975 2976 You can install stripped programs and libraries with 2977 2978 make install-strip 2979 2980 If you are bootstrapping a released version of GCC then please 2981 quickly review the build status page for your release, available from 2982 <https://gcc.gnu.org/buildstat.html>. If your system is not listed for 2983 the version of GCC that you built, send a note to <gcc (a] gcc.gnu.org> 2984 indicating that you successfully built and installed GCC. Include the 2985 following information: 2986 2987 * Output from running 'SRCDIR/config.guess'. Do not send that file 2988 itself, just the one-line output from running it. 2989 2990 * The output of 'gcc -v' for your newly installed 'gcc'. This tells 2991 us which version of GCC you built and the options you passed to 2992 configure. 2993 2994 * Whether you enabled all languages or a subset of them. If you used 2995 a full distribution then this information is part of the configure 2996 options in the output of 'gcc -v', but if you downloaded the "core" 2997 compiler plus additional front ends then it isn't apparent which 2998 ones you built unless you tell us about it. 2999 3000 * If the build was for GNU/Linux, also include: 3001 * The distribution name and version (e.g., Red Hat 7.1 or Debian 3002 2.2.3); this information should be available from 3003 '/etc/issue'. 3004 3005 * The version of the Linux kernel, available from 'uname 3006 --version' or 'uname -a'. 3007 3008 * The version of glibc you used; for RPM-based systems like Red 3009 Hat, Mandrake, and SuSE type 'rpm -q glibc' to get the glibc 3010 version, and on systems like Debian and Progeny use 'dpkg -l 3011 libc6'. 3012 For other systems, you can include similar information if you think 3013 it is relevant. 3014 3015 * Any other information that you think would be useful to people 3016 building GCC on the same configuration. The new entry in the build 3017 status list will include a link to the archived copy of your 3018 message. 3019 3020 We'd also like to know if the *note host/target specific installation 3021 notes: Specific. didn't include your host/target information or if that 3022 information is incomplete or out of date. Send a note to 3023 <gcc (a] gcc.gnu.org> detailing how the information should be changed. 3024 3025 If you find a bug, please report it following the bug reporting 3026 guidelines. 3027 3028 If you want to print the GCC manuals, do 'cd OBJDIR; make dvi'. You 3029 will need to have 'texi2dvi' (version at least 4.7) and TeX installed. 3030 This creates a number of '.dvi' files in subdirectories of 'OBJDIR'; 3031 these may be converted for printing with programs such as 'dvips'. 3032 Alternately, by using 'make pdf' in place of 'make dvi', you can create 3033 documentation in the form of '.pdf' files; this requires 'texi2pdf', 3034 which is included with Texinfo version 4.8 and later. You can also buy 3035 printed manuals from the Free Software Foundation, though such manuals 3036 may not be for the most recent version of GCC. 3037 3038 If you would like to generate online HTML documentation, do 'cd 3039 OBJDIR; make html' and HTML will be generated for the gcc manuals in 3040 'OBJDIR/gcc/HTML'. 3041 3042 3043 File: gccinstall.info, Node: Binaries, Next: Specific, Prev: Installing GCC, Up: Top 3044 3045 8 Installing GCC: Binaries 3046 ************************** 3047 3048 We are often asked about pre-compiled versions of GCC. While we cannot 3049 provide these for all platforms, below you'll find links to binaries for 3050 various platforms where creating them by yourself is not easy due to 3051 various reasons. 3052 3053 Please note that we did not create these binaries, nor do we support 3054 them. If you have any problems installing them, please contact their 3055 makers. 3056 3057 * AIX: 3058 * Bull's Open Source Software Archive for for AIX 6 and AIX 7; 3059 3060 * AIX Open Source Packages (AIX5L AIX 6.1 AIX 7.1). 3061 3062 * DOS--DJGPP. 3063 3064 * HP-UX: 3065 * HP-UX Porting Center; 3066 3067 * Solaris 2 (SPARC, Intel): 3068 * OpenCSW 3069 3070 * macOS: 3071 * The Homebrew package manager; 3072 * MacPorts. 3073 3074 * Microsoft Windows: 3075 * The Cygwin project; 3076 * The MinGW and mingw-w64 projects. 3077 3078 * OpenPKG offers binaries for quite a number of platforms. 3079 3080 * The GFortran Wiki has links to GNU Fortran binaries for several 3081 platforms. 3082 3083 3084 File: gccinstall.info, Node: Specific, Next: GNU Free Documentation License, Prev: Binaries, Up: Top 3085 3086 9 Host/target specific installation notes for GCC 3087 ************************************************* 3088 3089 Please read this document carefully _before_ installing the GNU Compiler 3090 Collection on your machine. 3091 3092 Note that this list of install notes is _not_ a list of supported 3093 hosts or targets. Not all supported hosts and targets are listed here, 3094 only the ones that require host-specific or target-specific information 3095 have to. 3096 3097 aarch64*-*-* 3098 ============ 3099 3100 Binutils pre 2.24 does not have support for selecting '-mabi' and does 3101 not support ILP32. If it is used to build GCC 4.9 or later, GCC will 3102 not support option '-mabi=ilp32'. 3103 3104 To enable a workaround for the Cortex-A53 erratum number 835769 by 3105 default (for all CPUs regardless of -mcpu option given) at configure 3106 time use the '--enable-fix-cortex-a53-835769' option. This will enable 3107 the fix by default and can be explicitly disabled during compilation by 3108 passing the '-mno-fix-cortex-a53-835769' option. Conversely, 3109 '--disable-fix-cortex-a53-835769' will disable the workaround by 3110 default. The workaround is disabled by default if neither of 3111 '--enable-fix-cortex-a53-835769' or '--disable-fix-cortex-a53-835769' is 3112 given at configure time. 3113 3114 To enable a workaround for the Cortex-A53 erratum number 843419 by 3115 default (for all CPUs regardless of -mcpu option given) at configure 3116 time use the '--enable-fix-cortex-a53-843419' option. This workaround 3117 is applied at link time. Enabling the workaround will cause GCC to pass 3118 the relevant option to the linker. It can be explicitly disabled during 3119 compilation by passing the '-mno-fix-cortex-a53-843419' option. 3120 Conversely, '--disable-fix-cortex-a53-843419' will disable the 3121 workaround by default. The workaround is disabled by default if neither 3122 of '--enable-fix-cortex-a53-843419' or '--disable-fix-cortex-a53-843419' 3123 is given at configure time. 3124 3125 To enable Branch Target Identification Mechanism and Return Address 3126 Signing by default at configure time use the 3127 '--enable-standard-branch-protection' option. This is equivalent to 3128 having '-mbranch-protection=standard' during compilation. This can be 3129 explicitly disabled during compilation by passing the 3130 '-mbranch-protection=none' option which turns off all types of branch 3131 protections. Conversely, '--disable-standard-branch-protection' will 3132 disable both the protections by default. This mechanism is turned off 3133 by default if neither of the options are given at configure time. 3134 3135 alpha*-*-* 3136 ========== 3137 3138 This section contains general configuration information for all 3139 Alpha-based platforms using ELF. In addition to reading this section, 3140 please read all other sections that match your target. 3141 3142 amd64-*-solaris2* 3143 ================= 3144 3145 This is a synonym for 'x86_64-*-solaris2*'. 3146 3147 amdgcn-*-amdhsa 3148 =============== 3149 3150 AMD GCN GPU target. 3151 3152 Instead of GNU Binutils, you will need to install LLVM 13.0.1, or 3153 later, and copy 'bin/llvm-mc' to 'amdgcn-amdhsa/bin/as', 'bin/lld' to 3154 'amdgcn-amdhsa/bin/ld', 'bin/llvm-nm' to 'amdgcn-amdhsa/bin/nm', and 3155 'bin/llvm-ar' to both 'bin/amdgcn-amdhsa-ar' and 3156 'bin/amdgcn-amdhsa-ranlib'. 3157 3158 Use Newlib (3.2.0, or newer). 3159 3160 To run the binaries, install the HSA Runtime from the ROCm Platform, 3161 and use 'libexec/gcc/amdhsa-amdhsa/VERSION/gcn-run' to launch them on 3162 the GPU. 3163 3164 arc-*-elf32 3165 =========== 3166 3167 Use 'configure --target=arc-elf32 --with-cpu=CPU 3168 --enable-languages="c,c++"' to configure GCC, with CPU being one of 3169 'arc600', 'arc601', or 'arc700'. 3170 3171 arc-linux-uclibc 3172 ================ 3173 3174 Use 'configure --target=arc-linux-uclibc --with-cpu=arc700 3175 --enable-languages="c,c++"' to configure GCC. 3176 3177 arm-*-eabi 3178 ========== 3179 3180 ARM-family processors. 3181 3182 Building the Ada frontend commonly fails (an infinite loop executing 3183 'xsinfo') if the host compiler is GNAT 4.8. Host compilers built from 3184 the GNAT 4.6, 4.9 or 5 release branches are known to succeed. 3185 3186 avr 3187 === 3188 3189 ATMEL AVR-family micro controllers. These are used in embedded 3190 applications. There are no standard Unix configurations. *Note AVR 3191 Options: (gcc)AVR Options, for the list of supported MCU types. 3192 3193 Use 'configure --target=avr --enable-languages="c"' to configure GCC. 3194 3195 Further installation notes and other useful information about AVR 3196 tools can also be obtained from: 3197 3198 * http://www.nongnu.org/avr/ 3199 * http://www.amelek.gda.pl/avr/ 3200 3201 The following error: 3202 Error: register required 3203 3204 indicates that you should upgrade to a newer version of the binutils. 3205 3206 Blackfin 3207 ======== 3208 3209 The Blackfin processor, an Analog Devices DSP. *Note Blackfin Options: 3210 (gcc)Blackfin Options, 3211 3212 More information, and a version of binutils with support for this 3213 processor, are available at 3214 <https://sourceforge.net/projects/adi-toolchain/>. 3215 3216 CR16 3217 ==== 3218 3219 The CR16 CompactRISC architecture is a 16-bit architecture. This 3220 architecture is used in embedded applications. 3221 3222 *Note CR16 Options: (gcc)CR16 Options, 3223 3224 Use 'configure --target=cr16-elf --enable-languages=c,c++' to 3225 configure GCC for building a CR16 elf cross-compiler. 3226 3227 Use 'configure --target=cr16-uclinux --enable-languages=c,c++' to 3228 configure GCC for building a CR16 uclinux cross-compiler. 3229 3230 CRIS 3231 ==== 3232 3233 CRIS is a CPU architecture in Axis Communications systems-on-a-chip, for 3234 example the ETRAX series. These are used in embedded applications. 3235 3236 *Note CRIS Options: (gcc)CRIS Options, for a list of CRIS-specific 3237 options. 3238 3239 Use 'configure --target=cris-elf' to configure GCC for building a 3240 cross-compiler for CRIS. 3241 3242 DOS 3243 === 3244 3245 Please have a look at the binaries page. 3246 3247 You cannot install GCC by itself on MSDOS; it will not compile under 3248 any MSDOS compiler except itself. You need to get the complete 3249 compilation package DJGPP, which includes binaries as well as sources, 3250 and includes all the necessary compilation tools and libraries. 3251 3252 epiphany-*-elf 3253 ============== 3254 3255 Adapteva Epiphany. This configuration is intended for embedded systems. 3256 3257 *-*-freebsd* 3258 ============ 3259 3260 In order to better utilize FreeBSD base system functionality and match 3261 the configuration of the system compiler, GCC 4.5 and above as well as 3262 GCC 4.4 past 2010-06-20 leverage SSP support in libc (which is present 3263 on FreeBSD 7 or later) and the use of '__cxa_atexit' by default (on 3264 FreeBSD 6 or later). The use of 'dl_iterate_phdr' inside 3265 'libgcc_s.so.1' and boehm-gc (on FreeBSD 7 or later) is enabled by GCC 3266 4.5 and above. 3267 3268 We support FreeBSD using the ELF file format with DWARF 2 debugging 3269 for all CPU architectures. You may use '-gstabs' instead of '-g', if 3270 you really want the old debugging format. There are no known issues 3271 with mixing object files and libraries with different debugging formats. 3272 Otherwise, this release of GCC should now match more of the 3273 configuration used in the stock FreeBSD configuration of GCC. In 3274 particular, '--enable-threads' is now configured by default. However, 3275 as a general user, do not attempt to replace the system compiler with 3276 this release. Known to bootstrap and check with good results on FreeBSD 3277 7.2-STABLE. In the past, known to bootstrap and check with good results 3278 on FreeBSD 3.0, 3.4, 4.0, 4.2, 4.3, 4.4, 4.5, 4.8, 4.9 and 5-CURRENT. 3279 3280 The version of binutils installed in '/usr/bin' probably works with 3281 this release of GCC. Bootstrapping against the latest GNU binutils 3282 and/or the version found in '/usr/ports/devel/binutils' has been known 3283 to enable additional features and improve overall testsuite results. 3284 However, it is currently known that boehm-gc may not configure properly 3285 on FreeBSD prior to the FreeBSD 7.0 release with GNU binutils after 3286 2.16.1. 3287 3288 ft32-*-elf 3289 ========== 3290 3291 The FT32 processor. This configuration is intended for embedded 3292 systems. 3293 3294 h8300-hms 3295 ========= 3296 3297 Renesas H8/300 series of processors. 3298 3299 Please have a look at the binaries page. 3300 3301 The calling convention and structure layout has changed in release 3302 2.6. All code must be recompiled. The calling convention now passes 3303 the first three arguments in function calls in registers. Structures 3304 are no longer a multiple of 2 bytes. 3305 3306 hppa*-hp-hpux* 3307 ============== 3308 3309 Support for HP-UX version 9 and older was discontinued in GCC 3.4. 3310 3311 We require using gas/binutils on all hppa platforms. Version 2.19 or 3312 later is recommended. 3313 3314 It may be helpful to configure GCC with the '--with-gnu-as' and 3315 '--with-as=...' options to ensure that GCC can find GAS. 3316 3317 The HP assembler should not be used with GCC. It is rarely tested and 3318 may not work. It shouldn't be used with any languages other than C due 3319 to its many limitations. 3320 3321 Specifically, '-g' does not work (HP-UX uses a peculiar debugging 3322 format which GCC does not know about). It also inserts timestamps into 3323 each object file it creates, causing the 3-stage comparison test to fail 3324 during a bootstrap. You should be able to continue by saying 'make 3325 all-host all-target' after getting the failure from 'make'. 3326 3327 Various GCC features are not supported. For example, it does not 3328 support weak symbols or alias definitions. As a result, explicit 3329 template instantiations are required when using C++. This makes it 3330 difficult if not impossible to build many C++ applications. 3331 3332 There are two default scheduling models for instructions. These are 3333 PROCESSOR_7100LC and PROCESSOR_8000. They are selected from the pa-risc 3334 architecture specified for the target machine when configuring. 3335 PROCESSOR_8000 is the default. PROCESSOR_7100LC is selected when the 3336 target is a 'hppa1*' machine. 3337 3338 The PROCESSOR_8000 model is not well suited to older processors. 3339 Thus, it is important to completely specify the machine architecture 3340 when configuring if you want a model other than PROCESSOR_8000. The 3341 macro TARGET_SCHED_DEFAULT can be defined in BOOT_CFLAGS if a different 3342 default scheduling model is desired. 3343 3344 As of GCC 4.0, GCC uses the UNIX 95 namespace for HP-UX 10.10 through 3345 11.00, and the UNIX 98 namespace for HP-UX 11.11 and later. This 3346 namespace change might cause problems when bootstrapping with an earlier 3347 version of GCC or the HP compiler as essentially the same namespace is 3348 required for an entire build. This problem can be avoided in a number 3349 of ways. With HP cc, 'UNIX_STD' can be set to '95' or '98'. Another 3350 way is to add an appropriate set of predefines to 'CC'. The description 3351 for the 'munix=' option contains a list of the predefines used with each 3352 standard. 3353 3354 More specific information to 'hppa*-hp-hpux*' targets follows. 3355 3356 hppa*-hp-hpux10 3357 =============== 3358 3359 For hpux10.20, we _highly_ recommend you pick up the latest sed patch 3360 'PHCO_19798' from HP. 3361 3362 The C++ ABI has changed incompatibly in GCC 4.0. COMDAT subspaces 3363 are used for one-only code and data. This resolves many of the previous 3364 problems in using C++ on this target. However, the ABI is not 3365 compatible with the one implemented under HP-UX 11 using secondary 3366 definitions. 3367 3368 hppa*-hp-hpux11 3369 =============== 3370 3371 GCC 3.0 and up support HP-UX 11. GCC 2.95.x is not supported and cannot 3372 be used to compile GCC 3.0 and up. 3373 3374 The libffi library haven't been ported to 64-bit HP-UX and doesn't 3375 build. 3376 3377 Refer to binaries for information about obtaining precompiled GCC 3378 binaries for HP-UX. Precompiled binaries must be obtained to build the 3379 Ada language as it cannot be bootstrapped using C. Ada is only 3380 available for the 32-bit PA-RISC runtime. 3381 3382 Starting with GCC 3.4 an ISO C compiler is required to bootstrap. 3383 The bundled compiler supports only traditional C; you will need either 3384 HP's unbundled compiler, or a binary distribution of GCC. 3385 3386 It is possible to build GCC 3.3 starting with the bundled HP 3387 compiler, but the process requires several steps. GCC 3.3 can then be 3388 used to build later versions. 3389 3390 There are several possible approaches to building the distribution. 3391 Binutils can be built first using the HP tools. Then, the GCC 3392 distribution can be built. The second approach is to build GCC first 3393 using the HP tools, then build binutils, then rebuild GCC. There have 3394 been problems with various binary distributions, so it is best not to 3395 start from a binary distribution. 3396 3397 On 64-bit capable systems, there are two distinct targets. Different 3398 installation prefixes must be used if both are to be installed on the 3399 same system. The 'hppa[1-2]*-hp-hpux11*' target generates code for the 3400 32-bit PA-RISC runtime architecture and uses the HP linker. The 3401 'hppa64-hp-hpux11*' target generates 64-bit code for the PA-RISC 2.0 3402 architecture. 3403 3404 The script config.guess now selects the target type based on the 3405 compiler detected during configuration. You must define 'PATH' or 'CC' 3406 so that configure finds an appropriate compiler for the initial 3407 bootstrap. When 'CC' is used, the definition should contain the options 3408 that are needed whenever 'CC' is used. 3409 3410 Specifically, options that determine the runtime architecture must be 3411 in 'CC' to correctly select the target for the build. It is also 3412 convenient to place many other compiler options in 'CC'. For example, 3413 'CC="cc -Ac +DA2.0W -Wp,-H16376 -D_CLASSIC_TYPES -D_HPUX_SOURCE"' can be 3414 used to bootstrap the GCC 3.3 branch with the HP compiler in 64-bit 3415 K&R/bundled mode. The '+DA2.0W' option will result in the automatic 3416 selection of the 'hppa64-hp-hpux11*' target. The macro definition table 3417 of cpp needs to be increased for a successful build with the HP 3418 compiler. _CLASSIC_TYPES and _HPUX_SOURCE need to be defined when 3419 building with the bundled compiler, or when using the '-Ac' option. 3420 These defines aren't necessary with '-Ae'. 3421 3422 It is best to explicitly configure the 'hppa64-hp-hpux11*' target 3423 with the '--with-ld=...' option. This overrides the standard search for 3424 ld. The two linkers supported on this target require different 3425 commands. The default linker is determined during configuration. As a 3426 result, it's not possible to switch linkers in the middle of a GCC 3427 build. This has been reported to sometimes occur in unified builds of 3428 binutils and GCC. 3429 3430 A recent linker patch must be installed for the correct operation of 3431 GCC 3.3 and later. 'PHSS_26559' and 'PHSS_24304' are the oldest linker 3432 patches that are known to work. They are for HP-UX 11.00 and 11.11, 3433 respectively. 'PHSS_24303', the companion to 'PHSS_24304', might be 3434 usable but it hasn't been tested. These patches have been superseded. 3435 Consult the HP patch database to obtain the currently recommended linker 3436 patch for your system. 3437 3438 The patches are necessary for the support of weak symbols on the 3439 32-bit port, and for the running of initializers and finalizers. Weak 3440 symbols are implemented using SOM secondary definition symbols. Prior 3441 to HP-UX 11, there are bugs in the linker support for secondary symbols. 3442 The patches correct a problem of linker core dumps creating shared 3443 libraries containing secondary symbols, as well as various other linking 3444 issues involving secondary symbols. 3445 3446 GCC 3.3 uses the ELF DT_INIT_ARRAY and DT_FINI_ARRAY capabilities to 3447 run initializers and finalizers on the 64-bit port. The 32-bit port 3448 uses the linker '+init' and '+fini' options for the same purpose. The 3449 patches correct various problems with the +init/+fini options, including 3450 program core dumps. Binutils 2.14 corrects a problem on the 64-bit port 3451 resulting from HP's non-standard use of the .init and .fini sections for 3452 array initializers and finalizers. 3453 3454 Although the HP and GNU linkers are both supported for the 3455 'hppa64-hp-hpux11*' target, it is strongly recommended that the HP 3456 linker be used for link editing on this target. 3457 3458 At this time, the GNU linker does not support the creation of long 3459 branch stubs. As a result, it cannot successfully link binaries 3460 containing branch offsets larger than 8 megabytes. In addition, there 3461 are problems linking shared libraries, linking executables with 3462 '-static', and with dwarf2 unwind and exception support. It also 3463 doesn't provide stubs for internal calls to global functions in shared 3464 libraries, so these calls cannot be overloaded. 3465 3466 The HP dynamic loader does not support GNU symbol versioning, so 3467 symbol versioning is not supported. It may be necessary to disable 3468 symbol versioning with '--disable-symvers' when using GNU ld. 3469 3470 POSIX threads are the default. The optional DCE thread library is 3471 not supported, so '--enable-threads=dce' does not work. 3472 3473 *-*-linux-gnu 3474 ============= 3475 3476 The '.init_array' and '.fini_array' sections are enabled unconditionally 3477 which requires at least glibc 2.1 and binutils 2.12. 3478 3479 Versions of libstdc++-v3 starting with 3.2.1 require bug fixes 3480 present in glibc 2.2.5 and later. More information is available in the 3481 libstdc++-v3 documentation. 3482 3483 i?86-*-linux* 3484 ============= 3485 3486 As of GCC 3.3, binutils 2.13.1 or later is required for this platform. 3487 See bug 10877 for more information. 3488 3489 If you receive Signal 11 errors when building on GNU/Linux, then it 3490 is possible you have a hardware problem. Further information on this 3491 can be found on www.bitwizard.nl. 3492 3493 i?86-*-solaris2* 3494 ================ 3495 3496 Use this for Solaris 11.3 or later on x86 and x86-64 systems. Starting 3497 with GCC 4.7, there is also a 64-bit 'amd64-*-solaris2*' or 3498 'x86_64-*-solaris2*' configuration that corresponds to 3499 'sparcv9-sun-solaris2*'. 3500 3501 It is recommended that you configure GCC to use the GNU assembler. 3502 The versions included in Solaris 11.3, from GNU binutils 2.23.1 or newer 3503 (available as '/usr/bin/gas' and '/usr/gnu/bin/as'), work fine. The 3504 current version, from GNU binutils 2.34, is known to work. Recent 3505 versions of the Solaris assembler in '/usr/bin/as' work almost as well, 3506 though. 3507 3508 For linking, the Solaris linker is preferred. If you want to use the 3509 GNU linker instead, the version in Solaris 11.3, from GNU binutils 3510 2.23.1 or newer (in '/usr/gnu/bin/ld' and '/usr/bin/gld'), works, as 3511 does the latest version, from GNU binutils 2.34. 3512 3513 To use GNU 'as', configure with the options '--with-gnu-as 3514 --with-as=/usr/gnu/bin/as'. It may be necessary to configure with 3515 '--without-gnu-ld --with-ld=/usr/ccs/bin/ld' to guarantee use of Solaris 3516 'ld'. 3517 3518 ia64-*-linux 3519 ============ 3520 3521 IA-64 processor (also known as IPF, or Itanium Processor Family) running 3522 GNU/Linux. 3523 3524 If you are using the installed system libunwind library with 3525 '--with-system-libunwind', then you must use libunwind 0.98 or later. 3526 3527 ia64-*-hpux* 3528 ============ 3529 3530 Building GCC on this target requires the GNU Assembler. The bundled HP 3531 assembler will not work. To prevent GCC from using the wrong assembler, 3532 the option '--with-gnu-as' may be necessary. 3533 3534 The GCC libunwind library has not been ported to HPUX. This means 3535 that for GCC versions 3.2.3 and earlier, '--enable-libunwind-exceptions' 3536 is required to build GCC. For GCC 3.3 and later, this is the default. 3537 For gcc 3.4.3 and later, '--enable-libunwind-exceptions' is removed and 3538 the system libunwind library will always be used. 3539 3540 *-ibm-aix* 3541 ========== 3542 3543 Support for AIX version 3 and older was discontinued in GCC 3.4. 3544 Support for AIX version 4.2 and older was discontinued in GCC 4.5. 3545 3546 "out of memory" bootstrap failures may indicate a problem with 3547 process resource limits (ulimit). Hard limits are configured in the 3548 '/etc/security/limits' system configuration file. 3549 3550 GCC 4.9 and above require a C++ compiler for bootstrap. IBM VAC++ / 3551 xlC cannot bootstrap GCC. xlc can bootstrap an older version of GCC and 3552 G++ can bootstrap recent releases of GCC. 3553 3554 GCC can bootstrap with recent versions of IBM XLC, but bootstrapping 3555 with an earlier release of GCC is recommended. Bootstrapping with XLC 3556 requires a larger data segment, which can be enabled through the 3557 LDR_CNTRL environment variable, e.g., 3558 3559 % LDR_CNTRL=MAXDATA=0x50000000 3560 % export LDR_CNTRL 3561 3562 One can start with a pre-compiled version of GCC to build from 3563 sources. One may delete GCC's "fixed" header files when starting with a 3564 version of GCC built for an earlier release of AIX. 3565 3566 To speed up the configuration phases of bootstrapping and installing 3567 GCC, one may use GNU Bash instead of AIX '/bin/sh', e.g., 3568 3569 % CONFIG_SHELL=/opt/freeware/bin/bash 3570 % export CONFIG_SHELL 3571 3572 and then proceed as described in the build instructions, where we 3573 strongly recommend specifying an absolute path to invoke 3574 SRCDIR/configure. 3575 3576 Because GCC on AIX is built as a 32-bit executable by default, 3577 (although it can generate 64-bit programs) the GMP and MPFR libraries 3578 required by gfortran must be 32-bit libraries. Building GMP and MPFR as 3579 static archive libraries works better than shared libraries. 3580 3581 Errors involving 'alloca' when building GCC generally are due to an 3582 incorrect definition of 'CC' in the Makefile or mixing files compiled 3583 with the native C compiler and GCC. During the stage1 phase of the 3584 build, the native AIX compiler *must* be invoked as 'cc' (not 'xlc'). 3585 Once 'configure' has been informed of 'xlc', one needs to use 'make 3586 distclean' to remove the configure cache files and ensure that 'CC' 3587 environment variable does not provide a definition that will confuse 3588 'configure'. If this error occurs during stage2 or later, then the 3589 problem most likely is the version of Make (see above). 3590 3591 The native 'as' and 'ld' are recommended for bootstrapping on AIX. 3592 The GNU Assembler, GNU Linker, and GNU Binutils version 2.20 is the 3593 minimum level that supports bootstrap on AIX 5. The GNU Assembler has 3594 not been updated to support AIX 6 or AIX 7. The native AIX tools do 3595 interoperate with GCC. 3596 3597 AIX 7.1 added partial support for DWARF debugging, but full support 3598 requires AIX 7.1 TL03 SP7 that supports additional DWARF sections and 3599 fixes a bug in the assembler. AIX 7.1 TL03 SP5 distributed a version of 3600 libm.a missing important symbols; a fix for IV77796 will be included in 3601 SP6. 3602 3603 AIX 5.3 TL10, AIX 6.1 TL05 and AIX 7.1 TL00 introduced an AIX 3604 assembler change that sometimes produces corrupt assembly files causing 3605 AIX linker errors. The bug breaks GCC bootstrap on AIX and can cause 3606 compilation failures with existing GCC installations. An AIX iFix for 3607 AIX 5.3 is available (APAR IZ98385 for AIX 5.3 TL10, APAR IZ98477 for 3608 AIX 5.3 TL11 and IZ98134 for AIX 5.3 TL12). AIX 5.3 TL11 SP8, AIX 5.3 3609 TL12 SP5, AIX 6.1 TL04 SP11, AIX 6.1 TL05 SP7, AIX 6.1 TL06 SP6, AIX 6.1 3610 TL07 and AIX 7.1 TL01 should include the fix. 3611 3612 Building 'libstdc++.a' requires a fix for an AIX Assembler bug APAR 3613 IY26685 (AIX 4.3) or APAR IY25528 (AIX 5.1). It also requires a fix for 3614 another AIX Assembler bug and a co-dependent AIX Archiver fix referenced 3615 as APAR IY53606 (AIX 5.2) or as APAR IY54774 (AIX 5.1) 3616 3617 'libstdc++' in GCC 3.4 increments the major version number of the 3618 shared object and GCC installation places the 'libstdc++.a' shared 3619 library in a common location which will overwrite the and GCC 3.3 3620 version of the shared library. Applications either need to be re-linked 3621 against the new shared library or the GCC 3.1 and GCC 3.3 versions of 3622 the 'libstdc++' shared object needs to be available to the AIX runtime 3623 loader. The GCC 3.1 'libstdc++.so.4', if present, and GCC 3.3 3624 'libstdc++.so.5' shared objects can be installed for runtime dynamic 3625 loading using the following steps to set the 'F_LOADONLY' flag in the 3626 shared object for _each_ multilib 'libstdc++.a' installed: 3627 3628 Extract the shared objects from the currently installed 'libstdc++.a' 3629 archive: 3630 % ar -x libstdc++.a libstdc++.so.4 libstdc++.so.5 3631 3632 Enable the 'F_LOADONLY' flag so that the shared object will be 3633 available for runtime dynamic loading, but not linking: 3634 % strip -e libstdc++.so.4 libstdc++.so.5 3635 3636 Archive the runtime-only shared object in the GCC 3.4 'libstdc++.a' 3637 archive: 3638 % ar -q libstdc++.a libstdc++.so.4 libstdc++.so.5 3639 3640 Eventually, the '--with-aix-soname=svr4' configure option may drop 3641 the need for this procedure for libraries that support it. 3642 3643 Linking executables and shared libraries may produce warnings of 3644 duplicate symbols. The assembly files generated by GCC for AIX always 3645 have included multiple symbol definitions for certain global variable 3646 and function declarations in the original program. The warnings should 3647 not prevent the linker from producing a correct library or runnable 3648 executable. 3649 3650 AIX 4.3 utilizes a "large format" archive to support both 32-bit and 3651 64-bit object modules. The routines provided in AIX 4.3.0 and AIX 4.3.1 3652 to parse archive libraries did not handle the new format correctly. 3653 These routines are used by GCC and result in error messages during 3654 linking such as "not a COFF file". The version of the routines shipped 3655 with AIX 4.3.1 should work for a 32-bit environment. The '-g' option of 3656 the archive command may be used to create archives of 32-bit objects 3657 using the original "small format". A correct version of the routines is 3658 shipped with AIX 4.3.2 and above. 3659 3660 Some versions of the AIX binder (linker) can fail with a relocation 3661 overflow severe error when the '-bbigtoc' option is used to link 3662 GCC-produced object files into an executable that overflows the TOC. A 3663 fix for APAR IX75823 (OVERFLOW DURING LINK WHEN USING GCC AND -BBIGTOC) 3664 is available from IBM Customer Support and from its 3665 techsupport.services.ibm.com website as PTF U455193. 3666 3667 The AIX 4.3.2.1 linker (bos.rte.bind_cmds Level 4.3.2.1) will dump 3668 core with a segmentation fault when invoked by any version of GCC. A 3669 fix for APAR IX87327 is available from IBM Customer Support and from its 3670 techsupport.services.ibm.com website as PTF U461879. This fix is 3671 incorporated in AIX 4.3.3 and above. 3672 3673 The initial assembler shipped with AIX 4.3.0 generates incorrect 3674 object files. A fix for APAR IX74254 (64BIT DISASSEMBLED OUTPUT FROM 3675 COMPILER FAILS TO ASSEMBLE/BIND) is available from IBM Customer Support 3676 and from its techsupport.services.ibm.com website as PTF U453956. This 3677 fix is incorporated in AIX 4.3.1 and above. 3678 3679 AIX provides National Language Support (NLS). Compilers and 3680 assemblers use NLS to support locale-specific representations of various 3681 data formats including floating-point numbers (e.g., '.' vs ',' for 3682 separating decimal fractions). There have been problems reported where 3683 GCC does not produce the same floating-point formats that the assembler 3684 expects. If one encounters this problem, set the 'LANG' environment 3685 variable to 'C' or 'En_US'. 3686 3687 A default can be specified with the '-mcpu=CPU_TYPE' switch and using 3688 the configure option '--with-cpu-CPU_TYPE'. 3689 3690 iq2000-*-elf 3691 ============ 3692 3693 Vitesse IQ2000 processors. These are used in embedded applications. 3694 There are no standard Unix configurations. 3695 3696 lm32-*-elf 3697 ========== 3698 3699 Lattice Mico32 processor. This configuration is intended for embedded 3700 systems. 3701 3702 lm32-*-uclinux 3703 ============== 3704 3705 Lattice Mico32 processor. This configuration is intended for embedded 3706 systems running uClinux. 3707 3708 LoongArch 3709 ========= 3710 3711 LoongArch processor. The following LoongArch targets are available: 3712 'loongarch64-linux-gnu*' 3713 LoongArch processor running GNU/Linux. This target triplet may be 3714 coupled with a small set of possible suffixes to identify their 3715 default ABI type: 3716 'f64' 3717 Uses 'lp64d/base' ABI by default. 3718 'f32' 3719 Uses 'lp64f/base' ABI by default. 3720 'sf' 3721 Uses 'lp64s/base' ABI by default. 3722 3723 'loongarch64-linux-gnu' 3724 Same as 'loongarch64-linux-gnuf64', but may be used with 3725 '--with-abi=*' to configure the default ABI type. 3726 3727 More information about LoongArch can be found at 3728 <https://github.com/loongson/LoongArch-Documentation>. 3729 3730 m32c-*-elf 3731 ========== 3732 3733 Renesas M32C processor. This configuration is intended for embedded 3734 systems. 3735 3736 m32r-*-elf 3737 ========== 3738 3739 Renesas M32R processor. This configuration is intended for embedded 3740 systems. 3741 3742 m68k-*-* 3743 ======== 3744 3745 By default, 'm68k-*-elf*', 'm68k-*-rtems', 'm68k-*-uclinux' and 3746 'm68k-*-linux' build libraries for both M680x0 and ColdFire processors. 3747 If you only need the M680x0 libraries, you can omit the ColdFire ones by 3748 passing '--with-arch=m68k' to 'configure'. Alternatively, you can omit 3749 the M680x0 libraries by passing '--with-arch=cf' to 'configure'. These 3750 targets default to 5206 or 5475 code as appropriate for the target 3751 system when configured with '--with-arch=cf' and 68020 code otherwise. 3752 3753 The 'm68k-*-netbsd' and 'm68k-*-openbsd' targets also support the 3754 '--with-arch' option. They will generate ColdFire CFV4e code when 3755 configured with '--with-arch=cf' and 68020 code otherwise. 3756 3757 You can override the default processors listed above by configuring 3758 with '--with-cpu=TARGET'. This TARGET can either be a '-mcpu' argument 3759 or one of the following values: 'm68000', 'm68010', 'm68020', 'm68030', 3760 'm68040', 'm68060', 'm68020-40' and 'm68020-60'. 3761 3762 GCC requires at least binutils version 2.17 on these targets. 3763 3764 m68k-*-uclinux 3765 ============== 3766 3767 GCC 4.3 changed the uClinux configuration so that it uses the 3768 'm68k-linux-gnu' ABI rather than the 'm68k-elf' ABI. It also added 3769 improved support for C++ and flat shared libraries, both of which were 3770 ABI changes. 3771 3772 microblaze-*-elf 3773 ================ 3774 3775 Xilinx MicroBlaze processor. This configuration is intended for 3776 embedded systems. 3777 3778 mips-*-* 3779 ======== 3780 3781 If on a MIPS system you get an error message saying "does not have gp 3782 sections for all it's [sic] sectons [sic]", don't worry about it. This 3783 happens whenever you use GAS with the MIPS linker, but there is not 3784 really anything wrong, and it is okay to use the output file. You can 3785 stop such warnings by installing the GNU linker. 3786 3787 It would be nice to extend GAS to produce the gp tables, but they are 3788 optional, and there should not be a warning about their absence. 3789 3790 The libstdc++ atomic locking routines for MIPS targets requires MIPS 3791 II and later. A patch went in just after the GCC 3.3 release to make 3792 'mips*-*-*' use the generic implementation instead. You can also 3793 configure for 'mipsel-elf' as a workaround. The 'mips*-*-linux*' target 3794 continues to use the MIPS II routines. More work on this is expected in 3795 future releases. 3796 3797 The built-in '__sync_*' functions are available on MIPS II and later 3798 systems and others that support the 'll', 'sc' and 'sync' instructions. 3799 This can be overridden by passing '--with-llsc' or '--without-llsc' when 3800 configuring GCC. Since the Linux kernel emulates these instructions if 3801 they are missing, the default for 'mips*-*-linux*' targets is 3802 '--with-llsc'. The '--with-llsc' and '--without-llsc' configure options 3803 may be overridden at compile time by passing the '-mllsc' or '-mno-llsc' 3804 options to the compiler. 3805 3806 MIPS systems check for division by zero (unless 3807 '-mno-check-zero-division' is passed to the compiler) by generating 3808 either a conditional trap or a break instruction. Using trap results in 3809 smaller code, but is only supported on MIPS II and later. Also, some 3810 versions of the Linux kernel have a bug that prevents trap from 3811 generating the proper signal ('SIGFPE'). To enable the use of break, 3812 use the '--with-divide=breaks' 'configure' option when configuring GCC. 3813 The default is to use traps on systems that support them. 3814 3815 moxie-*-elf 3816 =========== 3817 3818 The moxie processor. 3819 3820 msp430-*-elf* 3821 ============= 3822 3823 TI MSP430 processor. This configuration is intended for embedded 3824 systems. 3825 3826 'msp430-*-elf' is the standard configuration with most GCC features 3827 enabled by default. 3828 3829 'msp430-*-elfbare' is tuned for a bare-metal environment, and 3830 disables features related to shared libraries and other functionality 3831 not used for this device. This reduces code and data usage of the GCC 3832 libraries, resulting in a minimal run-time environment by default. 3833 3834 Features disabled by default include: 3835 * transactional memory 3836 * __cxa_atexit 3837 3838 nds32le-*-elf 3839 ============= 3840 3841 Andes NDS32 target in little endian mode. 3842 3843 nds32be-*-elf 3844 ============= 3845 3846 Andes NDS32 target in big endian mode. 3847 3848 nvptx-*-none 3849 ============ 3850 3851 Nvidia PTX target. 3852 3853 Instead of GNU binutils, you will need to install nvptx-tools. Tell 3854 GCC where to find it: 3855 '--with-build-time-tools=[install-nvptx-tools]/nvptx-none/bin'. 3856 3857 You will need newlib 3.1.0 or later. It can be automatically built 3858 together with GCC. For this, add a symbolic link to nvptx-newlib's 3859 'newlib' directory to the directory containing the GCC sources. 3860 3861 Use the '--disable-sjlj-exceptions' and 3862 '--enable-newlib-io-long-long' options when configuring. 3863 3864 or1k-*-elf 3865 ========== 3866 3867 The OpenRISC 1000 32-bit processor with delay slots. This configuration 3868 is intended for embedded systems. 3869 3870 or1k-*-linux 3871 ============ 3872 3873 The OpenRISC 1000 32-bit processor with delay slots. 3874 3875 powerpc-*-* 3876 =========== 3877 3878 You can specify a default version for the '-mcpu=CPU_TYPE' switch by 3879 using the configure option '--with-cpu-CPU_TYPE'. 3880 3881 You will need GNU binutils 2.20 or newer. 3882 3883 powerpc-*-darwin* 3884 ================= 3885 3886 PowerPC running Darwin (Mac OS X kernel). 3887 3888 Pre-installed versions of Mac OS X may not include any developer 3889 tools, meaning that you will not be able to build GCC from source. Tool 3890 binaries are available at <https://opensource.apple.com>. 3891 3892 This version of GCC requires at least cctools-590.36. The 3893 cctools-590.36 package referenced from 3894 <https://gcc.gnu.org/ml/gcc/2006-03/msg00507.html> will not work on 3895 systems older than 10.3.9 (aka darwin7.9.0). 3896 3897 powerpc-*-elf 3898 ============= 3899 3900 PowerPC system in big endian mode, running System V.4. 3901 3902 powerpc*-*-linux-gnu* 3903 ===================== 3904 3905 PowerPC system in big endian mode running Linux. 3906 3907 powerpc-*-netbsd* 3908 ================= 3909 3910 PowerPC system in big endian mode running NetBSD. 3911 3912 powerpc-*-eabisim 3913 ================= 3914 3915 Embedded PowerPC system in big endian mode for use in running under the 3916 PSIM simulator. 3917 3918 powerpc-*-eabi 3919 ============== 3920 3921 Embedded PowerPC system in big endian mode. 3922 3923 powerpcle-*-elf 3924 =============== 3925 3926 PowerPC system in little endian mode, running System V.4. 3927 3928 powerpcle-*-eabisim 3929 =================== 3930 3931 Embedded PowerPC system in little endian mode for use in running under 3932 the PSIM simulator. 3933 3934 powerpcle-*-eabi 3935 ================ 3936 3937 Embedded PowerPC system in little endian mode. 3938 3939 rl78-*-elf 3940 ========== 3941 3942 The Renesas RL78 processor. This configuration is intended for embedded 3943 systems. 3944 3945 riscv32-*-elf 3946 ============= 3947 3948 The RISC-V RV32 instruction set. This configuration is intended for 3949 embedded systems. This (and all other RISC-V) targets require the 3950 binutils 2.30 release. 3951 3952 riscv32-*-linux 3953 =============== 3954 3955 The RISC-V RV32 instruction set running GNU/Linux. This (and all other 3956 RISC-V) targets require the binutils 2.30 release. 3957 3958 riscv64-*-elf 3959 ============= 3960 3961 The RISC-V RV64 instruction set. This configuration is intended for 3962 embedded systems. This (and all other RISC-V) targets require the 3963 binutils 2.30 release. 3964 3965 riscv64-*-linux 3966 =============== 3967 3968 The RISC-V RV64 instruction set running GNU/Linux. This (and all other 3969 RISC-V) targets require the binutils 2.30 release. 3970 3971 rx-*-elf 3972 ======== 3973 3974 The Renesas RX processor. 3975 3976 s390-*-linux* 3977 ============= 3978 3979 S/390 system running GNU/Linux for S/390. 3980 3981 s390x-*-linux* 3982 ============== 3983 3984 zSeries system (64-bit) running GNU/Linux for zSeries. 3985 3986 s390x-ibm-tpf* 3987 ============== 3988 3989 zSeries system (64-bit) running TPF. This platform is supported as 3990 cross-compilation target only. 3991 3992 *-*-solaris2* 3993 ============= 3994 3995 Support for Solaris 10 has been removed in GCC 10. Support for Solaris 3996 9 has been removed in GCC 5. Support for Solaris 8 has been removed in 3997 GCC 4.8. Support for Solaris 7 has been removed in GCC 4.6. 3998 3999 Solaris 11.3 provides GCC 4.5.2, 4.7.3, and 4.8.2 as 4000 '/usr/gcc/4.5/bin/gcc' or similar. Newer Solaris versions provide one 4001 or more of GCC 5, 7, and 9. Alternatively, you can install a pre-built 4002 GCC to bootstrap and install GCC. See the binaries page for details. 4003 4004 The Solaris 2 '/bin/sh' will often fail to configure 'libstdc++-v3'. 4005 We therefore recommend using the following initial sequence of commands 4006 4007 % CONFIG_SHELL=/bin/ksh 4008 % export CONFIG_SHELL 4009 4010 and proceed as described in the configure instructions. In addition we 4011 strongly recommend specifying an absolute path to invoke 4012 'SRCDIR/configure'. 4013 4014 In Solaris 11, you need to check for 'system/header', 4015 'system/linker', and 'developer/assembler' packages. 4016 4017 Trying to use the linker and other tools in '/usr/ucb' to install GCC 4018 has been observed to cause trouble. For example, the linker may hang 4019 indefinitely. The fix is to remove '/usr/ucb' from your 'PATH'. 4020 4021 The build process works more smoothly with the legacy Solaris tools 4022 so, if you have '/usr/xpg4/bin' in your 'PATH', we recommend that you 4023 place '/usr/bin' before '/usr/xpg4/bin' for the duration of the build. 4024 4025 We recommend the use of the Solaris assembler or the GNU assembler, 4026 in conjunction with the Solaris linker. The GNU 'as' versions included 4027 in Solaris 11.3, from GNU binutils 2.23.1 or newer (in '/usr/bin/gas' 4028 and '/usr/gnu/bin/as'), are known to work. The current version, from 4029 GNU binutils 2.34, is known to work as well. Note that your mileage may 4030 vary if you use a combination of the GNU tools and the Solaris tools: 4031 while the combination GNU 'as' + Solaris 'ld' should reasonably work, 4032 the reverse combination Solaris 'as' + GNU 'ld' may fail to build or 4033 cause memory corruption at runtime in some cases for C++ programs. GNU 4034 'ld' usually works as well. Again, the current version (2.34) is known 4035 to work, but generally lacks platform specific features, so better stay 4036 with Solaris 'ld'. To use the LTO linker plugin ('-fuse-linker-plugin') 4037 with GNU 'ld', GNU binutils _must_ be configured with 4038 '--enable-largefile'. 4039 4040 To enable symbol versioning in 'libstdc++' with the Solaris linker, 4041 you need to have any version of GNU 'c++filt', which is part of GNU 4042 binutils. 'libstdc++' symbol versioning will be disabled if no 4043 appropriate version is found. Solaris 'c++filt' from the Solaris Studio 4044 compilers does _not_ work. 4045 4046 In order to build the GNU D compiler, GDC, a working 'libphobos' is 4047 needed. That library wasn't built by default in GCC 9-11 on SPARC, or 4048 on x86 when the Solaris assembler is used, but can be enabled by 4049 configuring with '--enable-libphobos'. Also, GDC 9.4.0 is required on 4050 x86, while GDC 9.3.0 is known to work on SPARC. 4051 4052 The versions of the GNU Multiple Precision Library (GMP), the MPFR 4053 library and the MPC library bundled with Solaris 11.3 and later are 4054 usually recent enough to match GCC's requirements. There are two 4055 caveats: 4056 4057 * While the version of the GMP library in Solaris 11.3 works with 4058 GCC, you need to configure with 4059 '--with-gmp-include=/usr/include/gmp'. 4060 4061 * The version of the MPFR libary included in Solaris 11.3 is too old; 4062 you need to provide a more recent one. 4063 4064 sparc*-*-* 4065 ========== 4066 4067 This section contains general configuration information for all 4068 SPARC-based platforms. In addition to reading this section, please read 4069 all other sections that match your target. 4070 4071 Newer versions of the GNU Multiple Precision Library (GMP), the MPFR 4072 library and the MPC library are known to be miscompiled by earlier 4073 versions of GCC on these platforms. We therefore recommend the use of 4074 the exact versions of these libraries listed as minimal versions in the 4075 prerequisites. 4076 4077 sparc-sun-solaris2* 4078 =================== 4079 4080 When GCC is configured to use GNU binutils 2.14 or later, the binaries 4081 produced are smaller than the ones produced using Solaris native tools; 4082 this difference is quite significant for binaries containing debugging 4083 information. 4084 4085 Starting with Solaris 7, the operating system is capable of executing 4086 64-bit SPARC V9 binaries. GCC 3.1 and later properly supports this; the 4087 '-m64' option enables 64-bit code generation. However, if all you want 4088 is code tuned for the UltraSPARC CPU, you should try the 4089 '-mtune=ultrasparc' option instead, which produces code that, unlike 4090 full 64-bit code, can still run on non-UltraSPARC machines. 4091 4092 When configuring the GNU Multiple Precision Library (GMP), the MPFR 4093 library or the MPC library on a Solaris 7 or later system, the canonical 4094 target triplet must be specified as the 'build' parameter on the 4095 configure line. This target triplet can be obtained by invoking 4096 './config.guess' in the toplevel source directory of GCC (and not that 4097 of GMP or MPFR or MPC). For example on a Solaris 11 system: 4098 4099 % ./configure --build=sparc-sun-solaris2.11 --prefix=xxx 4100 4101 sparc-*-linux* 4102 ============== 4103 4104 sparc64-*-solaris2* 4105 =================== 4106 4107 When configuring a 64-bit-default GCC on Solaris/SPARC, you must use a 4108 build compiler that generates 64-bit code, either by default or by 4109 specifying 'CC='gcc -m64' CXX='gcc-m64'' to 'configure'. Additionally, 4110 you _must_ pass '--build=sparc64-sun-solaris2.11' or 4111 '--build=sparcv9-sun-solaris2.11' because 'config.guess' misdetects this 4112 situation, which can cause build failures. 4113 4114 When configuring the GNU Multiple Precision Library (GMP), the MPFR 4115 library or the MPC library, the canonical target triplet must be 4116 specified as the 'build' parameter on the configure line. For example 4117 on a Solaris 11 system: 4118 4119 % ./configure --build=sparc64-sun-solaris2.11 --prefix=xxx 4120 4121 sparcv9-*-solaris2* 4122 =================== 4123 4124 This is a synonym for 'sparc64-*-solaris2*'. 4125 4126 c6x-*-* 4127 ======= 4128 4129 The C6X family of processors. This port requires binutils-2.22 or 4130 newer. 4131 4132 tilegx-*-linux* 4133 =============== 4134 4135 The TILE-Gx processor in little endian mode, running GNU/Linux. This 4136 port requires binutils-2.22 or newer. 4137 4138 tilegxbe-*-linux* 4139 ================= 4140 4141 The TILE-Gx processor in big endian mode, running GNU/Linux. This port 4142 requires binutils-2.23 or newer. 4143 4144 tilepro-*-linux* 4145 ================ 4146 4147 The TILEPro processor running GNU/Linux. This port requires 4148 binutils-2.22 or newer. 4149 4150 visium-*-elf 4151 ============ 4152 4153 CDS VISIUMcore processor. This configuration is intended for embedded 4154 systems. 4155 4156 *-*-vxworks* 4157 ============ 4158 4159 Support for VxWorks is in flux. At present GCC supports _only_ the very 4160 recent VxWorks 5.5 (aka Tornado 2.2) release, and only on PowerPC. We 4161 welcome patches for other architectures supported by VxWorks 5.5. 4162 Support for VxWorks AE would also be welcome; we believe this is merely 4163 a matter of writing an appropriate "configlette" (see below). We are 4164 not interested in supporting older, a.out or COFF-based, versions of 4165 VxWorks in GCC 3. 4166 4167 VxWorks comes with an older version of GCC installed in 4168 '$WIND_BASE/host'; we recommend you do not overwrite it. Choose an 4169 installation PREFIX entirely outside $WIND_BASE. Before running 4170 'configure', create the directories 'PREFIX' and 'PREFIX/bin'. Link or 4171 copy the appropriate assembler, linker, etc. into 'PREFIX/bin', and set 4172 your PATH to include that directory while running both 'configure' and 4173 'make'. 4174 4175 You must give 'configure' the '--with-headers=$WIND_BASE/target/h' 4176 switch so that it can find the VxWorks system headers. Since VxWorks is 4177 a cross compilation target only, you must also specify 4178 '--target=TARGET'. 'configure' will attempt to create the directory 4179 'PREFIX/TARGET/sys-include' and copy files into it; make sure the user 4180 running 'configure' has sufficient privilege to do so. 4181 4182 GCC's exception handling runtime requires a special "configlette" 4183 module, 'contrib/gthr_supp_vxw_5x.c'. Follow the instructions in that 4184 file to add the module to your kernel build. (Future versions of 4185 VxWorks will incorporate this module.) 4186 4187 x86_64-*-*, amd64-*-* 4188 ===================== 4189 4190 GCC supports the x86-64 architecture implemented by the AMD64 processor 4191 (amd64-*-* is an alias for x86_64-*-*) on GNU/Linux, FreeBSD and NetBSD. 4192 On GNU/Linux the default is a bi-arch compiler which is able to generate 4193 both 64-bit x86-64 and 32-bit x86 code (via the '-m32' switch). 4194 4195 x86_64-*-solaris2* 4196 ================== 4197 4198 GCC also supports the x86-64 architecture implemented by the AMD64 4199 processor ('amd64-*-*' is an alias for 'x86_64-*-*') on Solaris 10 or 4200 later. Unlike other systems, without special options a bi-arch compiler 4201 is built which generates 32-bit code by default, but can generate 64-bit 4202 x86-64 code with the '-m64' switch. Since GCC 4.7, there is also a 4203 configuration that defaults to 64-bit code, but can generate 32-bit code 4204 with '-m32'. To configure and build this way, you have to provide all 4205 support libraries like 'libgmp' as 64-bit code, configure with 4206 '--target=x86_64-pc-solaris2.11' and 'CC=gcc -m64'. 4207 4208 xtensa*-*-elf 4209 ============= 4210 4211 This target is intended for embedded Xtensa systems using the 'newlib' C 4212 library. It uses ELF but does not support shared objects. 4213 Designed-defined instructions specified via the Tensilica Instruction 4214 Extension (TIE) language are only supported through inline assembly. 4215 4216 The Xtensa configuration information must be specified prior to 4217 building GCC. The 'include/xtensa-config.h' header file contains the 4218 configuration information. If you created your own Xtensa configuration 4219 with the Xtensa Processor Generator, the downloaded files include a 4220 customized copy of this header file, which you can use to replace the 4221 default header file. 4222 4223 xtensa*-*-linux* 4224 ================ 4225 4226 This target is for Xtensa systems running GNU/Linux. It supports ELF 4227 shared objects and the GNU C library (glibc). It also generates 4228 position-independent code (PIC) regardless of whether the '-fpic' or 4229 '-fPIC' options are used. In other respects, this target is the same as 4230 the 'xtensa*-*-elf' target. 4231 4232 Microsoft Windows 4233 ================= 4234 4235 Intel 16-bit versions 4236 --------------------- 4237 4238 The 16-bit versions of Microsoft Windows, such as Windows 3.1, are not 4239 supported. 4240 4241 However, the 32-bit port has limited support for Microsoft Windows 4242 3.11 in the Win32s environment, as a target only. See below. 4243 4244 Intel 32-bit versions 4245 --------------------- 4246 4247 The 32-bit versions of Windows, including Windows 95, Windows NT, 4248 Windows XP, and Windows Vista, are supported by several different target 4249 platforms. These targets differ in which Windows subsystem they target 4250 and which C libraries are used. 4251 4252 * Cygwin *-*-cygwin: Cygwin provides a user-space Linux API emulation 4253 layer in the Win32 subsystem. 4254 * MinGW *-*-mingw32: MinGW is a native GCC port for the Win32 4255 subsystem that provides a subset of POSIX. 4256 * MKS i386-pc-mks: NuTCracker from MKS. See 4257 <https://www.mkssoftware.com> for more information. 4258 4259 Intel 64-bit versions 4260 --------------------- 4261 4262 GCC contains support for x86-64 using the mingw-w64 runtime library, 4263 available from <https://www.mingw-w64.org/downloads/>. This library 4264 should be used with the target triple x86_64-pc-mingw32. 4265 4266 Windows CE 4267 ---------- 4268 4269 Windows CE is supported as a target only on Hitachi SuperH 4270 (sh-wince-pe), and MIPS (mips-wince-pe). 4271 4272 Other Windows Platforms 4273 ----------------------- 4274 4275 GCC no longer supports Windows NT on the Alpha or PowerPC. 4276 4277 GCC no longer supports the Windows POSIX subsystem. However, it does 4278 support the Interix subsystem. See above. 4279 4280 Old target names including *-*-winnt and *-*-windowsnt are no longer 4281 used. 4282 4283 PW32 (i386-pc-pw32) support was never completed, and the project 4284 seems to be inactive. See <http://pw32.sourceforge.net/> for more 4285 information. 4286 4287 UWIN support has been removed due to a lack of maintenance. 4288 4289 *-*-cygwin 4290 ========== 4291 4292 Ports of GCC are included with the Cygwin environment. 4293 4294 GCC will build under Cygwin without modification; it does not build 4295 with Microsoft's C++ compiler and there are no plans to make it do so. 4296 4297 The Cygwin native compiler can be configured to target any 32-bit x86 4298 cpu architecture desired; the default is i686-pc-cygwin. It should be 4299 used with as up-to-date a version of binutils as possible; use either 4300 the latest official GNU binutils release in the Cygwin distribution, or 4301 version 2.20 or above if building your own. 4302 4303 *-*-mingw32 4304 =========== 4305 4306 GCC will build with and support only MinGW runtime 3.12 and later. 4307 Earlier versions of headers are incompatible with the new default 4308 semantics of 'extern inline' in '-std=c99' and '-std=gnu99' modes. 4309 4310 To support emitting DWARF debugging info you need to use GNU binutils 4311 version 2.16 or above containing support for the '.secrel32' assembler 4312 pseudo-op. 4313 4314 Older systems 4315 ============= 4316 4317 GCC contains support files for many older (1980s and early 1990s) Unix 4318 variants. For the most part, support for these systems has not been 4319 deliberately removed, but it has not been maintained for several years 4320 and may suffer from bitrot. 4321 4322 Starting with GCC 3.1, each release has a list of "obsoleted" 4323 systems. Support for these systems is still present in that release, 4324 but 'configure' will fail unless the '--enable-obsolete' option is 4325 given. Unless a maintainer steps forward, support for these systems 4326 will be removed from the next release of GCC. 4327 4328 Support for old systems as hosts for GCC can cause problems if the 4329 workarounds for compiler, library and operating system bugs affect the 4330 cleanliness or maintainability of the rest of GCC. In some cases, to 4331 bring GCC up on such a system, if still possible with current GCC, may 4332 require first installing an old version of GCC which did work on that 4333 system, and using it to compile a more recent GCC, to avoid bugs in the 4334 vendor compiler. Old releases of GCC 1 and GCC 2 are available in the 4335 'old-releases' directory on the GCC mirror sites. Header bugs may 4336 generally be avoided using 'fixincludes', but bugs or deficiencies in 4337 libraries and the operating system may still cause problems. 4338 4339 Support for older systems as targets for cross-compilation is less 4340 problematic than support for them as hosts for GCC; if an enthusiast 4341 wishes to make such a target work again (including resurrecting any of 4342 the targets that never worked with GCC 2, starting from the last version 4343 before they were removed), patches following the usual requirements 4344 would be likely to be accepted, since they should not affect the support 4345 for more modern targets. 4346 4347 For some systems, old versions of GNU binutils may also be useful, 4348 and are available from 'pub/binutils/old-releases' on sourceware.org 4349 mirror sites. 4350 4351 Some of the information on specific systems above relates to such 4352 older systems, but much of the information about GCC on such systems 4353 (which may no longer be applicable to current GCC) is to be found in the 4354 GCC texinfo manual. 4355 4356 all ELF targets (SVR4, Solaris 2, etc.) 4357 ======================================= 4358 4359 C++ support is significantly better on ELF targets if you use the GNU 4360 linker; duplicate copies of inlines, vtables and template instantiations 4361 will be discarded automatically. 4362 4363 4364 File: gccinstall.info, Node: GNU Free Documentation License, Next: Concept Index, Prev: Specific, Up: Top 4365 4366 GNU Free Documentation License 4367 ****************************** 4368 4369 Version 1.3, 3 November 2008 4370 4371 Copyright (C) 2000, 2001, 2002, 2007, 2008 Free Software Foundation, Inc. 4372 <https://fsf.org/> 4373 4374 Everyone is permitted to copy and distribute verbatim copies 4375 of this license document, but changing it is not allowed. 4376 4377 0. PREAMBLE 4378 4379 The purpose of this License is to make a manual, textbook, or other 4380 functional and useful document "free" in the sense of freedom: to 4381 assure everyone the effective freedom to copy and redistribute it, 4382 with or without modifying it, either commercially or 4383 noncommercially. Secondarily, this License preserves for the 4384 author and publisher a way to get credit for their work, while not 4385 being considered responsible for modifications made by others. 4386 4387 This License is a kind of "copyleft", which means that derivative 4388 works of the document must themselves be free in the same sense. 4389 It complements the GNU General Public License, which is a copyleft 4390 license designed for free software. 4391 4392 We have designed this License in order to use it for manuals for 4393 free software, because free software needs free documentation: a 4394 free program should come with manuals providing the same freedoms 4395 that the software does. But this License is not limited to 4396 software manuals; it can be used for any textual work, regardless 4397 of subject matter or whether it is published as a printed book. We 4398 recommend this License principally for works whose purpose is 4399 instruction or reference. 4400 4401 1. APPLICABILITY AND DEFINITIONS 4402 4403 This License applies to any manual or other work, in any medium, 4404 that contains a notice placed by the copyright holder saying it can 4405 be distributed under the terms of this License. Such a notice 4406 grants a world-wide, royalty-free license, unlimited in duration, 4407 to use that work under the conditions stated herein. The 4408 "Document", below, refers to any such manual or work. Any member 4409 of the public is a licensee, and is addressed as "you". You accept 4410 the license if you copy, modify or distribute the work in a way 4411 requiring permission under copyright law. 4412 4413 A "Modified Version" of the Document means any work containing the 4414 Document or a portion of it, either copied verbatim, or with 4415 modifications and/or translated into another language. 4416 4417 A "Secondary Section" is a named appendix or a front-matter section 4418 of the Document that deals exclusively with the relationship of the 4419 publishers or authors of the Document to the Document's overall 4420 subject (or to related matters) and contains nothing that could 4421 fall directly within that overall subject. (Thus, if the Document 4422 is in part a textbook of mathematics, a Secondary Section may not 4423 explain any mathematics.) The relationship could be a matter of 4424 historical connection with the subject or with related matters, or 4425 of legal, commercial, philosophical, ethical or political position 4426 regarding them. 4427 4428 The "Invariant Sections" are certain Secondary Sections whose 4429 titles are designated, as being those of Invariant Sections, in the 4430 notice that says that the Document is released under this License. 4431 If a section does not fit the above definition of Secondary then it 4432 is not allowed to be designated as Invariant. The Document may 4433 contain zero Invariant Sections. If the Document does not identify 4434 any Invariant Sections then there are none. 4435 4436 The "Cover Texts" are certain short passages of text that are 4437 listed, as Front-Cover Texts or Back-Cover Texts, in the notice 4438 that says that the Document is released under this License. A 4439 Front-Cover Text may be at most 5 words, and a Back-Cover Text may 4440 be at most 25 words. 4441 4442 A "Transparent" copy of the Document means a machine-readable copy, 4443 represented in a format whose specification is available to the 4444 general public, that is suitable for revising the document 4445 straightforwardly with generic text editors or (for images composed 4446 of pixels) generic paint programs or (for drawings) some widely 4447 available drawing editor, and that is suitable for input to text 4448 formatters or for automatic translation to a variety of formats 4449 suitable for input to text formatters. A copy made in an otherwise 4450 Transparent file format whose markup, or absence of markup, has 4451 been arranged to thwart or discourage subsequent modification by 4452 readers is not Transparent. An image format is not Transparent if 4453 used for any substantial amount of text. A copy that is not 4454 "Transparent" is called "Opaque". 4455 4456 Examples of suitable formats for Transparent copies include plain 4457 ASCII without markup, Texinfo input format, LaTeX input format, 4458 SGML or XML using a publicly available DTD, and standard-conforming 4459 simple HTML, PostScript or PDF designed for human modification. 4460 Examples of transparent image formats include PNG, XCF and JPG. 4461 Opaque formats include proprietary formats that can be read and 4462 edited only by proprietary word processors, SGML or XML for which 4463 the DTD and/or processing tools are not generally available, and 4464 the machine-generated HTML, PostScript or PDF produced by some word 4465 processors for output purposes only. 4466 4467 The "Title Page" means, for a printed book, the title page itself, 4468 plus such following pages as are needed to hold, legibly, the 4469 material this License requires to appear in the title page. For 4470 works in formats which do not have any title page as such, "Title 4471 Page" means the text near the most prominent appearance of the 4472 work's title, preceding the beginning of the body of the text. 4473 4474 The "publisher" means any person or entity that distributes copies 4475 of the Document to the public. 4476 4477 A section "Entitled XYZ" means a named subunit of the Document 4478 whose title either is precisely XYZ or contains XYZ in parentheses 4479 following text that translates XYZ in another language. (Here XYZ 4480 stands for a specific section name mentioned below, such as 4481 "Acknowledgements", "Dedications", "Endorsements", or "History".) 4482 To "Preserve the Title" of such a section when you modify the 4483 Document means that it remains a section "Entitled XYZ" according 4484 to this definition. 4485 4486 The Document may include Warranty Disclaimers next to the notice 4487 which states that this License applies to the Document. These 4488 Warranty Disclaimers are considered to be included by reference in 4489 this License, but only as regards disclaiming warranties: any other 4490 implication that these Warranty Disclaimers may have is void and 4491 has no effect on the meaning of this License. 4492 4493 2. VERBATIM COPYING 4494 4495 You may copy and distribute the Document in any medium, either 4496 commercially or noncommercially, provided that this License, the 4497 copyright notices, and the license notice saying this License 4498 applies to the Document are reproduced in all copies, and that you 4499 add no other conditions whatsoever to those of this License. You 4500 may not use technical measures to obstruct or control the reading 4501 or further copying of the copies you make or distribute. However, 4502 you may accept compensation in exchange for copies. If you 4503 distribute a large enough number of copies you must also follow the 4504 conditions in section 3. 4505 4506 You may also lend copies, under the same conditions stated above, 4507 and you may publicly display copies. 4508 4509 3. COPYING IN QUANTITY 4510 4511 If you publish printed copies (or copies in media that commonly 4512 have printed covers) of the Document, numbering more than 100, and 4513 the Document's license notice requires Cover Texts, you must 4514 enclose the copies in covers that carry, clearly and legibly, all 4515 these Cover Texts: Front-Cover Texts on the front cover, and 4516 Back-Cover Texts on the back cover. Both covers must also clearly 4517 and legibly identify you as the publisher of these copies. The 4518 front cover must present the full title with all words of the title 4519 equally prominent and visible. You may add other material on the 4520 covers in addition. Copying with changes limited to the covers, as 4521 long as they preserve the title of the Document and satisfy these 4522 conditions, can be treated as verbatim copying in other respects. 4523 4524 If the required texts for either cover are too voluminous to fit 4525 legibly, you should put the first ones listed (as many as fit 4526 reasonably) on the actual cover, and continue the rest onto 4527 adjacent pages. 4528 4529 If you publish or distribute Opaque copies of the Document 4530 numbering more than 100, you must either include a machine-readable 4531 Transparent copy along with each Opaque copy, or state in or with 4532 each Opaque copy a computer-network location from which the general 4533 network-using public has access to download using public-standard 4534 network protocols a complete Transparent copy of the Document, free 4535 of added material. If you use the latter option, you must take 4536 reasonably prudent steps, when you begin distribution of Opaque 4537 copies in quantity, to ensure that this Transparent copy will 4538 remain thus accessible at the stated location until at least one 4539 year after the last time you distribute an Opaque copy (directly or 4540 through your agents or retailers) of that edition to the public. 4541 4542 It is requested, but not required, that you contact the authors of 4543 the Document well before redistributing any large number of copies, 4544 to give them a chance to provide you with an updated version of the 4545 Document. 4546 4547 4. MODIFICATIONS 4548 4549 You may copy and distribute a Modified Version of the Document 4550 under the conditions of sections 2 and 3 above, provided that you 4551 release the Modified Version under precisely this License, with the 4552 Modified Version filling the role of the Document, thus licensing 4553 distribution and modification of the Modified Version to whoever 4554 possesses a copy of it. In addition, you must do these things in 4555 the Modified Version: 4556 4557 A. Use in the Title Page (and on the covers, if any) a title 4558 distinct from that of the Document, and from those of previous 4559 versions (which should, if there were any, be listed in the 4560 History section of the Document). You may use the same title 4561 as a previous version if the original publisher of that 4562 version gives permission. 4563 4564 B. List on the Title Page, as authors, one or more persons or 4565 entities responsible for authorship of the modifications in 4566 the Modified Version, together with at least five of the 4567 principal authors of the Document (all of its principal 4568 authors, if it has fewer than five), unless they release you 4569 from this requirement. 4570 4571 C. State on the Title page the name of the publisher of the 4572 Modified Version, as the publisher. 4573 4574 D. Preserve all the copyright notices of the Document. 4575 4576 E. Add an appropriate copyright notice for your modifications 4577 adjacent to the other copyright notices. 4578 4579 F. Include, immediately after the copyright notices, a license 4580 notice giving the public permission to use the Modified 4581 Version under the terms of this License, in the form shown in 4582 the Addendum below. 4583 4584 G. Preserve in that license notice the full lists of Invariant 4585 Sections and required Cover Texts given in the Document's 4586 license notice. 4587 4588 H. Include an unaltered copy of this License. 4589 4590 I. Preserve the section Entitled "History", Preserve its Title, 4591 and add to it an item stating at least the title, year, new 4592 authors, and publisher of the Modified Version as given on the 4593 Title Page. If there is no section Entitled "History" in the 4594 Document, create one stating the title, year, authors, and 4595 publisher of the Document as given on its Title Page, then add 4596 an item describing the Modified Version as stated in the 4597 previous sentence. 4598 4599 J. Preserve the network location, if any, given in the Document 4600 for public access to a Transparent copy of the Document, and 4601 likewise the network locations given in the Document for 4602 previous versions it was based on. These may be placed in the 4603 "History" section. You may omit a network location for a work 4604 that was published at least four years before the Document 4605 itself, or if the original publisher of the version it refers 4606 to gives permission. 4607 4608 K. For any section Entitled "Acknowledgements" or "Dedications", 4609 Preserve the Title of the section, and preserve in the section 4610 all the substance and tone of each of the contributor 4611 acknowledgements and/or dedications given therein. 4612 4613 L. Preserve all the Invariant Sections of the Document, unaltered 4614 in their text and in their titles. Section numbers or the 4615 equivalent are not considered part of the section titles. 4616 4617 M. Delete any section Entitled "Endorsements". Such a section 4618 may not be included in the Modified Version. 4619 4620 N. Do not retitle any existing section to be Entitled 4621 "Endorsements" or to conflict in title with any Invariant 4622 Section. 4623 4624 O. Preserve any Warranty Disclaimers. 4625 4626 If the Modified Version includes new front-matter sections or 4627 appendices that qualify as Secondary Sections and contain no 4628 material copied from the Document, you may at your option designate 4629 some or all of these sections as invariant. To do this, add their 4630 titles to the list of Invariant Sections in the Modified Version's 4631 license notice. These titles must be distinct from any other 4632 section titles. 4633 4634 You may add a section Entitled "Endorsements", provided it contains 4635 nothing but endorsements of your Modified Version by various 4636 parties--for example, statements of peer review or that the text 4637 has been approved by an organization as the authoritative 4638 definition of a standard. 4639 4640 You may add a passage of up to five words as a Front-Cover Text, 4641 and a passage of up to 25 words as a Back-Cover Text, to the end of 4642 the list of Cover Texts in the Modified Version. Only one passage 4643 of Front-Cover Text and one of Back-Cover Text may be added by (or 4644 through arrangements made by) any one entity. If the Document 4645 already includes a cover text for the same cover, previously added 4646 by you or by arrangement made by the same entity you are acting on 4647 behalf of, you may not add another; but you may replace the old 4648 one, on explicit permission from the previous publisher that added 4649 the old one. 4650 4651 The author(s) and publisher(s) of the Document do not by this 4652 License give permission to use their names for publicity for or to 4653 assert or imply endorsement of any Modified Version. 4654 4655 5. COMBINING DOCUMENTS 4656 4657 You may combine the Document with other documents released under 4658 this License, under the terms defined in section 4 above for 4659 modified versions, provided that you include in the combination all 4660 of the Invariant Sections of all of the original documents, 4661 unmodified, and list them all as Invariant Sections of your 4662 combined work in its license notice, and that you preserve all 4663 their Warranty Disclaimers. 4664 4665 The combined work need only contain one copy of this License, and 4666 multiple identical Invariant Sections may be replaced with a single 4667 copy. If there are multiple Invariant Sections with the same name 4668 but different contents, make the title of each such section unique 4669 by adding at the end of it, in parentheses, the name of the 4670 original author or publisher of that section if known, or else a 4671 unique number. Make the same adjustment to the section titles in 4672 the list of Invariant Sections in the license notice of the 4673 combined work. 4674 4675 In the combination, you must combine any sections Entitled 4676 "History" in the various original documents, forming one section 4677 Entitled "History"; likewise combine any sections Entitled 4678 "Acknowledgements", and any sections Entitled "Dedications". You 4679 must delete all sections Entitled "Endorsements." 4680 4681 6. COLLECTIONS OF DOCUMENTS 4682 4683 You may make a collection consisting of the Document and other 4684 documents released under this License, and replace the individual 4685 copies of this License in the various documents with a single copy 4686 that is included in the collection, provided that you follow the 4687 rules of this License for verbatim copying of each of the documents 4688 in all other respects. 4689 4690 You may extract a single document from such a collection, and 4691 distribute it individually under this License, provided you insert 4692 a copy of this License into the extracted document, and follow this 4693 License in all other respects regarding verbatim copying of that 4694 document. 4695 4696 7. AGGREGATION WITH INDEPENDENT WORKS 4697 4698 A compilation of the Document or its derivatives with other 4699 separate and independent documents or works, in or on a volume of a 4700 storage or distribution medium, is called an "aggregate" if the 4701 copyright resulting from the compilation is not used to limit the 4702 legal rights of the compilation's users beyond what the individual 4703 works permit. When the Document is included in an aggregate, this 4704 License does not apply to the other works in the aggregate which 4705 are not themselves derivative works of the Document. 4706 4707 If the Cover Text requirement of section 3 is applicable to these 4708 copies of the Document, then if the Document is less than one half 4709 of the entire aggregate, the Document's Cover Texts may be placed 4710 on covers that bracket the Document within the aggregate, or the 4711 electronic equivalent of covers if the Document is in electronic 4712 form. Otherwise they must appear on printed covers that bracket 4713 the whole aggregate. 4714 4715 8. TRANSLATION 4716 4717 Translation is considered a kind of modification, so you may 4718 distribute translations of the Document under the terms of section 4719 4. Replacing Invariant Sections with translations requires special 4720 permission from their copyright holders, but you may include 4721 translations of some or all Invariant Sections in addition to the 4722 original versions of these Invariant Sections. You may include a 4723 translation of this License, and all the license notices in the 4724 Document, and any Warranty Disclaimers, provided that you also 4725 include the original English version of this License and the 4726 original versions of those notices and disclaimers. In case of a 4727 disagreement between the translation and the original version of 4728 this License or a notice or disclaimer, the original version will 4729 prevail. 4730 4731 If a section in the Document is Entitled "Acknowledgements", 4732 "Dedications", or "History", the requirement (section 4) to 4733 Preserve its Title (section 1) will typically require changing the 4734 actual title. 4735 4736 9. TERMINATION 4737 4738 You may not copy, modify, sublicense, or distribute the Document 4739 except as expressly provided under this License. Any attempt 4740 otherwise to copy, modify, sublicense, or distribute it is void, 4741 and will automatically terminate your rights under this License. 4742 4743 However, if you cease all violation of this License, then your 4744 license from a particular copyright holder is reinstated (a) 4745 provisionally, unless and until the copyright holder explicitly and 4746 finally terminates your license, and (b) permanently, if the 4747 copyright holder fails to notify you of the violation by some 4748 reasonable means prior to 60 days after the cessation. 4749 4750 Moreover, your license from a particular copyright holder is 4751 reinstated permanently if the copyright holder notifies you of the 4752 violation by some reasonable means, this is the first time you have 4753 received notice of violation of this License (for any work) from 4754 that copyright holder, and you cure the violation prior to 30 days 4755 after your receipt of the notice. 4756 4757 Termination of your rights under this section does not terminate 4758 the licenses of parties who have received copies or rights from you 4759 under this License. If your rights have been terminated and not 4760 permanently reinstated, receipt of a copy of some or all of the 4761 same material does not give you any rights to use it. 4762 4763 10. FUTURE REVISIONS OF THIS LICENSE 4764 4765 The Free Software Foundation may publish new, revised versions of 4766 the GNU Free Documentation License from time to time. Such new 4767 versions will be similar in spirit to the present version, but may 4768 differ in detail to address new problems or concerns. See 4769 <https://www.gnu.org/copyleft/>. 4770 4771 Each version of the License is given a distinguishing version 4772 number. If the Document specifies that a particular numbered 4773 version of this License "or any later version" applies to it, you 4774 have the option of following the terms and conditions either of 4775 that specified version or of any later version that has been 4776 published (not as a draft) by the Free Software Foundation. If the 4777 Document does not specify a version number of this License, you may 4778 choose any version ever published (not as a draft) by the Free 4779 Software Foundation. If the Document specifies that a proxy can 4780 decide which future versions of this License can be used, that 4781 proxy's public statement of acceptance of a version permanently 4782 authorizes you to choose that version for the Document. 4783 4784 11. RELICENSING 4785 4786 "Massive Multiauthor Collaboration Site" (or "MMC Site") means any 4787 World Wide Web server that publishes copyrightable works and also 4788 provides prominent facilities for anybody to edit those works. A 4789 public wiki that anybody can edit is an example of such a server. 4790 A "Massive Multiauthor Collaboration" (or "MMC") contained in the 4791 site means any set of copyrightable works thus published on the MMC 4792 site. 4793 4794 "CC-BY-SA" means the Creative Commons Attribution-Share Alike 3.0 4795 license published by Creative Commons Corporation, a not-for-profit 4796 corporation with a principal place of business in San Francisco, 4797 California, as well as future copyleft versions of that license 4798 published by that same organization. 4799 4800 "Incorporate" means to publish or republish a Document, in whole or 4801 in part, as part of another Document. 4802 4803 An MMC is "eligible for relicensing" if it is licensed under this 4804 License, and if all works that were first published under this 4805 License somewhere other than this MMC, and subsequently 4806 incorporated in whole or in part into the MMC, (1) had no cover 4807 texts or invariant sections, and (2) were thus incorporated prior 4808 to November 1, 2008. 4809 4810 The operator of an MMC Site may republish an MMC contained in the 4811 site under CC-BY-SA on the same site at any time before August 1, 4812 2009, provided the MMC is eligible for relicensing. 4813 4814 ADDENDUM: How to use this License for your documents 4815 ==================================================== 4816 4817 To use this License in a document you have written, include a copy of 4818 the License in the document and put the following copyright and license 4819 notices just after the title page: 4820 4821 Copyright (C) YEAR YOUR NAME. 4822 Permission is granted to copy, distribute and/or modify this document 4823 under the terms of the GNU Free Documentation License, Version 1.3 4824 or any later version published by the Free Software Foundation; 4825 with no Invariant Sections, no Front-Cover Texts, and no Back-Cover 4826 Texts. A copy of the license is included in the section entitled ``GNU 4827 Free Documentation License''. 4828 4829 If you have Invariant Sections, Front-Cover Texts and Back-Cover 4830 Texts, replace the "with...Texts." line with this: 4831 4832 with the Invariant Sections being LIST THEIR TITLES, with 4833 the Front-Cover Texts being LIST, and with the Back-Cover Texts 4834 being LIST. 4835 4836 If you have Invariant Sections without Cover Texts, or some other 4837 combination of the three, merge those two alternatives to suit the 4838 situation. 4839 4840 If your document contains nontrivial examples of program code, we 4841 recommend releasing these examples in parallel under your choice of free 4842 software license, such as the GNU General Public License, to permit 4843 their use in free software. 4844 4845 4846 File: gccinstall.info, Node: Concept Index, Prev: GNU Free Documentation License, Up: Top 4847 4848 Concept Index 4849 ************* 4850 4851 [index] 4852 * Menu: 4853 4854 * Binaries: Binaries. (line 6) 4855 * build_configargs: Configuration. (line 1833) 4856 * Configuration: Configuration. (line 6) 4857 * Downloading GCC: Downloading the source. 4858 (line 6) 4859 * Downloading the Source: Downloading the source. 4860 (line 6) 4861 * FDL, GNU Free Documentation License: GNU Free Documentation License. 4862 (line 6) 4863 * Host specific installation: Specific. (line 6) 4864 * host_configargs: Configuration. (line 1837) 4865 * Installing GCC: Binaries: Binaries. (line 6) 4866 * Installing GCC: Building: Building. (line 6) 4867 * Installing GCC: Configuration: Configuration. (line 6) 4868 * Installing GCC: Testing: Testing. (line 6) 4869 * Prerequisites: Prerequisites. (line 6) 4870 * Specific: Specific. (line 6) 4871 * Specific installation notes: Specific. (line 6) 4872 * Target specific installation: Specific. (line 6) 4873 * Target specific installation notes: Specific. (line 6) 4874 * target_configargs: Configuration. (line 1841) 4875 * Testing: Testing. (line 6) 4876 * Testsuite: Testing. (line 6) 4877 4878 4879 4880 Tag Table: 4881 Node: Top1696 4882 Node: Installing GCC2201 4883 Node: Prerequisites3837 4884 Ref: GNAT-prerequisite5825 4885 Ref: GDC-prerequisite7222 4886 Node: Downloading the source16886 4887 Node: Configuration18557 4888 Ref: with-gnu-as36857 4889 Ref: with-as37752 4890 Ref: with-gnu-ld39161 4891 Ref: WithAixSoname64872 4892 Ref: AixLdCommand65533 4893 Node: Building107858 4894 Node: Testing124065 4895 Node: Final install131896 4896 Node: Binaries137197 4897 Node: Specific138304 4898 Ref: aarch64-x-x138838 4899 Ref: alpha-x-x140858 4900 Ref: amd64-x-solaris2141072 4901 Ref: amdgcn-x-amdhsa141154 4902 Ref: arc-x-elf32141680 4903 Ref: arc-linux-uclibc141856 4904 Ref: arm-x-eabi141997 4905 Ref: avr142250 4906 Ref: bfin142831 4907 Ref: cr16143094 4908 Ref: cris143510 4909 Ref: dos143836 4910 Ref: epiphany-x-elf144161 4911 Ref: x-x-freebsd144266 4912 Ref: ft32-x-elf145914 4913 Ref: h8300-hms146012 4914 Ref: hppa-hp-hpux146364 4915 Ref: hppa-hp-hpux10148736 4916 Ref: hppa-hp-hpux11149149 4917 Ref: x-x-linux-gnu154551 4918 Ref: ix86-x-linux154874 4919 Ref: ix86-x-solaris2155187 4920 Ref: ia64-x-linux156263 4921 Ref: ia64-x-hpux156510 4922 Ref: x-ibm-aix157065 4923 Ref: TransferAixShobj160727 4924 Ref: iq2000-x-elf164537 4925 Ref: lm32-x-elf164677 4926 Ref: lm32-x-uclinux164781 4927 Ref: loongarch164909 4928 Ref: m32c-x-elf165603 4929 Ref: m32r-x-elf165705 4930 Ref: m68k-x-x165807 4931 Ref: m68k-x-uclinux166845 4932 Ref: microblaze-x-elf167090 4933 Ref: mips-x-x167209 4934 Ref: moxie-x-elf169119 4935 Ref: msp430-x-elf169166 4936 Ref: nds32le-x-elf169723 4937 Ref: nds32be-x-elf169795 4938 Ref: nvptx-x-none169864 4939 Ref: or1k-x-elf170375 4940 Ref: or1k-x-linux170506 4941 Ref: powerpc-x-x170587 4942 Ref: powerpc-x-darwin170778 4943 Ref: powerpc-x-elf171273 4944 Ref: powerpc-x-linux-gnu171358 4945 Ref: powerpc-x-netbsd171453 4946 Ref: powerpc-x-eabisim171541 4947 Ref: powerpc-x-eabi171667 4948 Ref: powerpcle-x-elf171743 4949 Ref: powerpcle-x-eabisim171835 4950 Ref: powerpcle-x-eabi171968 4951 Ref: rl78-x-elf172051 4952 Ref: riscv32-x-elf172157 4953 Ref: riscv32-x-linux172346 4954 Ref: riscv64-x-elf172503 4955 Ref: riscv64-x-linux172692 4956 Ref: rx-x-elf172849 4957 Ref: s390-x-linux172895 4958 Ref: s390x-x-linux172967 4959 Ref: s390x-ibm-tpf173054 4960 Ref: x-x-solaris2173185 4961 Ref: sparc-x-x176619 4962 Ref: sparc-sun-solaris2177121 4963 Ref: sparc-x-linux178264 4964 Ref: sparc64-x-solaris2178295 4965 Ref: sparcv9-x-solaris2179013 4966 Ref: c6x-x-x179100 4967 Ref: tilegx-*-linux179192 4968 Ref: tilegxbe-*-linux179334 4969 Ref: tilepro-*-linux179477 4970 Ref: visium-x-elf179598 4971 Ref: x-x-vxworks179706 4972 Ref: x86-64-x-x181229 4973 Ref: x86-64-x-solaris2181557 4974 Ref: xtensa-x-elf182207 4975 Ref: xtensa-x-linux182878 4976 Ref: windows183219 4977 Ref: x-x-cygwin185015 4978 Ref: x-x-mingw32185568 4979 Ref: older185950 4980 Ref: elf188067 4981 Node: GNU Free Documentation License188325 4982 Node: Concept Index213460 4983 4984 End Tag Table 4985