Files
meta.hpp/develop/cmake/DisableExceptions.cmake
2023-03-20 15:48:32 +07:00

7 lines
311 B
CMake

add_library(${PROJECT_NAME}.disable_exceptions INTERFACE)
add_library(${PROJECT_NAME}::disable_exceptions ALIAS ${PROJECT_NAME}.disable_exceptions)
target_compile_options(${PROJECT_NAME}.disable_exceptions INTERFACE
$<$<OR:$<CXX_COMPILER_ID:Clang>,$<CXX_COMPILER_ID:AppleClang>>:
-fno-exceptions>)