From 01dd2dd45d59a4ce0247fc31612439247cc10e1e Mon Sep 17 00:00:00 2001 From: Ivan Grokhotkov Date: Tue, 8 Feb 2022 21:22:36 +0100 Subject: [PATCH] driver: disable sdmmc in cmake based on soc_caps --- components/driver/CMakeLists.txt | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/components/driver/CMakeLists.txt b/components/driver/CMakeLists.txt index 3c043f9217..eb0f8662dd 100644 --- a/components/driver/CMakeLists.txt +++ b/components/driver/CMakeLists.txt @@ -51,14 +51,15 @@ if(CONFIG_SOC_PCNT_SUPPORTED) list(APPEND srcs "pcnt.c") endif() +if(CONFIG_SOC_SDMMC_HOST_SUPPORTED) + list(APPEND srcs "sdmmc_transaction.c" "sdmmc_host.c") +endif() + if(${target} STREQUAL "esp32") - # SDMMC and MCPWM are in ESP32 only. list(APPEND srcs "dac_common.c" "sdio_slave.c" - "sdmmc_host.c" "i2s.c" - "sdmmc_transaction.c" "touch_sensor_common.c" "esp32/touch_sensor.c" "esp32/adc.c" @@ -82,9 +83,7 @@ if(IDF_TARGET STREQUAL "esp32s2") endif() if(${target} STREQUAL "esp32s3") - list(APPEND srcs "sdmmc_host.c" - "sdmmc_transaction.c" - "usb_serial_jtag.c" + list(APPEND srcs "usb_serial_jtag.c" "spi_slave_hd.c" "touch_sensor_common.c" "esp32s3/touch_sensor.c"