mirror of
https://github.com/love2d/megasource.git
synced 2026-08-12 00:20:55 +02:00
suppress warnings for clang
--HG-- branch : suppress_warnings_clang
This commit is contained in:
+5
-1
@@ -52,7 +52,11 @@ endfunction()
|
||||
|
||||
function(disable_warnings ARG_TARGET)
|
||||
get_target_property(OLD_FLAGS ${ARG_TARGET} COMPILE_FLAGS)
|
||||
set(NEW_FLAGS -W0)
|
||||
if (CMAKE_CXX_COMPILER_ID MATCHES "Clang")
|
||||
set(NEW_FLAGS -w)
|
||||
else ()
|
||||
set(NEW_FLAGS -W0)
|
||||
endif ()
|
||||
if(OLD_FLAGS)
|
||||
set(NEW_FLAGS "${OLD_FLAGS} ${NEW_FLAGS}")
|
||||
endif()
|
||||
|
||||
Reference in New Issue
Block a user