A component is evaluated with add_subdirectory() while the component that requires it is still being evaluated. CMake gives the new directory a copy of every variable and the directory properties visible at the call. The dependency therefore saw the variables of the requiring component, for example its srcs list, and appended to them. Record the variables and the directory properties visible at the first idf_component_include() call. Before a component is evaluated, a helper function unsets every other variable. It also sets the directory properties to the recorded values. The requiring component keeps its own variables and properties. This fixes two leaks in the current tree. esp_coex registered its linker.lf through a leaked ldfragments variable in builds without coexistence. esp_driver_cam received private include directories of esp_cam_sensor. The isolation can be disabled with IDF_COMPONENT_SCOPE_ISOLATION=NO. COMPONENT_BUILD_DIR is now set for every component, next to COMPONENT_DIR. The breaking-changes entry about recursive evaluation is replaced with a Component Scope section in the design documentation. The section also states that the isolation is not complete. The variables visible when the record is made stay visible in every component, so a component must still initialize the variables it sets. Signed-off-by: Frantisek Hrbata <frantisek.hrbata@espressif.com>
Documentation Source Folder
This folder contains source files of ESP-IDF documentation available in English and Chinese.
The sources do not render well in GitHub and some information is not visible without building the documentation.
Use the actual documentation, which is generated within about 20 minutes of each commit:
Hosted Documentation
- English: https://docs.espressif.com/projects/esp-idf/en/latest/
- Chinese: https://docs.espressif.com/projects/esp-idf/zh_CN/latest/
After clicking any link to ESP-IDF Programming Guide, go to the top of the sidebar, then make sure you have the correct Espressif chip (target) and ESP-IDF version selected in the dropdown menus. You can also find a link at the bottom right to download the HTML version as a zip for offline reading.
Building Documentation
The documentation is built using the Python package esp-docs, which can be installed by running:
pip install esp-docs
For a summary of available options, run:
build-docs --help
For more information, see the esp-docs documentation at https://github.com/espressif/esp-docs/blob/master/README.md