Skip to content

Commit ff117fc

Browse files
shubhamdprestyled-commits
authored andcommitted
[ESP32] update document for app_main outside of main component (#37331)
* [ESP32] update document for app_main outside of main component Earlier, we needed to fetch and link the components separately. In #36883 we started using `add_prebuilt_library()` so there is no need to explicitly specify the executable component. * Restyled by prettier-markdown --------- Co-authored-by: Restyled.io <commits@restyled.io>
1 parent dc69689 commit ff117fc

File tree

1 file changed

+5
-7
lines changed

1 file changed

+5
-7
lines changed

docs/platforms/esp32/config_options.md

+5-7
Original file line numberDiff line numberDiff line change
@@ -15,14 +15,12 @@ CONFIG_LWIP_IPV4=n
1515
### Executable component not in "main" component
1616

1717
The ESP-IDF framework allows renaming the main component, which can be useful if
18-
you want to place the app_main() function in a different component.
18+
you want to place the `app_main()` function in a different component.
1919

2020
For required changes in the executable component, please refer to the
2121
[esp-idf documentation](https://docs.espressif.com/projects/esp-idf/en/stable/esp32/api-guides/build-system.html#renaming-main-component).
2222

23-
If you're building applications that support Matter and want to place app_main()
24-
in a component other than main, use the following command:
25-
26-
```
27-
idf.py -DEXECUTABLE_COMPONENT_NAME="your_component" build
28-
```
23+
You need to list the required components in `idf_component_register()`. If this
24+
module contains Matter related code, you may need to include
25+
`chip, app_update, spi_flash, and nvs_flash` as `PRIV_REQUIRES`, along with any
26+
other necessary dependencies.

0 commit comments

Comments
 (0)