Permalink
Browse files

CMakeLists.txt: add -Werror=format-security

  • Loading branch information...
rouault committed Jun 7, 2017
1 parent 1e8b44c commit 0174ae639639ed4e8c01d6830bbc72695cdfef98
Showing with 2 additions and 2 deletions.
  1. +2 −2 CMakeLists.txt
@@ -165,8 +165,8 @@ option(WITH_GENERIC_NINT "generic rounding" OFF)

# Add compiler flags for warnings
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_COMPILER_IS_GNUCC)
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wdeclaration-after-statement")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Werror=format-security -Wdeclaration-after-statement")
set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Werror=format-security")
endif()

if(NOT DEFINED CMAKE_INSTALL_LIBDIR)

0 comments on commit 0174ae6

Please sign in to comment.