aboutsummaryrefslogtreecommitdiff
path: root/gdb/config.in
diff options
context:
space:
mode:
authorLancelot Six <lancelot.six@amd.com>2023-09-12 12:34:51 +0000
committerLancelot Six <lancelot.six@amd.com>2023-10-28 19:25:34 +0000
commitf74dc26792a0679e29db45e56367331ff48666d1 (patch)
treec70261e72422a288b139750893933098e5ad0c24 /gdb/config.in
parenteb4de4047d8fab210c521730a2e4b43401129981 (diff)
downloadgdb-f74dc26792a0679e29db45e56367331ff48666d1.zip
gdb-f74dc26792a0679e29db45e56367331ff48666d1.tar.gz
gdb-f74dc26792a0679e29db45e56367331ff48666d1.tar.bz2
gdb/gdbsupport/gdbserver: Require c++17
This patch proposes to require a C++17 compiler to build gdb / gdbsupport / gdbserver. Before this patch, GDB required a C++11 compiler. The general policy regarding bumping C++ language requirement in GDB (as stated in [1]) is: Our general policy is to wait until the oldest compiler that supports C++NN is at least 3 years old. Rationale: We want to ensure reasonably widespread compiler availability, to lower barrier of entry to GDB contributions, and to make it easy for users to easily build new GDB on currently supported stable distributions themselves. 3 years should be sufficient for latest stable releases of distributions to include a compiler for the standard, and/or for new compilers to appear as easily installable optional packages. Requiring everyone to build a compiler first before building GDB, which would happen if we required a too-new compiler, would cause too much inconvenience. See the policy proposal and discussion [here](https://sourceware.org/ml/gdb-patches/2016-10/msg00616.html). The first GCC release which with full C++17 support is GCC-9[2], released in 2019[3], which is over 4 years ago. Clang has had C++17 support since Clang-5[4] released in 2018[5]. A discussions with many distros showed that a C++17-able compiler is always available, meaning that this no hard requirement preventing us to require it going forward. [1] https://sourceware.org/gdb/wiki/Internals%20GDB-C-Coding-Standards#When_is_GDB_going_to_start_requiring_C.2B-.2B-NN_.3F [2] https://gcc.gnu.org/projects/cxx-status.html#cxx17 [3] https://gcc.gnu.org/gcc-9/ [4] https://clang.llvm.org/cxx_status.html [5] https://releases.llvm.org/ Change-Id: Id596f5db17ea346e8a978668825787b3a9a443fd Reviewed-By: Eli Zaretskii <eliz@gnu.org> Approved-By: Tom Tromey <tom@tromey.com> Approved-By: Pedro Alves <pedro@palves.net>
Diffstat (limited to 'gdb/config.in')
-rw-r--r--gdb/config.in4
1 files changed, 2 insertions, 2 deletions
diff --git a/gdb/config.in b/gdb/config.in
index e172451..f8926fe 100644
--- a/gdb/config.in
+++ b/gdb/config.in
@@ -99,8 +99,8 @@
/* Define to 1 if you have the <curses.h> header file. */
#undef HAVE_CURSES_H
-/* define if the compiler supports basic C++11 syntax */
-#undef HAVE_CXX11
+/* define if the compiler supports basic C++17 syntax */
+#undef HAVE_CXX17
/* Define to 1 if you have the declaration of `ADDR_NO_RANDOMIZE', and to 0 if
you don't. */