From d5973b8b143bec2553f8dd3de253286710ff953c Mon Sep 17 00:00:00 2001 From: Ivan Grokhotkov Date: Fri, 19 Aug 2022 08:14:59 +0200 Subject: [PATCH] build system: add 'linux' component to common requirements 'linux' component provides some of the common header files, such as 'sys/queue.h' and 'sys/lock.h'. For chip targets, it is possible to include these files without having to add any extra requirements. With this change, the same behavior will apply for the linux target. --- components/spi_flash/CMakeLists.txt | 2 +- tools/cmake/build.cmake | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/components/spi_flash/CMakeLists.txt b/components/spi_flash/CMakeLists.txt index 260b353b48..7096cb57d0 100644 --- a/components/spi_flash/CMakeLists.txt +++ b/components/spi_flash/CMakeLists.txt @@ -8,7 +8,7 @@ if(${target} STREQUAL "linux") idf_component_register(SRCS "${srcs}" INCLUDE_DIRS include ${hal_dir}/include ${bootloader_support_dir}/include PRIV_INCLUDE_DIRS include/spi_flash - PRIV_REQUIRES linux partition_table) + PRIV_REQUIRES partition_table) return() endif() diff --git a/tools/cmake/build.cmake b/tools/cmake/build.cmake index 589d163fb7..265aaafbf6 100644 --- a/tools/cmake/build.cmake +++ b/tools/cmake/build.cmake @@ -206,7 +206,7 @@ function(__build_init idf_path) endforeach() if("${target}" STREQUAL "linux") - set(requires_common freertos log esp_rom esp_common) + set(requires_common freertos log esp_rom esp_common linux) idf_build_set_property(__COMPONENT_REQUIRES_COMMON "${requires_common}") else() # Set components required by all other components in the build