Best Practise for adding files to IDF standard component
Posted: Mon Nov 04, 2019 6:06 pm
Hi,
I have ported the AWS IoT SDK as an ESP32 IDF component.
I am using the mbedtls component of IDF, but have to add one header file (threading_alt.h) and change some options in /esp32/idf/components/mbedtls/port/include/mbedtls/esp_config.h.
My question is, what is the "best" way of doing this ?
Should I place the threading_alt.h file in the idf component dirs ?
Change esp_config.h in place ?
Copy the whole mbedtls dir to my projects component dir ?
I can't figure out a way to provide the additional include paths / settings to the mbedtls component due to my lack of knowledge in CMake.
Changing the components files will render them non functional if the code referenced in threading_alt.h is not provided by the app.
The threading_alt.h file is dependent on existing #ifdefs in mbedtls, but I don't know how to place the file in my apps / the sdks component dir and reference it from the mbedtls' build.
To me it seems, that I can only define the require of mbedtls by my app, but how do I tell the medtls components build about the location of the threading_alt.h file ?
Any guidance helps.
I have ported the AWS IoT SDK as an ESP32 IDF component.
I am using the mbedtls component of IDF, but have to add one header file (threading_alt.h) and change some options in /esp32/idf/components/mbedtls/port/include/mbedtls/esp_config.h.
My question is, what is the "best" way of doing this ?
Should I place the threading_alt.h file in the idf component dirs ?
Change esp_config.h in place ?
Copy the whole mbedtls dir to my projects component dir ?
I can't figure out a way to provide the additional include paths / settings to the mbedtls component due to my lack of knowledge in CMake.
Changing the components files will render them non functional if the code referenced in threading_alt.h is not provided by the app.
The threading_alt.h file is dependent on existing #ifdefs in mbedtls, but I don't know how to place the file in my apps / the sdks component dir and reference it from the mbedtls' build.
To me it seems, that I can only define the require of mbedtls by my app, but how do I tell the medtls components build about the location of the threading_alt.h file ?
Any guidance helps.