From 8f74704ea59f6dc16d4286869492c03eb1344689 Mon Sep 17 00:00:00 2001 From: Max Bachmann Date: Mon, 2 Sep 2024 17:04:56 +0200 Subject: [PATCH] workaround crash in mutex --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 314c0b07..d6466e6c 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -29,6 +29,10 @@ endif() if(MSVC) add_compile_options(/W4 /bigobj /wd4127) + + # NOTE: _DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR is temporary. When building on + # VS 2022 17.10 or newer, but using an older runtime, mutexes can crash + add_compile_options(/D_DISABLE_CONSTEXPR_MUTEX_CONSTRUCTOR) else() add_compile_options(-Wall -Wextra -pedantic -Wno-psabi) endif()