From c5625fc1bcd9aeca4650ed3ac6faf998cb757f22 Mon Sep 17 00:00:00 2001 From: Joseph Hickey Date: Wed, 15 Jan 2020 14:53:32 -0500 Subject: [PATCH] Update #24: Also enable cast-align warning Include in the basic warning set. Note that at this time the CFE does not build cleanly on all architectures with this warning enabled, pending resolution of issue #313. --- cmake/sample_defs/arch_build_custom.cmake | 1 + cmake/sample_defs/mission_build_custom.cmake | 1 + 2 files changed, 2 insertions(+) diff --git a/cmake/sample_defs/arch_build_custom.cmake b/cmake/sample_defs/arch_build_custom.cmake index 14d41a517..ac1dd99b4 100644 --- a/cmake/sample_defs/arch_build_custom.cmake +++ b/cmake/sample_defs/arch_build_custom.cmake @@ -32,6 +32,7 @@ add_compile_options( -Wstrict-prototypes # Warn about missing prototypes -Wwrite-strings # Warn if not treating string literals as "const" -Wpointer-arith # Warn about suspicious pointer operations + -Wcast-align # Warn about casts that increase alignment requirements -Werror # Treat warnings as errors (code should be clean) ) diff --git a/cmake/sample_defs/mission_build_custom.cmake b/cmake/sample_defs/mission_build_custom.cmake index ae256ba9b..92506bc9a 100644 --- a/cmake/sample_defs/mission_build_custom.cmake +++ b/cmake/sample_defs/mission_build_custom.cmake @@ -17,6 +17,7 @@ add_compile_options( -Wstrict-prototypes # Warn about missing prototypes -Wwrite-strings # Warn if not treating string literals as "const" -Wpointer-arith # Warn about suspicious pointer operations + -Wcast-align # Warn about casts that increase alignment requirements -Werror # Treat warnings as errors (code should be clean) )