aboutsummaryrefslogtreecommitdiff
path: root/libstdc++-v3/doc
diff options
context:
space:
mode:
authorJonathan Wakely <jwakely@redhat.com>2023-09-07 10:24:56 +0100
committerJonathan Wakely <jwakely@redhat.com>2023-09-08 18:04:12 +0100
commitb96b554592c5cbb6a2c1797ffcb5706fd295f4fd (patch)
tree62d0bbe4c052f2d8a1e9e4edec5e858ad2e99aa5 /libstdc++-v3/doc
parent1a0c6decd2112267c88438466df2e1c46b20248e (diff)
downloadgcc-b96b554592c5cbb6a2c1797ffcb5706fd295f4fd.zip
gcc-b96b554592c5cbb6a2c1797ffcb5706fd295f4fd.tar.gz
gcc-b96b554592c5cbb6a2c1797ffcb5706fd295f4fd.tar.bz2
libstdc++: Add Filesystem TS and std::stacktrace symbols to libstdc++exp.a
This consolidates the three static archives for extensions into one, so that -lstdc++exp can be used to provide the definitions of all unstable library features. The libstdc++_libbacktrace.a archive is now just a "noinst" convenience library that is only used during the build, not installed. Its contents are added to libstdc++exp.a, along with the new non-inline definitions of std::stacktrace symbols. The libstdc++fs.a archive is still installed, but its contents are duplicated in libstdc++exp.a now. This means -lstdc++exp can be used instead of -lstdc++fs. For targets using the GNU linker we should consider replacing libstdc++fs.a with a linker script that does INPUT(libstdc++exp.a). The tests for <experimental/filesystem> could be changed to use -lstdc++exp instead of -lstdc++fs, which would allow removing src/filesystem/.libs from the LDFLAGS in scripts/testsuite_flags.in, but that can be done at a later date. libstdc++-v3/ChangeLog: * acinclude.m4 (GLIBCXX_CONFIGURE): Add c++23 directory. * configure: Regenerate. * doc/html/manual/*: Regenerate. * doc/xml/manual/using.xml: Update documentation on linking. * include/std/stacktrace: Remove declarations of libbacktrace APIs. (stacktrace_entry::_S_err_handler, stacktrace_entry::_S_init): Remove. (stacktrace_entry::_Info): New class. (stacktrace_entry::_M_get_info): Use _Info. (__stacktrace_impl): New class. (basic_stacktrace): Derive from __stacktrace_impl. (basic_stacktrace::current): Use __stacktrace_impl::_S_current. * scripts/testsuite_flags.in: Adjust LDFLAGS to find libstdc++exp instead of libstdc++_libbacktrace. * src/Makefile.am (SUBDIRS): Add c++23 directory. * src/Makefile.in: Regenerate. * src/c++20/Makefile.am: Fix comment. * src/c++20/Makefile.in: Regenerate. * src/c++23/Makefile.am: New file. * src/c++23/Makefile.in: New file. * src/c++23/stacktrace.cc: New file with definitions of stacktrace_entry::_Info and __stacktrace_impl members. * src/experimental/Makefile.am: Use LIBADD to include other libraries. * src/experimental/Makefile.in: Regenerate. * src/libbacktrace/Makefile.am: Use noinst_LTLIBRARIES. * src/libbacktrace/Makefile.in: Regenerate. * testsuite/19_diagnostics/stacktrace/current.cc: Adjust dg-options to use -lstdc++exp. * testsuite/19_diagnostics/stacktrace/entry.cc: Likewise. * testsuite/19_diagnostics/stacktrace/stacktrace.cc: Likewise. * testsuite/23_containers/vector/debug/assign4_backtrace_neg.cc: Likewise.
Diffstat (limited to 'libstdc++-v3/doc')
-rw-r--r--libstdc++-v3/doc/html/manual/using.html26
-rw-r--r--libstdc++-v3/doc/html/manual/using_dynamic_or_shared.html4
-rw-r--r--libstdc++-v3/doc/xml/manual/using.xml37
3 files changed, 37 insertions, 30 deletions
diff --git a/libstdc++-v3/doc/html/manual/using.html b/libstdc++-v3/doc/html/manual/using.html
index eebb35d..e8e0c6c 100644
--- a/libstdc++-v3/doc/html/manual/using.html
+++ b/libstdc++-v3/doc/html/manual/using.html
@@ -28,18 +28,20 @@
</td></tr><tr><td align="left"><code class="literal">-latomic</code></td><td align="left">Linking to <code class="filename">libatomic</code>
is required for some uses of ISO C++11
<code class="filename">&lt;atomic&gt;</code>.
- </td></tr><tr><td align="left"><code class="literal">-lstdc++fs</code></td><td align="left">Linking to <code class="filename">libstdc++fs</code>
- is required for use of the Filesystem library extensions in
- <code class="filename">&lt;experimental/filesystem&gt;</code>.
- </td></tr><tr><td align="left"><code class="literal">-lstdc++exp</code></td><td align="left">Linking to <code class="filename">libstdc++exp</code>
- is required for use of the C++ Contracts extensions enabled by
- <code class="literal">-fcontracts</code>.
- </td></tr><tr><td align="left"><code class="literal">-lstdc++_libbacktrace</code></td><td align="left">Until C++23 support is non-experimental, linking to
- <code class="filename">libstdc++_libbacktrace.a</code>
- is required for use of the C++23 type
- <code class="classname">std::stacktrace</code>
- and related types in
- <code class="filename">&lt;stacktrace&gt;</code>.
+ </td></tr><tr><td align="left"><code class="literal">-lstdc++exp</code></td><td align="left">Linking to <code class="filename">libstdc++exp.a</code>
+ is required for use of experimental C++ library features.
+ This currently provides support for the C++23 types defined in the
+ <code class="filename">&lt;stacktrace&gt;</code> header,
+ the Filesystem library extensions defined in the
+ <code class="filename">&lt;experimental/filesystem&gt;</code>
+ header,
+ and the Contracts extensions enabled by <code class="literal">-fcontracts</code>.
+ </td></tr><tr><td align="left"><code class="literal">-lstdc++fs</code></td><td align="left">Linking to <code class="filename">libstdc++fs.a</code>
+ is another way to use the Filesystem library extensions defined in the
+ <code class="filename">&lt;experimental/filesystem&gt;</code>
+ header.
+ The <code class="filename">libstdc++exp.a</code> library
+ also provides all the symbols contained in this library.
</td></tr><tr><td align="left"><code class="literal">-fopenmp</code></td><td align="left">For <a class="link" href="parallel_mode.html" title="Chapter 18. Parallel Mode">parallel</a> mode.</td></tr><tr><td align="left"><code class="literal">-ltbb</code></td><td align="left">Linking to tbb (Thread Building Blocks) is required for use of the
Parallel Standard Algorithms and execution policies in
<code class="filename">&lt;execution&gt;</code>.
diff --git a/libstdc++-v3/doc/html/manual/using_dynamic_or_shared.html b/libstdc++-v3/doc/html/manual/using_dynamic_or_shared.html
index 46ccbc5..f1e7278 100644
--- a/libstdc++-v3/doc/html/manual/using_dynamic_or_shared.html
+++ b/libstdc++-v3/doc/html/manual/using_dynamic_or_shared.html
@@ -138,6 +138,10 @@ A quick read of the relevant part of the GCC
and link with <code class="option">-lstdc++fs</code>. The library implementation
is incomplete on non-POSIX platforms, specifically Windows is only
partially supported.
+ Since GCC 14, <code class="filename">libstdc++exp.a</code>
+ also contains the definitions for this library,
+ so <code class="option">-lstdc++exp</code> can be used instead of
+ <code class="option">-lstdc++fs</code>.
</p><p>
GCC 13 includes an implementation of the C++ Contracts library defined by
<a class="link" href="https://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1429r3.pdf" target="_top">P1429R3</a>.
diff --git a/libstdc++-v3/doc/xml/manual/using.xml b/libstdc++-v3/doc/xml/manual/using.xml
index 3a507fc..7276cad 100644
--- a/libstdc++-v3/doc/xml/manual/using.xml
+++ b/libstdc++-v3/doc/xml/manual/using.xml
@@ -101,29 +101,26 @@
</row>
<row>
- <entry><literal>-lstdc++fs</literal></entry>
- <entry>Linking to <filename class="libraryfile">libstdc++fs</filename>
- is required for use of the Filesystem library extensions in
- <filename class="headerfile">&lt;experimental/filesystem&gt;</filename>.
- </entry>
- </row>
-
- <row>
<entry><literal>-lstdc++exp</literal></entry>
- <entry>Linking to <filename class="libraryfile">libstdc++exp</filename>
- is required for use of the C++ Contracts extensions enabled by
- <literal>-fcontracts</literal>.
+ <entry>Linking to <filename class="libraryfile">libstdc++exp.a</filename>
+ is required for use of experimental C++ library features.
+ This currently provides support for the C++23 types defined in the
+ <filename class="headerfile">&lt;stacktrace&gt;</filename> header,
+ the Filesystem library extensions defined in the
+ <filename class="headerfile">&lt;experimental/filesystem&gt;</filename>
+ header,
+ and the Contracts extensions enabled by <literal>-fcontracts</literal>.
</entry>
</row>
<row>
- <entry><literal>-lstdc++_libbacktrace</literal></entry>
- <entry>Until C++23 support is non-experimental, linking to
- <filename class="libraryfile">libstdc++_libbacktrace.a</filename>
- is required for use of the C++23 type
- <classname>std::stacktrace</classname>
- and related types in
- <filename class="headerfile">&lt;stacktrace&gt;</filename>.
+ <entry><literal>-lstdc++fs</literal></entry>
+ <entry>Linking to <filename class="libraryfile">libstdc++fs.a</filename>
+ is another way to use the Filesystem library extensions defined in the
+ <filename class="headerfile">&lt;experimental/filesystem&gt;</filename>
+ header.
+ The <filename class="libraryfile">libstdc++exp.a</filename> library
+ also provides all the symbols contained in this library.
</entry>
</row>
@@ -1710,6 +1707,10 @@ A quick read of the relevant part of the GCC
and link with <option>-lstdc++fs</option>. The library implementation
is incomplete on non-POSIX platforms, specifically Windows is only
partially supported.
+ Since GCC 14, <filename class="libraryfile">libstdc++exp.a</filename>
+ also contains the definitions for this library,
+ so <option>-lstdc++exp</option> can be used instead of
+ <option>-lstdc++fs</option>.
</para>
<para>