]> gcc.gnu.org Git - gcc.git/commit
libstdc++: Make _GLIBCXX_HOSTED respect -ffreestanding [PR103626]
authorJonathan Wakely <jwakely@redhat.com>
Tue, 20 Sep 2022 10:57:28 +0000 (11:57 +0100)
committerJonathan Wakely <jwakely@redhat.com>
Mon, 3 Oct 2022 14:43:48 +0000 (15:43 +0100)
commitf1b51f68f8ac6c63e352dda8599aed01634212de
tree18496da44408ad8f7e0fb72263e2edf7523eb61e
parent77d0627c244f7520bf74ec9cf2a8b69c32b6d30d
libstdc++: Make _GLIBCXX_HOSTED respect -ffreestanding [PR103626]

This allows the library to switch to freestanding mode when compiling
with the -ffreestanding flag. This means you don't need a separate
libstdc++ build configured with --disable-hosted-libstdcxx in order to
compile for a freestanding environment.

The testsuite support files cannot be compiled for freestanding, so add
-fno-freestanding to override any -ffreestanding in the test flags.

libstdc++-v3/ChangeLog:

PR libstdc++/103626
* acinclude.m4 (GLIBCXX_ENABLE_HOSTED): Define _GLIBCXX_HOSTED
to __STDC_HOSTED__ for non-freestanding installations.
* configure: Regenerate.
* include/Makefile.am (${host_builddir}/c++config.h): Adjust
grep pattern.
* include/Makefile.in: Regenerate.
* testsuite/lib/libstdc++.exp (v3-build_support): Use
-fno-freestanding.
* testsuite/libstdc++-abi/abi.exp: Likewise.
libstdc++-v3/acinclude.m4
libstdc++-v3/configure
libstdc++-v3/include/Makefile.am
libstdc++-v3/include/Makefile.in
libstdc++-v3/testsuite/lib/libstdc++.exp
libstdc++-v3/testsuite/libstdc++-abi/abi.exp
This page took 0.060303 seconds and 6 git commands to generate.