Skip to content

Commit

Permalink
Fix 'unknown warning option' warnings when building with Clang (#1028)
Browse files Browse the repository at this point in the history
Fixes #1027
  • Loading branch information
acolwell authored Dec 23, 2024
1 parent 08149b4 commit e0d28bc
Showing 1 changed file with 8 additions and 4 deletions.
12 changes: 8 additions & 4 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,10 @@ if (MSVC)
else()
SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wmissing-prototypes" )
add_compile_options(-Wall -Wextra -Wmissing-declarations -Wno-multichar -Winit-self -Wno-long-long
-Wvla -Wdate-time -Wshift-overflow=2
-Wduplicated-cond -Wno-stringop-overflow -Wno-format-overflow
-Wno-deprecated-copy)
-Wvla -Wdate-time -Wno-format-overflow -Wno-deprecated-copy)
if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
add_compile_options(-Wshift-overflow=2 -Wduplicated-cond -Wno-stringop-overflow)
endif()
endif()

if(NATRON_SYSTEM_LIBS)
Expand All @@ -141,7 +142,10 @@ elseif(WIN32)
add_compile_definitions(WINDOWS WIN32 _UNICODE UNICODE NOMINMAX QHTTP_SERVER_STATIC)
add_compile_definitions(COMPILED_FROM_DSP XML_STATIC) # for expat
if (NOT MSVC)
add_compile_options(-mwindows -municode -mthreads)
add_compile_options(-municode)
if (CMAKE_CXX_COMPILER_ID STREQUAL "GNU")
add_compile_options(-mwindows -mthreads)
endif()
add_link_options(-mwindows -municode)
set(CMAKE_RC_COMPILER_INIT windres)
set(CMAKE_RC_COMPILE_OBJECT
Expand Down

0 comments on commit e0d28bc

Please sign in to comment.