Bugfix/fix redundant compiler flags (#658)
* Improved GCC compiler flags in ARM, OS, and test builds. Removed redundant flags, and made them consistent across various builds. * Fixed redundant redeclaration of various functions detected by change in compiler flags. * Fixed string truncation warning in bip-init detected by change in compiler flags. * Fixed some set-but-not-used variables by creating dummy functions instead of using macros.
This commit is contained in:
@@ -191,9 +191,20 @@ target_compile_definitions(${EXECUTABLE} PRIVATE
|
||||
-DBACAPP_MINIMAL
|
||||
)
|
||||
|
||||
# inhibit pedantic warnings
|
||||
target_compile_options(${EXECUTABLE} PRIVATE
|
||||
-Wall
|
||||
-Wall -Wextra -pedantic
|
||||
-Wfloat-equal -Wconversion -Wredundant-decls
|
||||
-Wswitch-default
|
||||
# don't warn about conversion, sign, compares, long long and attributes
|
||||
# since they are common in embedded
|
||||
-Wno-sign-conversion
|
||||
-Wno-conversion
|
||||
-Wno-sign-compare
|
||||
-Wno-long-long
|
||||
-Wno-attributes
|
||||
# don't warn about implicit fallthrough since it is common in network protocols
|
||||
-Wno-implicit-fallthrough
|
||||
# the older Atmel SDK does not meet coding guidelines
|
||||
-Wno-comment
|
||||
-Wno-missing-braces
|
||||
-Wno-unused-variable
|
||||
|
||||
Reference in New Issue
Block a user