Skip to content

Commit

Permalink
fix(cmake): enable gtest on windows
Browse files Browse the repository at this point in the history
Signed-off-by: Roberto Scolaro <[email protected]>
  • Loading branch information
therealbobo authored and poiana committed Sep 4, 2023
1 parent 00b4030 commit fc4277f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ option(WITH_CHISEL "Include chisel implementation" OFF)

option(CREATE_TEST_TARGETS "Enable make-targets for unit testing" ON)

if(CREATE_TEST_TARGETS AND NOT WIN32)
if(CREATE_TEST_TARGETS)
include(gtest)
endif()

Expand All @@ -104,7 +104,7 @@ endif()
include(libscap)
include(libsinsp)

if(CREATE_TEST_TARGETS AND NOT WIN32)
if(CREATE_TEST_TARGETS)
# Add command to run all unit tests at once via the make system.
# This is preferred vs using ctest's add_test because it will build
# the code and output to stdout.
Expand Down
2 changes: 1 addition & 1 deletion cmake/modules/CompilerFlags.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ if(NOT MSVC)
else() # MSVC
set(MINIMAL_BUILD ON)

set(FALCOSECURITY_LIBS_COMMON_FLAGS "-D_CRT_SECURE_NO_WARNINGS -DWIN32 -DMINIMAL_BUILD /EHsc /W3 /Zi /std:c++17")
set(FALCOSECURITY_LIBS_COMMON_FLAGS "-D_CRT_SECURE_NO_WARNINGS -DWIN32 -DMINIMAL_BUILD /EHsc /W3 /Zi /std:c++20")
set(FALCOSECURITY_LIBS_DEBUG_FLAGS "/MTd /Od")
set(FALCOSECURITY_LIBS_RELEASE_FLAGS "/MT")

Expand Down

0 comments on commit fc4277f

Please sign in to comment.