Skip to content

Commit b65502f

Browse files
committed
fix(bt): suppress -Wunterminated-string-initialization warning
1 parent 243c587 commit b65502f

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

components/bt/CMakeLists.txt

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1022,3 +1022,14 @@ if(NOT CMAKE_BUILD_EARLY_EXPANSION)
10221022
"${CMAKE_CURRENT_LIST_DIR}/host/bluedroid/btc/profile/std/gap/btc_gap_ble.c"
10231023
PROPERTIES COMPILE_FLAGS "${jump_table_opts}")
10241024
endif()
1025+
1026+
if(CMAKE_C_COMPILER_ID MATCHES "GNU" AND CMAKE_C_COMPILER_VERSION VERSION_GREATER 15.0)
1027+
if(CONFIG_BT_BLUEDROID_ENABLED)
1028+
set_source_files_properties("host/bluedroid/device/controller.c"
1029+
PROPERTIES COMPILE_FLAGS "-Wno-unterminated-string-initialization")
1030+
endif()
1031+
if(CONFIG_BT_NIMBLE_ENABLED AND CONFIG_BT_NIMBLE_MESH)
1032+
set_source_files_properties("host/nimble/nimble/nimble/host/mesh/src/prov.c"
1033+
PROPERTIES COMPILE_FLAGS "-Wno-unterminated-string-initialization")
1034+
endif()
1035+
endif()

0 commit comments

Comments
 (0)