Skip to content

Commit

Permalink
Check for MSVC instead of WIN32 when targeting Visual Studio.
Browse files Browse the repository at this point in the history
  • Loading branch information
kovacsv committed Dec 17, 2021
1 parent 31d75f6 commit b643dad
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ set (VSE_CUSTOM_BUILD_OPTIONS ${VSE_CUSTOM_BUILD_OPTIONS})

function (SetCompilerOptions module)
target_compile_options (${module} PUBLIC "$<$<CONFIG:Debug>:-DDEBUG>")
if (WIN32)
if (MSVC)
set (AdditionalWarnings /w44061 /w44062 /w44265 /w44266 /w44355 /w44596 /w44800)
target_compile_options (${module} PUBLIC /W4 /WX ${AdditionalWarnings} ${VSE_CUSTOM_BUILD_OPTIONS})
else ()
Expand Down Expand Up @@ -159,14 +159,13 @@ target_include_directories (
)
target_link_libraries (EmbeddingTutorial NodeEngine NodeUIEngine BuiltInNodes)
SetCompilerOptions (EmbeddingTutorial)
if (WIN32)
if (MSVC)
target_compile_options (EmbeddingTutorial PUBLIC /wd4100)
else ()
target_compile_options (EmbeddingTutorial PUBLIC -Wno-unused-parameter)
endif ()

if (WIN32)

# WindowsAppSupport

set (WindowsAppSupportSourcesFolder Sources/WindowsAppSupport)
Expand Down

0 comments on commit b643dad

Please sign in to comment.