From 710d745a548cffd2535cba2aaf904f9fc96aca94 Mon Sep 17 00:00:00 2001 From: kcbanner Date: Thu, 23 May 2024 08:48:46 -0400 Subject: [PATCH] cmake: add /Zc:preprocessor to handle new OptTable macros See: https://github.com/llvm/llvm-project/commit/12d8e7c6ade55bba241259312e3e4bdcf6aeab81 See: https://github.com/llvm/llvm-project/commit/3f092f37b7362447cbb13f5502dae4bdd5762afd cmake: set MSVC_RUNTIME_LIBRARY for zigcpp --- CMakeLists.txt | 3 +++ 1 file changed, 3 insertions(+) diff --git a/CMakeLists.txt b/CMakeLists.txt index e1e8fcf921..feb1577476 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -728,6 +728,9 @@ if(NOT MSVC) -Wno-missing-braces -Wno-comment ) +else() +target_compile_options(zigcpp PRIVATE /Zc:preprocessor) +set_property(TARGET zigcpp PROPERTY MSVC_RUNTIME_LIBRARY "MultiThreaded") endif() target_include_directories(zigcpp PUBLIC