mirror of
https://github.com/espressif/esp-idf.git
synced 2026-10-02 03:00:34 +03:00
build: Adds support for universal Clang toolchain
This commit is contained in:
@@ -734,7 +734,11 @@ if(CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_DISABLE AND CONFIG_BT_NIMBLE_ENABLED)
|
||||
endif()
|
||||
|
||||
if(NOT CMAKE_BUILD_EARLY_EXPANSION)
|
||||
set(jump_table_opts "-fjump-tables")
|
||||
if(NOT (CMAKE_C_COMPILER_ID MATCHES "Clang") )
|
||||
set(jump_table_opts "${jump_table_opts} -ftree-switch-conversion")
|
||||
endif()
|
||||
set_source_files_properties("${CMAKE_CURRENT_LIST_DIR}/host/bluedroid/bta/hf_ag/bta_ag_cmd.c"
|
||||
"${CMAKE_CURRENT_LIST_DIR}/host/bluedroid/btc/profile/std/gap/btc_gap_ble.c"
|
||||
PROPERTIES COMPILE_FLAGS "-fjump-tables -ftree-switch-conversion")
|
||||
PROPERTIES COMPILE_FLAGS "${jump_table_opts}")
|
||||
endif()
|
||||
|
||||
@@ -512,7 +512,7 @@ static xt_handler set_isr_hlevel_wrapper(int mask, xt_handler f, void *arg)
|
||||
static void IRAM_ATTR interrupt_hlevel_disable(void)
|
||||
{
|
||||
assert(xPortGetCoreID() == CONFIG_BTDM_CTRL_PINNED_TO_CORE);
|
||||
assert(hli_cb.nested != ~0);
|
||||
assert(hli_cb.nested != UCHAR_MAX);
|
||||
uint32_t status = hli_intr_disable();
|
||||
if (hli_cb.nested++ == 0) {
|
||||
hli_cb.status = status;
|
||||
|
||||
@@ -550,7 +550,7 @@ esp_err_t esp_ble_gap_set_security_param(esp_ble_sm_param_t param_type,
|
||||
if((param_type != ESP_BLE_SM_CLEAR_STATIC_PASSKEY) && ( value == NULL || len < sizeof(uint8_t) || len > sizeof(uint32_t))) {
|
||||
return ESP_ERR_INVALID_ARG;
|
||||
}
|
||||
if((param_type == ESP_BLE_SM_SET_STATIC_PASSKEY)) {
|
||||
if(param_type == ESP_BLE_SM_SET_STATIC_PASSKEY) {
|
||||
uint32_t passkey = 0;
|
||||
for(uint8_t i = 0; i < len; i++)
|
||||
{
|
||||
|
||||
@@ -898,14 +898,14 @@ tBTM_STATUS BTM_EnableTestMode(void)
|
||||
}
|
||||
|
||||
/* put device to connectable mode */
|
||||
if (!BTM_SetConnectability(BTM_CONNECTABLE, BTM_DEFAULT_CONN_WINDOW,
|
||||
BTM_DEFAULT_CONN_INTERVAL) == BTM_SUCCESS) {
|
||||
if (BTM_SetConnectability(BTM_CONNECTABLE, BTM_DEFAULT_CONN_WINDOW,
|
||||
BTM_DEFAULT_CONN_INTERVAL) != BTM_SUCCESS) {
|
||||
return BTM_NO_RESOURCES;
|
||||
}
|
||||
|
||||
/* put device to discoverable mode */
|
||||
if (!BTM_SetDiscoverability(BTM_GENERAL_DISCOVERABLE, BTM_DEFAULT_DISC_WINDOW,
|
||||
BTM_DEFAULT_DISC_INTERVAL) == BTM_SUCCESS) {
|
||||
if (BTM_SetDiscoverability(BTM_GENERAL_DISCOVERABLE, BTM_DEFAULT_DISC_WINDOW,
|
||||
BTM_DEFAULT_DISC_INTERVAL) != BTM_SUCCESS) {
|
||||
return BTM_NO_RESOURCES;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user