As of esp-idf v4.1, the idf_component_register macro is one of the preferred ways to register components into CMakeLists.txt. However, if folder name matches between a user and an esp-idf component (common names e.g.: "log" or "bt"), CMake chooses the first folder it finds and adds it to the include directory list, ignoring the other.
Is there any solution to this problem, other than renaming the user component? Are namespaces possible on the esp-idf build system?
Thank you very much,
Xavi
Name conflicts between user and esp-idf components
Re: Name conflicts between user and esp-idf components
From esp-idf build system documentation:
Does that mean it is not possible to have two components with the same name, one on esp-idf and one on the project, but different purposes by design?If two or more of these directories contain component sub-directories with the same name, the component in the last place searched is used. This allows, for example, overriding ESP-IDF components with a modified version by copying that component from the ESP-IDF components directory to the project components directory and then modifying it there. If used in this way, the ESP-IDF directory itself can remain untouched.
-
- Posts: 9051
- Joined: Thu Nov 26, 2015 4:08 am
Re: Name conflicts between user and esp-idf components
Sorry for not seeing this earlier. Yes, this is true and by design.
Re: Name conflicts between user and esp-idf components
Thanks, Sprite! Then we will rename our components to something else.
Who is online
Users browsing this forum: No registered users and 230 guests