From 030eb3451019ada84bd98cc0344324eee5cc92ad Mon Sep 17 00:00:00 2001 From: Sen66 Date: Mon, 2 Mar 2026 00:11:37 +0100 Subject: [PATCH] fix: include shim also on linux --- CMakeLists.txt | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 08479a5..073969d 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -37,9 +37,9 @@ add_library(raw_pdb STATIC ${RAW_PDB_SRCS}) target_include_directories(raw_pdb PUBLIC third_party/raw_pdb/src) target_compile_features(raw_pdb PRIVATE cxx_std_11) # PDB_CRT.h forward-declares printf/memcmp/etc with __cdecl which conflicts -# with MinGW. Force-include a prefix header that pulls in the real CRT headers -# and strips __cdecl so the redeclarations are compatible. -if(MINGW) +# with non-MSVC compilers (GCC, Clang, MinGW). Force-include a prefix header +# that pulls in the real CRT headers and strips __cdecl. +if(NOT MSVC) target_compile_options(raw_pdb PUBLIC -include "${CMAKE_CURRENT_SOURCE_DIR}/cmake/raw_pdb_prefix.h") endif()