From f916fe3c6aa166f31dbbd42324b972aa6e08ff3a Mon Sep 17 00:00:00 2001 From: Eric Wasylishen Date: Tue, 3 May 2022 02:32:36 -0600 Subject: [PATCH] build: workaround for clang-cl --- CMakeLists.txt | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index 20431f28..dc082b81 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -75,6 +75,10 @@ if (ERICWTOOLS_ASAN) add_link_options(-fsanitize=address) endif() +if (CMAKE_CXX_COMPILER_ID STREQUAL "Clang" AND CMAKE_CXX_SIMULATE_ID STREQUAL "MSVC") + add_compile_options(/EHsc) +endif() + # 10.9: minimum version that supports unordered_map # 10.14: required by tbb 2021.3.0 (due to use of alignas) # 10.15: required by std::filesytstem