diff --git a/components/esp_driver_usb_serial_jtag/CMakeLists.txt b/components/esp_driver_usb_serial_jtag/CMakeLists.txt index e9b99f50840..fdc21c085ed 100644 --- a/components/esp_driver_usb_serial_jtag/CMakeLists.txt +++ b/components/esp_driver_usb_serial_jtag/CMakeLists.txt @@ -1,5 +1,9 @@ idf_build_get_property(target IDF_TARGET) +if(${target} STREQUAL "linux") + return() # This component is not supported by the POSIX/Linux simulator +endif() + set(srcs) set(include "include") @@ -9,15 +13,9 @@ if(CONFIG_SOC_USB_SERIAL_JTAG_SUPPORTED) "src/usb_serial_jtag_connection_monitor.c") endif() -if(${target} STREQUAL "linux") - set(priv_requires esp_ringbuf esp_timer) -else() - set(priv_requires esp_driver_gpio esp_ringbuf esp_pm esp_timer esp_hal_usb) -endif() - idf_component_register(SRCS ${srcs} INCLUDE_DIRS ${include} - PRIV_REQUIRES "${priv_requires}" + PRIV_REQUIRES esp_driver_gpio esp_ringbuf esp_pm esp_timer esp_hal_usb LDFRAGMENTS "linker.lf" ) diff --git a/components/esp_usb_cdc_rom_console/CMakeLists.txt b/components/esp_usb_cdc_rom_console/CMakeLists.txt index a33caad17e5..a4309eb57e4 100644 --- a/components/esp_usb_cdc_rom_console/CMakeLists.txt +++ b/components/esp_usb_cdc_rom_console/CMakeLists.txt @@ -1,5 +1,9 @@ idf_build_get_property(target IDF_TARGET) +if(${target} STREQUAL "linux") + return() # This component is not supported by the POSIX/Linux simulator +endif() + set(srcs) if(CONFIG_ESP_CONSOLE_USB_CDC)