[673b0d8] | 1 | <?xml version="1.0" encoding="ISO-8859-1"?>
|
---|
[b06ca36] | 2 | <!DOCTYPE sect1 PUBLIC "-//OASIS//DTD DocBook XML V4.5//EN"
|
---|
| 3 | "http://www.oasis-open.org/docbook/xml/4.5/docbookx.dtd" [
|
---|
[673b0d8] | 4 | <!ENTITY % general-entities SYSTEM "../general.ent">
|
---|
| 5 | %general-entities;
|
---|
| 6 | ]>
|
---|
[6a82dd9] | 7 |
|
---|
[81fd230] | 8 | <sect1 id="ch-system-gcc" role="wrap">
|
---|
[6a82dd9] | 9 | <?dbhtml filename="gcc.html"?>
|
---|
| 10 |
|
---|
[e747759] | 11 | <sect1info condition="script">
|
---|
| 12 | <productname>gcc</productname>
|
---|
| 13 | <productnumber>&gcc-version;</productnumber>
|
---|
| 14 | <address>&gcc-url;</address>
|
---|
| 15 | </sect1info>
|
---|
| 16 |
|
---|
[6a82dd9] | 17 | <title>GCC-&gcc-version;</title>
|
---|
| 18 |
|
---|
| 19 | <indexterm zone="ch-system-gcc">
|
---|
| 20 | <primary sortas="a-GCC">GCC</primary>
|
---|
| 21 | </indexterm>
|
---|
| 22 |
|
---|
| 23 | <sect2 role="package">
|
---|
| 24 | <title/>
|
---|
[6370fa6] | 25 |
|
---|
[6a82dd9] | 26 | <para>The GCC package contains the GNU compiler collection, which includes
|
---|
| 27 | the C and C++ compilers.</para>
|
---|
[673b0d8] | 28 |
|
---|
[6a82dd9] | 29 | <segmentedlist>
|
---|
| 30 | <segtitle>&buildtime;</segtitle>
|
---|
| 31 | <segtitle>&diskspace;</segtitle>
|
---|
[5888299] | 32 |
|
---|
[6a82dd9] | 33 | <seglistitem>
|
---|
[fb386e0] | 34 | <seg>&gcc-fin-sbu;</seg>
|
---|
| 35 | <seg>&gcc-fin-du;</seg>
|
---|
[6a82dd9] | 36 | </seglistitem>
|
---|
| 37 | </segmentedlist>
|
---|
[3554fa3a] | 38 |
|
---|
[6a82dd9] | 39 | </sect2>
|
---|
| 40 |
|
---|
| 41 | <sect2 role="installation">
|
---|
| 42 | <title>Installation of GCC</title>
|
---|
[f333d75] | 43 | <!--
|
---|
[a04b3d39] | 44 | <para>At first, fix an issue breaking
|
---|
| 45 | <filename class="libraryfile">libasan.a</filename> building this package
|
---|
[51e4ab2] | 46 | with Glibc-2.34 or later:</para>
|
---|
[a04b3d39] | 47 |
|
---|
| 48 | <screen><userinput remap="pre">sed -e '/static.*SIGSTKSZ/d' \
|
---|
| 49 | -e 's/return kAltStackSize/return SIGSTKSZ * 4/' \
|
---|
| 50 | -i libsanitizer/sanitizer_common/sanitizer_posix_libcdep.cpp</userinput></screen>
|
---|
[f333d75] | 51 | -->
|
---|
[460f575] | 52 | <para>If building on aarch64, change the default directory name for 64-bit
|
---|
[be3d9f3] | 53 | libraries to <quote>lib</quote>:</para>
|
---|
| 54 |
|
---|
| 55 | <screen><userinput remap="pre">case $(uname -m) in
|
---|
[460f575] | 56 | aarch64)
|
---|
| 57 | sed -e '/mabi.lp64=/s/lib64/lib/' \
|
---|
| 58 | -i.orig gcc/config/aarch64/t-aarch64-linux
|
---|
[be3d9f3] | 59 | ;;
|
---|
| 60 | esac</userinput></screen>
|
---|
| 61 |
|
---|
[f1dd547] | 62 | <para>The GCC documentation recommends building GCC in a dedicated build directory:</para>
|
---|
[73aedd1d] | 63 |
|
---|
[f1dd547] | 64 | <screen><userinput remap="pre">mkdir -v build
|
---|
| 65 | cd build</userinput></screen>
|
---|
[73aedd1d] | 66 |
|
---|
[6a82dd9] | 67 | <para>Prepare GCC for compilation:</para>
|
---|
[73aedd1d] | 68 |
|
---|
[efcb393] | 69 | <screen><userinput remap="configure">../configure --prefix=/usr \
|
---|
| 70 | LD=ld \
|
---|
[f1dd547] | 71 | --enable-languages=c,c++ \
|
---|
| 72 | --disable-multilib \
|
---|
| 73 | --disable-bootstrap \
|
---|
| 74 | --with-system-zlib</userinput></screen>
|
---|
[73aedd1d] | 75 |
|
---|
[6a156bab] | 76 | <para>Note that for other programming languages there are some prerequisites that
|
---|
[93756f6] | 77 | are not yet available. See the
|
---|
[6a156bab] | 78 | <ulink url="&blfs-book;general/gcc.html">BLFS Book GCC page</ulink>
|
---|
[93756f6] | 79 | for instructions on how to build all of GCC's supported languages.</para>
|
---|
[182d5d3] | 80 |
|
---|
[ae4d45a] | 81 | <variablelist>
|
---|
[a89ab79] | 82 | <title>The meaning of the new configure parameters:</title>
|
---|
| 83 |
|
---|
| 84 | <varlistentry>
|
---|
| 85 | <term><parameter>LD=ld</parameter></term>
|
---|
| 86 | <listitem>
|
---|
| 87 | <para>This parameter makes the configure script use the ld installed
|
---|
[6a156bab] | 88 | by the binutils built earlier in this chapter, rather than
|
---|
[a89ab79] | 89 | the cross-built version which would otherwise be used.</para>
|
---|
| 90 | </listitem>
|
---|
| 91 | </varlistentry>
|
---|
[cde2ae7] | 92 |
|
---|
[ae4d45a] | 93 | <varlistentry>
|
---|
| 94 | <term><parameter>--with-system-zlib</parameter></term>
|
---|
| 95 | <listitem>
|
---|
| 96 | <para>This switch tells GCC to link to the system installed copy of
|
---|
[6a156bab] | 97 | the zlib library, rather than its own internal copy.</para>
|
---|
[ae4d45a] | 98 | </listitem>
|
---|
| 99 | </varlistentry>
|
---|
| 100 | </variablelist>
|
---|
| 101 |
|
---|
[6a82dd9] | 102 | <para>Compile the package:</para>
|
---|
[73aedd1d] | 103 |
|
---|
[0445a3d] | 104 | <screen><userinput remap="make">make</userinput></screen>
|
---|
[73aedd1d] | 105 |
|
---|
[6a82dd9] | 106 | <important>
|
---|
| 107 | <para>In this section, the test suite for GCC is considered
|
---|
[1f201845] | 108 | important, but it takes a long time. First time builders are
|
---|
| 109 | encouraged to not skip it. The time to run the tests can be
|
---|
| 110 | reduced significantly by adding -jx to the make command below
|
---|
| 111 | where x is the number of cores on your system.</para>
|
---|
[6a82dd9] | 112 | </important>
|
---|
[81fd230] | 113 |
|
---|
[6a156bab] | 114 | <para>One set of tests in the GCC test suite is known to exhaust the default
|
---|
| 115 | stack, so increase the stack size prior to running the tests:</para>
|
---|
[4e48f56e] | 116 |
|
---|
[2efa44a] | 117 | <screen><userinput remap="test">ulimit -s 32768</userinput></screen>
|
---|
[4e48f56e] | 118 |
|
---|
[76db8d6] | 119 | <para>Test the results as a non-privileged user, but do not stop at errors:</para>
|
---|
| 120 |
|
---|
[d672ab7] | 121 | <screen><userinput remap="test">chown -Rv tester .
|
---|
[ae7f075] | 122 | su tester -c "PATH=$PATH make -k check"</userinput></screen>
|
---|
[73aedd1d] | 123 |
|
---|
[9278974d] | 124 | <para>To receive a summary of the test suite results, run:</para>
|
---|
| 125 |
|
---|
[f1dd547] | 126 | <screen><userinput remap="test">../contrib/test_summary</userinput></screen>
|
---|
[9278974d] | 127 |
|
---|
| 128 | <para>For only the summaries, pipe the output through
|
---|
| 129 | <userinput>grep -A7 Summ</userinput>.</para>
|
---|
| 130 |
|
---|
| 131 | <para>Results can be compared with those located at <ulink
|
---|
[98e7ac4] | 132 | url="&test-results;"/> and
|
---|
[b30de8f] | 133 | <ulink url="https://gcc.gnu.org/ml/gcc-testresults/"/>.</para>
|
---|
[9278974d] | 134 |
|
---|
[0567d85] | 135 | <para>In g++, four tests related to PR100400 are known to be reported
|
---|
| 136 | as both XPASS and FAIL. It's because the test file for this known issue
|
---|
| 137 | is not well written.</para>
|
---|
[d7a9421] | 138 |
|
---|
[9278974d] | 139 | <para>A few unexpected failures cannot always be avoided. The GCC developers
|
---|
[0238d49] | 140 | are usually aware of these issues, but have not resolved them yet.
|
---|
[9278974d] | 141 | Unless the test results are vastly different from those at the above URL,
|
---|
| 142 | it is safe to continue.</para>
|
---|
[73aedd1d] | 143 |
|
---|
[ac95fdb] | 144 | <!--note><para>
|
---|
[e3e989a] | 145 | On some combinations of kernel configuration and AMD processors
|
---|
| 146 | there may be more than 1100 failures in the gcc.target/i386/mpx
|
---|
| 147 | tests (which are designed to test the MPX option on recent
|
---|
| 148 | Intel processors). These can safely be ignored on AMD
|
---|
[1c8cc71] | 149 | processors. These tests will also fail on Intel processors if MPX support
|
---|
| 150 | is not enabled in the kernel even though it is present on the CPU.
|
---|
[ac95fdb] | 151 | </para></note-->
|
---|
[e3e989a] | 152 |
|
---|
[753d2cd] | 153 | <para>Install the package:</para>
|
---|
[73aedd1d] | 154 |
|
---|
[753d2cd] | 155 | <screen><userinput remap="install">make install</userinput></screen>
|
---|
[73aedd1d] | 156 |
|
---|
[e6db175] | 157 | <para>The GCC build directory is owned by <systemitem class="username">
|
---|
[ae7f075] | 158 | tester</systemitem> now and the ownership of the installed header
|
---|
[bf0ad1a] | 159 | directory (and its content) will be incorrect. Change the ownership to
|
---|
[e6db175] | 160 | <systemitem class="username">root</systemitem> user and group:</para>
|
---|
| 161 |
|
---|
| 162 | <screen><userinput remap="install">chown -v -R root:root \
|
---|
[9a43c25] | 163 | /usr/lib/gcc/$(gcc -dumpmachine)/&gcc-version;/include{,-fixed}</userinput></screen>
|
---|
[e6db175] | 164 |
|
---|
[60b23a6f] | 165 | <para>Create a symlink required by the <ulink
|
---|
[b30de8f] | 166 | url="https://refspecs.linuxfoundation.org/FHS_3.0/fhs/ch03s09.html">FHS</ulink>
|
---|
[60b23a6f] | 167 | for "historical" reasons.</para>
|
---|
[73aedd1d] | 168 |
|
---|
[9c3ce2a] | 169 | <screen><userinput remap="install">ln -svr /usr/bin/cpp /usr/lib</userinput></screen>
|
---|
[efcb393] | 170 | <!-- already done earlier
|
---|
[6a82dd9] | 171 | <para>Many packages use the name <command>cc</command> to call the C
|
---|
| 172 | compiler. To satisfy those packages, create a symlink:</para>
|
---|
[1ba726f] | 173 |
|
---|
[0445a3d] | 174 | <screen><userinput remap="install">ln -sv gcc /usr/bin/cc</userinput></screen>
|
---|
[efcb393] | 175 | -->
|
---|
[6206f72] | 176 | <para>Add a compatibility symlink to enable building programs with
|
---|
[d672ab7] | 177 | Link Time Optimization (LTO):</para>
|
---|
[6206f72] | 178 |
|
---|
[f36db31] | 179 | <screen><userinput remap="install">ln -sfv ../../libexec/gcc/$(gcc -dumpmachine)/&gcc-version;/liblto_plugin.so \
|
---|
[040ecb6] | 180 | /usr/lib/bfd-plugins/</userinput></screen>
|
---|
[6206f72] | 181 |
|
---|
[09f1daf] | 182 | <para>Now that our final toolchain is in place, it is important to again ensure
|
---|
| 183 | that compiling and linking will work as expected. We do this by performing
|
---|
[6a156bab] | 184 | some sanity checks:</para>
|
---|
[09f1daf] | 185 |
|
---|
[a3f7b43] | 186 | <screen><userinput>echo 'int main(){}' > dummy.c
|
---|
| 187 | cc dummy.c -v -Wl,--verbose &> dummy.log
|
---|
| 188 | readelf -l a.out | grep ': /lib'</userinput></screen>
|
---|
[09f1daf] | 189 |
|
---|
[a3f7b43] | 190 | <para>There should be no errors,
|
---|
| 191 | and the output of the last command will be (allowing for
|
---|
| 192 | platform-specific differences in the dynamic linker name):</para>
|
---|
[09f1daf] | 193 |
|
---|
[426a539] | 194 | <screen><computeroutput>[Requesting program interpreter: /lib64/ld-linux-aarch64.so.1]</computeroutput></screen>
|
---|
[09f1daf] | 195 |
|
---|
[a3f7b43] | 196 | <para>Now make sure that we're setup to use the correct start files:</para>
|
---|
[09f1daf] | 197 |
|
---|
[a3f7b43] | 198 | <screen><userinput>grep -o '/usr/lib.*/crt[1in].*succeeded' dummy.log</userinput></screen>
|
---|
[09f1daf] | 199 |
|
---|
[a3f7b43] | 200 | <para>The output of the last command should be:</para>
|
---|
[09f1daf] | 201 |
|
---|
[460f575] | 202 | <screen><computeroutput>/usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/crt1.o succeeded
|
---|
| 203 | /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/crti.o succeeded
|
---|
| 204 | /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/../../../../lib/crtn.o succeeded</computeroutput></screen>
|
---|
[09f1daf] | 205 |
|
---|
[6a156bab] | 206 | <para>Depending on your machine architecture, the above may differ slightly.
|
---|
| 207 | The difference will be the name of the directory
|
---|
[be3d9f3] | 208 | after <filename class="directory">/usr/lib/gcc</filename>. The important
|
---|
| 209 | thing to look for here is that <command>gcc</command> has found all three
|
---|
[5f7456b] | 210 | <filename>crt*.o</filename> files under the
|
---|
| 211 | <filename class="directory">/usr/lib</filename> directory.</para>
|
---|
[6e88633] | 212 |
|
---|
[a3f7b43] | 213 | <para>Verify that the compiler is searching for the correct header
|
---|
| 214 | files:</para>
|
---|
[09f1daf] | 215 |
|
---|
[041c8f67] | 216 | <screen><userinput>grep -B4 '^ /usr/include' dummy.log</userinput></screen>
|
---|
[e9a652b] | 217 |
|
---|
[a3f7b43] | 218 | <para>This command should return the following output:</para>
|
---|
[09f1daf] | 219 |
|
---|
[e9a652b] | 220 | <screen><computeroutput>#include <...> search starts here:
|
---|
[426a539] | 221 | /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/include
|
---|
[c528e3a] | 222 | /usr/local/include
|
---|
[460f575] | 223 | /usr/lib/gcc/aarch64-unknown-linux-gnu/&gcc-version;/include-fixed
|
---|
[e9a652b] | 224 | /usr/include</computeroutput></screen>
|
---|
| 225 |
|
---|
[6a156bab] | 226 | <para>Again, the directory named after your target triplet may be
|
---|
| 227 | different than the above, depending on your system architecture.</para>
|
---|
[3f39abf3] | 228 |
|
---|
[a3f7b43] | 229 | <para>Next, verify that the new linker is being used with the correct search paths:</para>
|
---|
[09f1daf] | 230 |
|
---|
[a3f7b43] | 231 | <screen><userinput>grep 'SEARCH.*/usr/lib' dummy.log |sed 's|; |\n|g'</userinput></screen>
|
---|
[09f1daf] | 232 |
|
---|
[a3f7b43] | 233 | <para>References to paths that have components with '-linux-gnu' should
|
---|
| 234 | be ignored, but otherwise the output of the last command should be:</para>
|
---|
[09f1daf] | 235 |
|
---|
[460f575] | 236 | <screen><computeroutput>SEARCH_DIR("/usr/aarch64-unknown-linux-gnu/lib64")
|
---|
[98e7ac4] | 237 | SEARCH_DIR("/usr/local/lib64")
|
---|
| 238 | SEARCH_DIR("/lib64")
|
---|
| 239 | SEARCH_DIR("/usr/lib64")
|
---|
[460f575] | 240 | SEARCH_DIR("/usr/aarch64-unknown-linux-gnu/lib")
|
---|
[e9a652b] | 241 | SEARCH_DIR("/usr/local/lib")
|
---|
| 242 | SEARCH_DIR("/lib")
|
---|
[6e88633] | 243 | SEARCH_DIR("/usr/lib");</computeroutput></screen>
|
---|
| 244 |
|
---|
[98e7ac4] | 245 | <para>A 32-bit system may see a few different directories. For example, here
|
---|
[460f575] | 246 | is the output from a 32bit ARM machine:</para>
|
---|
[6e88633] | 247 |
|
---|
[460f575] | 248 | <screen><computeroutput>SEARCH_DIR("/usr/armv6l-unknown-linux-gnueabihf/lib")
|
---|
[6e88633] | 249 | SEARCH_DIR("/usr/local/lib")
|
---|
| 250 | SEARCH_DIR("/lib")
|
---|
[e9a652b] | 251 | SEARCH_DIR("/usr/lib");</computeroutput></screen>
|
---|
| 252 |
|
---|
[a3f7b43] | 253 | <para>Next make sure that we're using the correct libc:</para>
|
---|
[09f1daf] | 254 |
|
---|
[a3f7b43] | 255 | <screen><userinput>grep "/lib.*/libc.so.6 " dummy.log</userinput></screen>
|
---|
[09f1daf] | 256 |
|
---|
[a3f7b43] | 257 | <para>The output of the last command should be:</para>
|
---|
[09f1daf] | 258 |
|
---|
[a3f7b43] | 259 | <screen><computeroutput>attempt to open /usr/lib/libc.so.6 succeeded</computeroutput></screen>
|
---|
[09f1daf] | 260 |
|
---|
[a3f7b43] | 261 | <para>Make sure GCC is using the correct dynamic linker:</para>
|
---|
[09f1daf] | 262 |
|
---|
[a3f7b43] | 263 | <screen><userinput>grep found dummy.log</userinput></screen>
|
---|
[09f1daf] | 264 |
|
---|
[a3f7b43] | 265 | <para>The output of the last command should be (allowing for
|
---|
| 266 | platform-specific differences in dynamic linker name):</para>
|
---|
[09f1daf] | 267 |
|
---|
[426a539] | 268 | <screen><computeroutput>found ld-linux-aarch64.so.1 at /usr/lib/ld-linux-aarch64.so.1</computeroutput></screen>
|
---|
[09f1daf] | 269 |
|
---|
[a3f7b43] | 270 | <para>If the output does not appear as shown above or is not received
|
---|
| 271 | at all, then something is seriously wrong. Investigate and retrace the
|
---|
| 272 | steps to find out where the problem is and correct it. <!--The most likely
|
---|
| 273 | reason is that something went wrong with the specs file adjustment.--> Any
|
---|
| 274 | issues will need to be resolved before continuing with the process.</para>
|
---|
[6a82dd9] | 275 |
|
---|
[a3f7b43] | 276 | <para>Once everything is working correctly, clean up the test files:</para>
|
---|
[e9a652b] | 277 |
|
---|
[a3f7b43] | 278 | <screen><userinput>rm -v dummy.c a.out dummy.log</userinput></screen>
|
---|
[e9a652b] | 279 |
|
---|
[970a126] | 280 | <para>Finally, move a misplaced file:</para>
|
---|
[39ec01c] | 281 |
|
---|
[970a126] | 282 | <screen><userinput remap="install">mkdir -pv /usr/share/gdb/auto-load/usr/lib
|
---|
| 283 | mv -v /usr/lib/*gdb.py /usr/share/gdb/auto-load/usr/lib</userinput></screen>
|
---|
[39ec01c] | 284 |
|
---|
[6a82dd9] | 285 | </sect2>
|
---|
| 286 |
|
---|
| 287 | <sect2 id="contents-gcc" role="content">
|
---|
| 288 | <title>Contents of GCC</title>
|
---|
| 289 |
|
---|
| 290 | <segmentedlist>
|
---|
| 291 | <segtitle>Installed programs</segtitle>
|
---|
| 292 | <segtitle>Installed libraries</segtitle>
|
---|
[fe05b08] | 293 | <segtitle>Installed directories</segtitle>
|
---|
[6a82dd9] | 294 |
|
---|
| 295 | <seglistitem>
|
---|
[2ca8941] | 296 | <seg>c++, cc (link to gcc), cpp, g++, gcc,
|
---|
[e5b4b3f] | 297 | gcc-ar, gcc-nm, gcc-ranlib, gcov, gcov-dump, gcov-tool,
|
---|
| 298 | and lto-dump</seg>
|
---|
[e0901b3] | 299 |
|
---|
[78cc3be] | 300 | <seg>libasan.{a,so}, libatomic.{a,so}, libcc1.so, libgcc.a, libgcc_eh.a,
|
---|
| 301 | libgcc_s.so, libgcov.a, libgomp.{a,so}, libitm.{a,so},
|
---|
| 302 | liblsan.{a,so}, liblto_plugin.so,
|
---|
[460f575] | 303 | libssp.{a,so}, libssp_nonshared.a,
|
---|
[78cc3be] | 304 | libstdc++.{a,so}, libstdc++fs.a, libsupc++.a, libtsan.{a,so},
|
---|
| 305 | and libubsan.{a,so}</seg>
|
---|
[2ca8941] | 306 |
|
---|
[d672ab7] | 307 | <seg>/usr/include/c++, /usr/lib/gcc, /usr/libexec/gcc, and
|
---|
[4e8a532] | 308 | /usr/share/gcc-&gcc-version;</seg>
|
---|
[6a82dd9] | 309 | </seglistitem>
|
---|
| 310 | </segmentedlist>
|
---|
| 311 |
|
---|
| 312 | <variablelist>
|
---|
| 313 | <bridgehead renderas="sect3">Short Descriptions</bridgehead>
|
---|
| 314 | <?dbfo list-presentation="list"?>
|
---|
| 315 | <?dbhtml list-presentation="table"?>
|
---|
| 316 |
|
---|
[75128571] | 317 | <varlistentry id="c">
|
---|
| 318 | <term><command>c++</command></term>
|
---|
| 319 | <listitem>
|
---|
| 320 | <para>The C++ compiler</para>
|
---|
| 321 | <indexterm zone="ch-system-gcc c">
|
---|
| 322 | <primary sortas="b-c++">c++</primary>
|
---|
| 323 | </indexterm>
|
---|
| 324 | </listitem>
|
---|
| 325 | </varlistentry>
|
---|
| 326 |
|
---|
[6a82dd9] | 327 | <varlistentry id="cc">
|
---|
| 328 | <term><command>cc</command></term>
|
---|
| 329 | <listitem>
|
---|
| 330 | <para>The C compiler</para>
|
---|
| 331 | <indexterm zone="ch-system-gcc cc">
|
---|
| 332 | <primary sortas="b-cc">cc</primary>
|
---|
| 333 | </indexterm>
|
---|
| 334 | </listitem>
|
---|
| 335 | </varlistentry>
|
---|
| 336 |
|
---|
| 337 | <varlistentry id="cpp">
|
---|
| 338 | <term><command>cpp</command></term>
|
---|
| 339 | <listitem>
|
---|
| 340 | <para>The C preprocessor; it is used by the compiler to expand the
|
---|
| 341 | #include, #define, and similar statements in the source files</para>
|
---|
| 342 | <indexterm zone="ch-system-gcc cpp">
|
---|
| 343 | <primary sortas="b-cpp">cpp</primary>
|
---|
| 344 | </indexterm>
|
---|
| 345 | </listitem>
|
---|
| 346 | </varlistentry>
|
---|
| 347 |
|
---|
| 348 | <varlistentry id="g">
|
---|
| 349 | <term><command>g++</command></term>
|
---|
| 350 | <listitem>
|
---|
| 351 | <para>The C++ compiler</para>
|
---|
| 352 | <indexterm zone="ch-system-gcc g">
|
---|
| 353 | <primary sortas="b-g++">g++</primary>
|
---|
| 354 | </indexterm>
|
---|
| 355 | </listitem>
|
---|
| 356 | </varlistentry>
|
---|
| 357 |
|
---|
| 358 | <varlistentry id="gcc">
|
---|
| 359 | <term><command>gcc</command></term>
|
---|
| 360 | <listitem>
|
---|
| 361 | <para>The C compiler</para>
|
---|
| 362 | <indexterm zone="ch-system-gcc gcc">
|
---|
| 363 | <primary sortas="b-gcc">gcc</primary>
|
---|
| 364 | </indexterm>
|
---|
| 365 | </listitem>
|
---|
| 366 | </varlistentry>
|
---|
| 367 |
|
---|
[e0901b3] | 368 | <varlistentry id="gcc-ar">
|
---|
| 369 | <term><command>gcc-ar</command></term>
|
---|
| 370 | <listitem>
|
---|
| 371 | <para>A wrapper around <command>ar</command> that adds a
|
---|
[afba93b] | 372 | plugin to the command line. This program is only used
|
---|
[edbeeb5] | 373 | to add "link time optimization" and is not useful with the
|
---|
[afba93b] | 374 | default build options</para>
|
---|
[e0901b3] | 375 | <indexterm zone="ch-system-gcc gcc-ar">
|
---|
| 376 | <primary sortas="b-gcc-ar">gc-ar</primary>
|
---|
| 377 | </indexterm>
|
---|
| 378 | </listitem>
|
---|
| 379 | </varlistentry>
|
---|
| 380 |
|
---|
| 381 | <varlistentry id="gcc-nm">
|
---|
| 382 | <term><command>gcc-nm</command></term>
|
---|
| 383 | <listitem>
|
---|
| 384 | <para>A wrapper around <command>nm</command> that adds a
|
---|
[afba93b] | 385 | plugin to the command line. This program is only used
|
---|
[a885478] | 386 | to add "link time optimization" and is not useful with the
|
---|
[afba93b] | 387 | default build options</para>
|
---|
[e0901b3] | 388 | <indexterm zone="ch-system-gcc gcc-nm">
|
---|
| 389 | <primary sortas="b-gcc-nm">gc-nm</primary>
|
---|
| 390 | </indexterm>
|
---|
| 391 | </listitem>
|
---|
| 392 | </varlistentry>
|
---|
| 393 |
|
---|
| 394 | <varlistentry id="gcc-ranlib">
|
---|
| 395 | <term><command>gcc-ranlib</command></term>
|
---|
| 396 | <listitem>
|
---|
| 397 | <para>A wrapper around <command>ranlib</command> that adds a
|
---|
[afba93b] | 398 | plugin to the command line. This program is only used
|
---|
[a885478] | 399 | to add "link time optimization" and is not useful with the
|
---|
[afba93b] | 400 | default build options</para>
|
---|
[e0901b3] | 401 | <indexterm zone="ch-system-gcc gcc-ranlib">
|
---|
| 402 | <primary sortas="b-gcc-ranlib">gc-ranlib</primary>
|
---|
| 403 | </indexterm>
|
---|
| 404 | </listitem>
|
---|
| 405 | </varlistentry>
|
---|
[6a82dd9] | 406 |
|
---|
| 407 | <varlistentry id="gcov">
|
---|
| 408 | <term><command>gcov</command></term>
|
---|
| 409 | <listitem>
|
---|
| 410 | <para>A coverage testing tool; it is used to analyze programs to
|
---|
| 411 | determine where optimizations will have the most effect</para>
|
---|
| 412 | <indexterm zone="ch-system-gcc gcov">
|
---|
| 413 | <primary sortas="b-gcov">gcov</primary>
|
---|
| 414 | </indexterm>
|
---|
[4783efe] | 415 | </listitem>
|
---|
| 416 | </varlistentry>
|
---|
| 417 |
|
---|
[78cc3be] | 418 | <varlistentry id="gcov-dump">
|
---|
| 419 | <term><command>gcov-dump</command></term>
|
---|
| 420 | <listitem>
|
---|
| 421 | <para>Offline gcda and gcno profile dump tool</para>
|
---|
| 422 | <indexterm zone="ch-system-gcc gcov-dump">
|
---|
| 423 | <primary sortas="b-gcov-dump">gcov-dump</primary>
|
---|
| 424 | </indexterm>
|
---|
| 425 | </listitem>
|
---|
| 426 | </varlistentry>
|
---|
| 427 |
|
---|
| 428 | <varlistentry id="gcov-tool">
|
---|
| 429 | <term><command>gcov-tool</command></term>
|
---|
| 430 | <listitem>
|
---|
| 431 | <para>Offline gcda profile processing tool</para>
|
---|
| 432 | <indexterm zone="ch-system-gcc gcov-tool">
|
---|
| 433 | <primary sortas="b-gcov-tool">gcov-tool</primary>
|
---|
| 434 | </indexterm>
|
---|
| 435 | </listitem>
|
---|
| 436 | </varlistentry>
|
---|
| 437 |
|
---|
[e5b4b3f] | 438 | <varlistentry id="lto-dump">
|
---|
| 439 | <term><command>lto-dump</command></term>
|
---|
| 440 | <listitem>
|
---|
| 441 | <para>Tool for dumping object files produced by GCC with LTO
|
---|
| 442 | enabled</para>
|
---|
| 443 | <indexterm zone="ch-system-gcc lto-dump">
|
---|
| 444 | <primary sortas="b-lto-dump">lto-dump</primary>
|
---|
| 445 | </indexterm>
|
---|
| 446 | </listitem>
|
---|
| 447 | </varlistentry>
|
---|
| 448 |
|
---|
[4783efe] | 449 | <varlistentry id="libasan">
|
---|
[78cc3be] | 450 | <term><filename class="libraryfile">libasan</filename></term>
|
---|
[4783efe] | 451 | <listitem>
|
---|
| 452 | <para>The Address Sanitizer runtime library</para>
|
---|
| 453 | <indexterm zone="ch-system-gcc libasan">
|
---|
| 454 | <primary sortas="b-libasan">libasan</primary>
|
---|
| 455 | </indexterm>
|
---|
[6a82dd9] | 456 | </listitem>
|
---|
| 457 | </varlistentry>
|
---|
| 458 |
|
---|
[78cc3be] | 459 | <varlistentry id="libatomic">
|
---|
| 460 | <term><filename class="libraryfile">libatomic</filename></term>
|
---|
| 461 | <listitem>
|
---|
| 462 | <para>GCC atomic built-in runtime library</para>
|
---|
| 463 | <indexterm zone="ch-system-gcc libatomic">
|
---|
| 464 | <primary sortas="b-libatomic">libatomic</primary>
|
---|
| 465 | </indexterm>
|
---|
| 466 | </listitem>
|
---|
| 467 | </varlistentry>
|
---|
| 468 |
|
---|
| 469 | <varlistentry id="libcc1">
|
---|
| 470 | <term><filename class="libraryfile">libcc1</filename></term>
|
---|
| 471 | <listitem>
|
---|
| 472 | <para>The C preprocessing library</para>
|
---|
| 473 | <indexterm zone="ch-system-gcc libcc1">
|
---|
| 474 | <primary sortas="b-libcc1">libcc1</primary>
|
---|
| 475 | </indexterm>
|
---|
| 476 | </listitem>
|
---|
| 477 | </varlistentry>
|
---|
| 478 |
|
---|
[6a82dd9] | 479 | <varlistentry id="libgcc">
|
---|
| 480 | <term><filename class="libraryfile">libgcc</filename></term>
|
---|
| 481 | <listitem>
|
---|
| 482 | <para>Contains run-time support for <command>gcc</command></para>
|
---|
| 483 | <indexterm zone="ch-system-gcc libgcc">
|
---|
[afba93b] | 484 | <primary sortas="c-libgcc">libgcc</primary>
|
---|
[6a82dd9] | 485 | </indexterm>
|
---|
| 486 | </listitem>
|
---|
| 487 | </varlistentry>
|
---|
| 488 |
|
---|
[90aae6b] | 489 | <varlistentry id="libgcov">
|
---|
| 490 | <term><filename class="libraryfile">libgcov</filename></term>
|
---|
| 491 | <listitem>
|
---|
| 492 | <para>This library is linked in to a program when GCC is instructed
|
---|
| 493 | to enable profiling</para>
|
---|
| 494 | <indexterm zone="ch-system-gcc libgcov">
|
---|
| 495 | <primary sortas="c-libgcov">libgcov</primary>
|
---|
| 496 | </indexterm>
|
---|
| 497 | </listitem>
|
---|
| 498 | </varlistentry>
|
---|
| 499 |
|
---|
| 500 | <varlistentry id="libgomp">
|
---|
| 501 | <term><filename class="libraryfile">libgomp</filename></term>
|
---|
| 502 | <listitem>
|
---|
| 503 | <para>GNU implementation of the OpenMP API for multi-platform
|
---|
| 504 | shared-memory parallel programming in C/C++ and Fortran</para>
|
---|
| 505 | <indexterm zone="ch-system-gcc libgomp">
|
---|
| 506 | <primary sortas="c-libgomp">libgomp</primary>
|
---|
| 507 | </indexterm>
|
---|
| 508 | </listitem>
|
---|
| 509 | </varlistentry>
|
---|
| 510 |
|
---|
[e5b4b3f] | 511 | <varlistentry id="libitm">
|
---|
| 512 | <term><filename class="libraryfile">libitm</filename></term>
|
---|
| 513 | <listitem>
|
---|
| 514 | <para>The GNU transactional memory library</para>
|
---|
| 515 | <indexterm zone="ch-system-gcc libitm">
|
---|
| 516 | <primary sortas="c-libitm">libitm</primary>
|
---|
| 517 | </indexterm>
|
---|
| 518 | </listitem>
|
---|
| 519 | </varlistentry>
|
---|
| 520 |
|
---|
[78cc3be] | 521 | <varlistentry id="liblsan">
|
---|
| 522 | <term><filename class="libraryfile">liblsan</filename></term>
|
---|
[b755562] | 523 | <listitem>
|
---|
[78cc3be] | 524 | <para>The Leak Sanitizer runtime library</para>
|
---|
| 525 | <indexterm zone="ch-system-gcc liblsan">
|
---|
| 526 | <primary sortas="c-liblsan">liblsan</primary>
|
---|
[b755562] | 527 | </indexterm>
|
---|
| 528 | </listitem>
|
---|
| 529 | </varlistentry>
|
---|
| 530 |
|
---|
[3119ddc] | 531 | <varlistentry id="liblto_plugin">
|
---|
| 532 | <term><filename class="libraryfile">liblto_plugin</filename></term>
|
---|
| 533 | <listitem>
|
---|
[e5b4b3f] | 534 | <para>GCC's LTO plugin allows binutils to process object files
|
---|
| 535 | produced by GCC with LTO enabled</para>
|
---|
[3119ddc] | 536 | <indexterm zone="ch-system-gcc liblto_plugin">
|
---|
[afba93b] | 537 | <primary sortas="c-liblto_plugin">liblto_plugin</primary>
|
---|
[3119ddc] | 538 | </indexterm>
|
---|
| 539 | </listitem>
|
---|
| 540 | </varlistentry>
|
---|
[7bb9fda] | 541 |
|
---|
[3119ddc] | 542 | <varlistentry id="libquadmath">
|
---|
| 543 | <term><filename class="libraryfile">libquadmath</filename></term>
|
---|
| 544 | <listitem>
|
---|
| 545 | <para>GCC Quad Precision Math Library API</para>
|
---|
| 546 | <indexterm zone="ch-system-gcc libquadmath">
|
---|
[afba93b] | 547 | <primary sortas="c-libquadmath">libquadmath</primary>
|
---|
[3119ddc] | 548 | </indexterm>
|
---|
| 549 | </listitem>
|
---|
| 550 | </varlistentry>
|
---|
| 551 |
|
---|
[2791a8e] | 552 | <varlistentry id="libssp">
|
---|
| 553 | <term><filename class="libraryfile">libssp</filename></term>
|
---|
| 554 | <listitem>
|
---|
| 555 | <para>Contains routines supporting GCC's stack-smashing protection
|
---|
| 556 | functionality</para>
|
---|
| 557 | <indexterm zone="ch-system-gcc libssp">
|
---|
[afba93b] | 558 | <primary sortas="c-libssp">libssp</primary>
|
---|
[2791a8e] | 559 | </indexterm>
|
---|
| 560 | </listitem>
|
---|
| 561 | </varlistentry>
|
---|
| 562 |
|
---|
[6a82dd9] | 563 | <varlistentry id="libstdc">
|
---|
| 564 | <term><filename class="libraryfile">libstdc++</filename></term>
|
---|
| 565 | <listitem>
|
---|
| 566 | <para>The standard C++ library</para>
|
---|
| 567 | <indexterm zone="ch-system-gcc libstdc">
|
---|
| 568 | <primary sortas="c-libstdc++">libstdc++</primary>
|
---|
| 569 | </indexterm>
|
---|
| 570 | </listitem>
|
---|
| 571 | </varlistentry>
|
---|
| 572 |
|
---|
[78cc3be] | 573 | <varlistentry id="libstdcfs">
|
---|
| 574 | <term><filename class="libraryfile">libstdc++fs</filename></term>
|
---|
| 575 | <listitem>
|
---|
| 576 | <para>ISO/IEC TS 18822:2015 Filesystem library</para>
|
---|
| 577 | <indexterm zone="ch-system-gcc libstdcfs">
|
---|
| 578 | <primary sortas="c-libstdc++fs">libstdc++fs</primary>
|
---|
| 579 | </indexterm>
|
---|
| 580 | </listitem>
|
---|
| 581 | </varlistentry>
|
---|
| 582 |
|
---|
[6a82dd9] | 583 | <varlistentry id="libsupc">
|
---|
| 584 | <term><filename class="libraryfile">libsupc++</filename></term>
|
---|
| 585 | <listitem>
|
---|
| 586 | <para>Provides supporting routines for the C++ programming
|
---|
| 587 | language</para>
|
---|
| 588 | <indexterm zone="ch-system-gcc libsupc">
|
---|
| 589 | <primary sortas="c-libsupc++">libsupc++</primary>
|
---|
| 590 | </indexterm>
|
---|
| 591 | </listitem>
|
---|
| 592 | </varlistentry>
|
---|
| 593 |
|
---|
[f6b1d91] | 594 | <varlistentry id="libtsan">
|
---|
| 595 | <term><filename class="libraryfile">libtsan</filename></term>
|
---|
| 596 | <listitem>
|
---|
| 597 | <para>The Thread Sanitizer runtime library</para>
|
---|
| 598 | <indexterm zone="ch-system-gcc libtsan">
|
---|
| 599 | <primary sortas="c-libtsan">libtsan</primary>
|
---|
| 600 | </indexterm>
|
---|
| 601 | </listitem>
|
---|
| 602 | </varlistentry>
|
---|
| 603 |
|
---|
[78cc3be] | 604 | <varlistentry id="libubsan">
|
---|
| 605 | <term><filename class="libraryfile">libubsan</filename></term>
|
---|
| 606 | <listitem>
|
---|
| 607 | <para>The Undefined Behavior Sanitizer runtime library</para>
|
---|
| 608 | <indexterm zone="ch-system-gcc libubsan">
|
---|
| 609 | <primary sortas="c-libubsan">libubsan</primary>
|
---|
| 610 | </indexterm>
|
---|
| 611 | </listitem>
|
---|
| 612 | </varlistentry>
|
---|
| 613 |
|
---|
[6a82dd9] | 614 | </variablelist>
|
---|
| 615 |
|
---|
| 616 | </sect2>
|
---|
[673b0d8] | 617 |
|
---|
| 618 | </sect1>
|
---|