From: Petr Štetiar Date: Mon, 4 Nov 2019 17:02:35 +0000 (+0100) Subject: cmake: enable extra compiler checks X-Git-Url: https://git.librecmc.org/?a=commitdiff_plain;h=c1af73bfb0231f2ae3ed4bc376f4a347902fa607;p=oweals%2Fuci.git cmake: enable extra compiler checks Let's enforce additional automatic checks enforced by the compiler in order to catch possible errors during compilation. Signed-off-by: Petr Štetiar --- diff --git a/CMakeLists.txt b/CMakeLists.txt index 4dd75f7..92adf4a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,8 @@ cmake_minimum_required(VERSION 2.6) PROJECT(uci C) SET(CMAKE_SHARED_LIBRARY_LINK_C_FLAGS "") -ADD_DEFINITIONS(-Os -Wall -Werror -Wclobbered --std=gnu99 -g3 -I. -DUCI_PREFIX="${CMAKE_INSTALL_PREFIX}") +ADD_DEFINITIONS(-Os -Wall -Werror -Wextra --std=gnu99 -g3 -I. -DUCI_PREFIX="${CMAKE_INSTALL_PREFIX}") +ADD_DEFINITIONS(-Wno-unused-parameter) OPTION(UCI_DEBUG "debugging support" OFF) OPTION(UCI_DEBUG_TYPECAST "typecast debugging support" OFF)