Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CMake error at 381, of component.cmake #25

Open
Rajath-sensesemi opened this issue Jul 13, 2024 · 4 comments
Open

CMake error at 381, of component.cmake #25

Rajath-sensesemi opened this issue Jul 13, 2024 · 4 comments

Comments

@Rajath-sensesemi
Copy link

After adding wolfssl using idf.py add dependency, and when I select wolfssl in Esp-tls options, the project doesn't build, the issue it says is cmake error at line 31 of component.cmake of esp idf framework.
_component_get_property function invoked with incorrect arguments

@gojimmypi
Copy link

Hi @Rajath-sensesemi and thanks for your interest in wolfSSL.

Please see #23 (comment) and espressif/esp-idf#13966

I'd like to help you with wolfSSL; can you please provide more details on your requirements? Do you think the Managed Component would work?

@Rajath-sensesemi
Copy link
Author

I want to use wolfssl for my essp idf project, after adding it as a managed component using this idf.py add-dependency "wolfssl/wolfssl^5.6.6-stable-update2-esp32", the project builds successfully, but when i try to use wolfssl features, by selecting esp-tls ---> wolfssl, after selecting this if i try to build, i get an error like this:
CMake Error at C:/Esp-idf-5.2.2/frameworks/esp-idf-v5.2.2/tools/cmake/component.cmake:381 (__component_get_property):
__component_get_property Function invoked with incorrect arguments for
function named: __component_get_property
Call Stack (most recent call first):
C:/Esp-idf-5.2.2/frameworks/esp-idf-v5.2.2/components/esp-tls/CMakeLists.txt:26 (idf_component_get_property)
I tried in many ways to solve this but it did not work, please give a solution

@gojimmypi
Copy link

when i try to use wolfssl features, by selecting esp-tls ---> wolfssl, after selecting this if i try to build, i get an error:

ah, yes: thanks for that. I should add a note. The wolfssl component can be used without configuring the esp-tls component in the ESP-IDF. See the examples.

The only purpose of Espressif esp-tls layer is to abstract the code and allow either mbedTLS or wolfSSL to be switched in and used when calling esp-tls functions. As you've seen, the wolfSSL integration has been neglected. I'm working on fixing that,

If for some reason you have existing code that must use the esp-tls, I'm working on ESP-IDF updates that will permit this. The work is on my my_522 branch as discussed in gojimmypi/esp-idf#1.

Although the work specifically mentions PlatformIO, the update will of course also work for the regular ESP-IDF. Note that my current work is on the v5.2.2 branch, but I had originally started on the latest master (on my wolfssl branch. I had encountered some unresolvable problems with PlatformIO and had to go back to v5.2.2.

The specific solution for the esp-wolfssl is found here where various names and locations of wolfSSL may be found:

    # esp-idf/components/esp-tls/CMakeLists.txt
    idf_component_get_property(wolfssl esp-wolfssl COMPONENT_LIB)

Note that using the idf.py add-dependency "wolfssl/wolfssl managed component is not the same as this esp-wolfssl repository which has considerably older code and is installed manually.

Depending on your requirements, I can help you proceed with a specific library. Can you provide more details on your project? Also feel free to reach out to [email protected] for priority support.

@Rajath-sensesemi
Copy link
Author

Thank you for the clarity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants