Skip to content

Commit

Permalink
Use CMAKE_CXX_FLAGS instead of add_compile_options
Browse files Browse the repository at this point in the history
  • Loading branch information
sudara committed Jul 31, 2024
1 parent f8fcd40 commit 9c7cf59
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -41,8 +41,9 @@ if (MelatoninInspector_IS_TOP_LEVEL)

# https://learn.microsoft.com/en-us/cpp/build/reference/mp-build-with-multiple-processes
# Needed for ninja to be happy in CI
# Hacky, ideally would be add_compile_options, but that didn't work
if (MSVC)
add_compile_options(/MP)
set(CMAKE_CXX_FLAGS "${CMAKE_C_FLAGS} /MP")
endif ()

set_target_properties("${TARGET_NAME}" PROPERTIES COMPILE_WARNING_AS_ERROR ON)
Expand Down

0 comments on commit 9c7cf59

Please sign in to comment.