mirror of
https://github.com/espressif/esp-idf.git
synced 2025-07-30 18:57:19 +02:00
refactor(hal/usb): Fix USB OTG compilation dependency
Update "hal/CMakeLists.txt" so that USB OTG related HAL files depend on the "SOC_USB_OTG_SUPPORTED" capability.
This commit is contained in:
@ -234,6 +234,13 @@ if(NOT BOOTLOADER_BUILD)
|
|||||||
list(APPEND srcs "huk_hal.c")
|
list(APPEND srcs "huk_hal.c")
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
|
if(CONFIG_SOC_USB_OTG_SUPPORTED)
|
||||||
|
list(APPEND srcs
|
||||||
|
"usb_hal.c"
|
||||||
|
"usb_dwc_hal.c"
|
||||||
|
"usb_phy_hal.c")
|
||||||
|
endif()
|
||||||
|
|
||||||
if(${target} STREQUAL "esp32")
|
if(${target} STREQUAL "esp32")
|
||||||
list(APPEND srcs
|
list(APPEND srcs
|
||||||
"touch_sensor_hal.c"
|
"touch_sensor_hal.c"
|
||||||
@ -244,23 +251,17 @@ if(NOT BOOTLOADER_BUILD)
|
|||||||
if(${target} STREQUAL "esp32s2")
|
if(${target} STREQUAL "esp32s2")
|
||||||
list(APPEND srcs
|
list(APPEND srcs
|
||||||
"touch_sensor_hal.c"
|
"touch_sensor_hal.c"
|
||||||
"usb_hal.c"
|
|
||||||
"usb_phy_hal.c"
|
|
||||||
"xt_wdt_hal.c"
|
"xt_wdt_hal.c"
|
||||||
"esp32s2/cp_dma_hal.c"
|
"esp32s2/cp_dma_hal.c"
|
||||||
"esp32s2/touch_sensor_hal.c"
|
"esp32s2/touch_sensor_hal.c")
|
||||||
"usb_dwc_hal.c")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(${target} STREQUAL "esp32s3")
|
if(${target} STREQUAL "esp32s3")
|
||||||
list(APPEND srcs
|
list(APPEND srcs
|
||||||
"touch_sensor_hal.c"
|
"touch_sensor_hal.c"
|
||||||
"usb_hal.c"
|
|
||||||
"usb_phy_hal.c"
|
|
||||||
"xt_wdt_hal.c"
|
"xt_wdt_hal.c"
|
||||||
"esp32s3/touch_sensor_hal.c"
|
"esp32s3/touch_sensor_hal.c"
|
||||||
"esp32s3/rtc_cntl_hal.c"
|
"esp32s3/rtc_cntl_hal.c")
|
||||||
"usb_dwc_hal.c")
|
|
||||||
endif()
|
endif()
|
||||||
|
|
||||||
if(${target} STREQUAL "esp32c3")
|
if(${target} STREQUAL "esp32c3")
|
||||||
|
Reference in New Issue
Block a user