diff options
author | Lukas Slebodnik <lslebodn@redhat.com> | 2014-02-21 11:58:03 +0100 |
---|---|---|
committer | Andreas Schneider <asn@cryptomilk.org> | 2014-02-21 16:30:14 +0100 |
commit | a1e707b30ad819b15445d785819516ad58da4aa2 (patch) | |
tree | 217d041fee5b4f8450a494dc039b129c7f85159b /cmake | |
parent | 1e56a5646d30594e3174a9811d5b1bb7bd4bd77d (diff) | |
download | cmocka-a1e707b30ad819b15445d785819516ad58da4aa2.tar.gz cmocka-a1e707b30ad819b15445d785819516ad58da4aa2.tar.bz2 cmocka-a1e707b30ad819b15445d785819516ad58da4aa2.zip |
Enable warning Wundef
It is better to use "#ifdef" for testing macros instead of "#if"
In header file, "#ifdef DOXYGEN" was used 30 times and "#if DOXYGEN"
23 times. This patch makes it consistent and enable warning Wundef to prevent
this kind of issues.
Reviewed-by: Andreas Schneider <asn@cryptomilk.org>
Diffstat (limited to 'cmake')
-rw-r--r-- | cmake/Modules/DefineCompilerFlags.cmake | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/cmake/Modules/DefineCompilerFlags.cmake b/cmake/Modules/DefineCompilerFlags.cmake index 7b65720..4fb0aed 100644 --- a/cmake/Modules/DefineCompilerFlags.cmake +++ b/cmake/Modules/DefineCompilerFlags.cmake @@ -13,7 +13,7 @@ if (UNIX AND NOT WIN32) set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -std=gnu99 -pedantic -pedantic-errors") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wall -Wextra -Wshadow -Wmissing-prototypes -Wdeclaration-after-statement") set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wunused -Wfloat-equal -Wpointer-arith -Wwrite-strings -Wformat-security") - set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wmissing-format-attribute") + set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -Wmissing-format-attribute -Wundef") # with -fPIC check_c_compiler_flag("-fPIC" WITH_FPIC) |