summaryrefslogtreecommitdiff
path: root/CMakeLists.txt
diff options
context:
space:
mode:
authorRalf Habacker <ralf.habacker@freenet.de>2021-11-11 13:24:06 +0100
committerSimon McVittie <smcv@collabora.com>2021-11-18 12:52:22 +0000
commit956aac65d49c36d27c5c7b1c569bb6c2571ae584 (patch)
tree4be715117ad431e70bff41103b0ead19d7ca5414 /CMakeLists.txt
parent31e8a2af0badd0f8d1ee9a8437048ea4422e2525 (diff)
downloaddbus-956aac65d49c36d27c5c7b1c569bb6c2571ae584.tar.gz
cmake: take over some fatal warnings from autotools
Adopt various fatal warnings from the autotools build system to see corresponding build errors also in cmake.
Diffstat (limited to 'CMakeLists.txt')
-rw-r--r--CMakeLists.txt8
1 files changed, 7 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt
index dc5d60d6..c18bb2d9 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -271,7 +271,13 @@ if(MSVC)
else()
set(WARNINGS "sign-compare")
set(WARNINGS_DISABLED "")
- set(WARNINGS_ERRORS "")
+ set(WARNINGS_ERRORS
+ missing-prototypes
+ strict-prototypes
+ declaration-after-statement
+ implicit-function-declaration
+ undef
+ )
endif()
generate_warning_cflags(WARNINGS_CFLAGS "${WARNINGS}" "${WARNINGS_DISABLED}" "${WARNINGS_ERRORS}")
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${WARNINGS_CFLAGS}")