mirror of
https://github.com/espressif/esp-idf.git
synced 2024-10-05 20:47:46 -04:00
doc: cmake: Add description of ESP_PLATFORM variable
Ref: https://github.com/espressif/esp-idf/pull/2601
This commit is contained in:
parent
4782aafc4c
commit
39dc1b4ff3
@ -349,6 +349,8 @@ The following variables are set at the project level, but available for use in c
|
||||
* Else, if the project is located inside a Git repository, the output of git describe will be used.
|
||||
* Otherwise, ``PROJECT_VER`` will be "1".
|
||||
|
||||
- ``ESP_PLATFORM``: Set to 1 whenever the ESP-IDF build system is being used.
|
||||
|
||||
If you modify any of these variables inside ``CMakeLists.txt`` then this will not prevent other components from building but it may make your component hard to build and/or debug.
|
||||
|
||||
- ``COMPONENT_ADD_INCLUDEDIRS``: Paths, relative to the component directory, which will be added to the include search path for
|
||||
@ -903,6 +905,9 @@ import it from other projects. Studying the library's CMakeLists.txt and build s
|
||||
It is also possible to wrap a third-party library to be used as a component in this manner. For example, the :component:`mbedtls` component is a wrapper for
|
||||
Espressif's fork of `mbedtls <https://github.com/ARMmbed/mbedtls>`_. See its :component_file:`component CMakeLists.txt <mbedtls/CMakeLists.txt>`.
|
||||
|
||||
The CMake variable ``ESP_PLATFORM`` is set to 1 whenever the ESP-IDF build system is being used. Tests such as ``if (ESP_PLATFORM)`` can be used in generic CMake code if special IDF-specific logic is required.
|
||||
|
||||
|
||||
Using ESP-IDF in Custom CMake Projects
|
||||
======================================
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user