From 137a14e106d75d1260f78acc1a19c5a936ef75b2 Mon Sep 17 00:00:00 2001 From: derselbst Date: Wed, 8 Jul 2020 19:10:29 +0200 Subject: [PATCH] Turn incompatible-pointer-types warning into error --- .travis.yml | 2 +- CMakeLists.txt | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.travis.yml b/.travis.yml index 4c65bdf9..6b5de751 100644 --- a/.travis.yml +++ b/.travis.yml @@ -25,7 +25,7 @@ addons: env: - CMAKE_FLAGS="-Denable-profiling=1" - CMAKE_FLAGS="-Denable-floats=1 -Denable-profiling=1" - - CMAKE_FLAGS="-Denable-floats=0" + - CMAKE_FLAGS="-Denable-floats=1" - CMAKE_FLAGS="-Denable-trap-on-fpe=1" - CMAKE_FLAGS="-Denable-fpe-check=1" - CMAKE_FLAGS="-Denable-ipv6=0" diff --git a/CMakeLists.txt b/CMakeLists.txt index 1b812074..c933c8e1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -184,7 +184,7 @@ if ( CMAKE_COMPILER_IS_GNUCC OR CMAKE_C_COMPILER_ID MATCHES "Clang" OR CMAKE_C_C endif ( NOT APPLE AND NOT OS2 ) # define some warning flags - set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -W -Wpointer-arith -Wcast-qual -Wstrict-prototypes -Wno-unused-parameter -Wdeclaration-after-statement -Werror=implicit-function-declaration" ) + set ( CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -W -Wpointer-arith -Wcast-qual -Wstrict-prototypes -Wno-unused-parameter -Wdeclaration-after-statement -Werror=implicit-function-declaration -Werror=incompatible-pointer-types" ) # prepend to build type specific flags, to allow users to override set ( CMAKE_C_FLAGS_DEBUG "-g ${CMAKE_C_FLAGS_DEBUG}" )