diff --git a/reactos/cmake/config.cmake b/reactos/cmake/config.cmake index 9dd983b5fc9..3ece53bdf00 100644 --- a/reactos/cmake/config.cmake +++ b/reactos/cmake/config.cmake @@ -76,3 +76,6 @@ set(_PREFAST_ FALSE CACHE BOOL set(_VS_ANALYZE_ FALSE CACHE BOOL "Whether to enable static analysis while compiling.") endif() + +set(USE_DUMMY_PSEH FALSE CACHE BOOL +"Whether to disable PSEH support.") \ No newline at end of file diff --git a/reactos/cmake/gcc.cmake b/reactos/cmake/gcc.cmake index 669ffe6bfd3..3b7338254d7 100644 --- a/reactos/cmake/gcc.cmake +++ b/reactos/cmake/gcc.cmake @@ -17,6 +17,14 @@ if(USE_PSEH3) add_definitions(-D_USE_PSEH3=1) endif() +if(NOT DEFINED USE_DUMMY_PSEH) + set(USE_DUMMY_PSEH 0) +endif() + +if(USE_DUMMY_PSEH) + add_definitions(-D_USE_DUMMY_PSEH=1) +endif() + # Compiler Core add_compile_flags("-pipe -fms-extensions -fno-strict-aliasing") if(GCC_VERSION VERSION_GREATER 4.7) diff --git a/reactos/lib/pseh/CMakeLists.txt b/reactos/lib/pseh/CMakeLists.txt index 5e960e13451..6134e13681a 100644 --- a/reactos/lib/pseh/CMakeLists.txt +++ b/reactos/lib/pseh/CMakeLists.txt @@ -6,6 +6,8 @@ if(NOT MSVC) list(APPEND SOURCE i386/pseh3.c i386/pseh3_i386.S) + elseif(USE_DUMMY_PSEH) + list(APPEND SOURCE dummy.c) elseif(ARCH STREQUAL "i386") list(APPEND SOURCE i386/framebased.S