diff options
-rw-r--r-- | CMakeLists.txt | 10 | ||||
-rw-r--r-- | cmd/sbc_harness/CMakeLists.txt | 2 |
2 files changed, 11 insertions, 1 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index 100214c..c9774c6 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -16,7 +16,15 @@ project(sbc_harness) pico_sdk_init() -add_compile_options(-Wall -Wextra -Werror) +add_compile_options(-Wall -Wextra -Wswitch-enum -Werror) + +function(_suppress_tinyusb_warnings) + __suppress_tinyusb_warnings() + set_source_files_properties( + ${PICO_TINYUSB_PATH}/src/device/usbd.c + PROPERTIES + COMPILE_OPTIONS "-Wno-switch-enum") +endfunction() function(target_embed_sources arg_target arg_hdrname) set(embed_objs) diff --git a/cmd/sbc_harness/CMakeLists.txt b/cmd/sbc_harness/CMakeLists.txt index 2018cf7..fb8fc4b 100644 --- a/cmd/sbc_harness/CMakeLists.txt +++ b/cmd/sbc_harness/CMakeLists.txt @@ -27,6 +27,8 @@ pico_enable_stdio_uart(sbc_harness_objs 1) pico_enable_stdio_semihosting(sbc_harness_objs 0) pico_enable_stdio_rtt(sbc_harness_objs 0) +suppress_tinyusb_warnings() + # Analyze the stack ############################################################ add_stack_analysis(sbc_harness_stack.c sbc_harness_objs) |