BuildRequires: systemd-devel
%endif
-%if 0%{?rhel} == 8
+# Only when we move to C++20
+%if 0%{?rhel} == 8 && 0
BuildRequires: boost1.78-devel
%else
BuildRequires: boost-devel
%build
# We need to build with LLVM/clang to be able to use LTO, since we are linking against a static Rust library built with LLVM
-%if 0%{?rhel} == 8
+# Only when we move to C++20
+%if 0%{?rhel} == 8 && 0
export BOOST_INCLUDEDIR=/usr/include/boost1.78
export BOOST_LIBRARYDIR=/usr/lib64/boost1.78
%endif
BuildRequires: krb5-devel
BuildRequires: p11-kit-devel
BuildRequires: libcurl-devel
-%if 0%{?rhel} == 8
+# Only when we move to C++20
+%if 0%{?rhel} == 8 && 0
BuildRequires: boost1.78-devel
%else
BuildRequires: boost-devel
%autosetup -p1 -n %{name}-%{getenv:BUILDER_VERSION}
%build
-%if 0%{?rhel} == 8
+# Only when we move to C++20
+%if 0%{?rhel} == 8 && 0
export BOOST_INCLUDEDIR=/usr/include/boost1.78
export BOOST_LIBRARYDIR=/usr/lib64/boost1.78
export CPPFLAGS=-I$BOOST_INCLUDEDIR
# Warn when pkg.m4 is missing
m4_pattern_forbid([^_?PKG_[A-Z_]+$], [*** pkg.m4 missing, please install pkg-config])
-AX_CXX_COMPILE_STDCXX_20([ext], [mandatory])
+AX_CXX_COMPILE_STDCXX_17([noext], [mandatory])
LT_PREREQ([2.2.2])
LT_INIT([disable-static dlopen])
default_options: [
'buildtype=debugoptimized',
'warning_level=2', # TODO Move this to 3 to enable -Wpedantic
- 'cpp_std=gnu++20',
+ 'cpp_std=c++17',
],
)
g_log<<Logger::Warning<<"About to create "<<numberOfThreads<<" backend threads for UDP"<<endl;
for (int distributorIdx = 0; distributorIdx < numberOfThreads; distributorIdx++) {
- std::thread t([=,this](){distribute(distributorIdx);});
+ std::thread t([=](){distribute(distributorIdx);});
t.detach();
Utility::usleep(50000); // we've overloaded mysql in the past :-)
}
PDNS_ENABLE_IPCIPHER
PDNS_CHECK_AARCH64_UINT64X2_T
-AX_CXX_COMPILE_STDCXX_20([ext], [mandatory])
+AX_CXX_COMPILE_STDCXX_17([noext], [mandatory])
AC_MSG_CHECKING([whether we will enable compiler security checks])
AC_ARG_ENABLE([hardening],
fn main() {
let mut bridge = cxx_build::bridge("src/lib.rs");
let mut build = bridge
- .flag_if_supported("-std=c++17")
+ .std("c++17")
.flag("-Isrc")
.flag("-I.")
.flag("-I..")
println!("cargo:rerun-if-changed=src/lib.rs");
println!("cargo:rerun-if-changed=src/helpers.rs");
-}
\ No newline at end of file
+}
default_options: [
'buildtype=debugoptimized',
'warning_level=2', # TODO Move this to 3 to enable -Wpedantic
- 'cpp_std=gnu++20',
+ 'cpp_std=c++17',
'b_pie=true',
],
)
# Warn when pkg.m4 is missing
m4_pattern_forbid([^_?PKG_[A-Z_]+$], [*** pkg.m4 missing, please install pkg-config])
-AX_CXX_COMPILE_STDCXX_20([ext], [mandatory])
+AX_CXX_COMPILE_STDCXX_17([noext], [mandatory])
PDNS_CHECK_CARGO([1.64])
# Rust runtime used dlopen from its static lib
default_options: [
'buildtype=debugoptimized',
'warning_level=2', # TODO Move this to 3 to enable -Wpedantic
- 'cpp_std=gnu++20',
+ 'cpp_std=c++17',
],
)
let sources = vec!["src/lib.rs", "src/web.rs", "src/misc.rs"];
cxx_build::bridges(sources)
// .file("src/source.cc") Code callable from Rust is in ../cxxsupport.cc
- .flag_if_supported("-std=c++17")
+ .std("c++17")
.flag("-Isrc")
.flag("-I../..")
.compile("recrust");