diff options
-rw-r--r-- | CMakeLists.txt | 4 | ||||
-rw-r--r-- | configure.ac | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index c79cc998e..623b0d38a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -27,8 +27,8 @@ project(weechat C) set(CMAKE_VERBOSE_MAKEFILE OFF) set(CMAKE_MODULE_PATH ${CMAKE_SOURCE_DIR}/cmake ${CMAKE_MODULE_PATH}) set(CMAKE_SKIP_RPATH ON) -set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsigned-char -Wall -Wextra -Werror-implicit-function-declaration") -set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsigned-char -Wall -Wextra") +set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -fsigned-char -Wall -Wextra -Werror-implicit-function-declaration -Wformat-overflow=2 -Wformat-truncation=2") +set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -fsigned-char -Wall -Wextra -Wformat-overflow=2 -Wformat-truncation=2") # version execute_process(COMMAND ${CMAKE_SOURCE_DIR}/version.sh devel-major OUTPUT_VARIABLE VERSION_MAJOR) diff --git a/configure.ac b/configure.ac index 6e707c4dc..7ef5ad5a5 100644 --- a/configure.ac +++ b/configure.ac @@ -1282,8 +1282,8 @@ AC_DEFINE_UNQUOTED(WEECHAT_SHAREDIR, "$WEECHAT_SHAREDIR") weechat_libdir=${libdir}/weechat AC_SUBST(weechat_libdir) -COMMON_CFLAGS="-fsigned-char -Wall -Wextra -Werror-implicit-function-declaration" -COMMON_CXXFLAGS="-fsigned-char -Wall -Wextra" +COMMON_CFLAGS="-fsigned-char -Wall -Wextra -Werror-implicit-function-declaration -Wformat-overflow=2 -Wformat-truncation=2" +COMMON_CXXFLAGS="-fsigned-char -Wall -Wextra -Wformat-overflow=2 -Wformat-truncation=2" AC_MSG_CHECKING([whether we have GNU assembler]) GAS=`as --version < /dev/null 2>/dev/null | grep GNU` |