From 03e19e2ab37bf1d34ac03e5a71c3b243898d2223 Mon Sep 17 00:00:00 2001 From: Davide Grohmann Date: Wed, 11 Aug 2021 13:35:14 +0200 Subject: Ensure same flags are used for both GCC and ARMClang Change-Id: Ib37930e7efb0663e9c39bb6c39af8cc62cf3f37c --- cmake/toolchain/arm-none-eabi-gcc.cmake | 5 +++-- cmake/toolchain/armclang.cmake | 1 + 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/cmake/toolchain/arm-none-eabi-gcc.cmake b/cmake/toolchain/arm-none-eabi-gcc.cmake index 701824f..11a1191 100644 --- a/cmake/toolchain/arm-none-eabi-gcc.cmake +++ b/cmake/toolchain/arm-none-eabi-gcc.cmake @@ -44,6 +44,7 @@ set(CMAKE_CXX_STANDARD 14) add_compile_options( -mcpu=${TARGET_CPU} -mthumb + "$<$:-gdwarf-3>" "$<$:-fno-unwind-tables;-fno-rtti;-fno-exceptions>") # Compile defines @@ -80,11 +81,11 @@ add_compile_options( -Wsign-compare -Wunused -Wswitch-default -# -Wformat + -Wformat -Wdouble-promotion -Wredundant-decls -Wshadow -# -Wcast-align + -Wcast-align -Wnull-dereference -Wno-format-extra-args -Wno-unused-function diff --git a/cmake/toolchain/armclang.cmake b/cmake/toolchain/armclang.cmake index 25c510c..257c2a8 100644 --- a/cmake/toolchain/armclang.cmake +++ b/cmake/toolchain/armclang.cmake @@ -84,6 +84,7 @@ add_compile_options( -Wnull-dereference -Wno-format-extra-args -Wno-unused-function + -Wno-unused-parameter -Wno-unused-label -Wno-missing-field-initializers -Wno-return-type) -- cgit v1.2.1