From 999982b06ce1d1280e5ce48f9253c6c536f41a12 Mon Sep 17 00:00:00 2001 From: MarcoFalke Date: Fri, 11 Feb 2022 13:08:55 +0100 Subject: build: Add --enable-c++20 option --- configure.ac | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'configure.ac') diff --git a/configure.ac b/configure.ac index 63ff6a1ebd..f59418205c 100644 --- a/configure.ac +++ b/configure.ac @@ -78,8 +78,18 @@ AC_ARG_WITH([seccomp], [seccomp_found=$withval], [seccomp_found=auto]) +AC_ARG_ENABLE([c++20], + [AS_HELP_STRING([--enable-c++20], + [enable compilation in c++20 mode (disabled by default)])], + [use_cxx20=$enableval], + [use_cxx20=no]) + dnl Require C++17 compiler (no GNU extensions) +if test "$use_cxx20" = "no"; then AX_CXX_COMPILE_STDCXX([17], [noext], [mandatory]) +else +AX_CXX_COMPILE_STDCXX([20], [noext], [mandatory]) +fi dnl Check if -latomic is required for CHECK_ATOMIC -- cgit v1.2.3