extra portability adjustments

This commit is contained in:
lizzie 2026-08-30 06:56:15 +00:00
parent 9195b1ede4
commit 19852c453f
6 changed files with 41 additions and 28 deletions

View file

@ -25,17 +25,13 @@ include(CTest)
include(CPMUtil)
if (CXX_GCC AND CMAKE_CXX_COMPILER_VERSION VERSION_LESS "14.0")
message(FATAL_ERROR "You must use gcc14 (or newer) feel free to fix clang yourself otherwise.")
message(FATAL_ERROR "GCC versions older than 14.0 are not supported. Update your system, or use clang/clang++ instead.")
endif()
if (OPENBSD)
# OpenBSD 7.8 broke libcxx when upgrading, so we must define the PSTL backend manually
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -D_LIBCPP_PSTL_BACKEND_SERIAL=1")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -D_LIBCPP_PSTL_BACKEND_SERIAL=1")
elseif (NETBSD)
if (NOT CXX_GCC OR CMAKE_CXX_COMPILER_VERSION VERSION_LESS "14.0")
message(FATAL_ERROR "You must use gcc14 (or newer) from pkgin; feel free to fix clang yourself otherwise.")
endif()
endif()
# NetBSD: Fun for the whole family!