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
Add cross-compiled library to RIOT OS #16799
Comments
Hi @forellendev, have a look at https://github.com/RIOT-OS/RIOT/blob/master/examples/bindist/README.md. I think that fits your use case. |
Thank you @miri64, I'll try it out! |
Unfortunately, I get the following error:
I cross-compiled a library on my ubuntu-x86_64 system to the ARM Cortex-M4 with the arm-none-eabi toolchain and would like to use this cross-compiled library within RIOT OS. Is this actually possible with the arm-non-eabi toolchain? |
You don't need to set the toolchain. It just need to be in your |
Thank you @miri64, I forgot to outcomment a path variable. I thought a little about manual cross-compiling the library, but now want to try to add it as a package (and hopefully as a new pkg to RIOT OS). I have the following Makefile in a new pkg folder:
The problem is that nothing is downloaded at all and my bin/native/libsafecrypto folders are empty. |
Did you include |
I did add this command to the Make of the application. Do you think it would be possible to fetch the project via PKG_URL and PKG_VERSION, but then apply a custom cross-compilation script to this download next? Maybe this library leads to some troubles. |
Yes, using custom compile scripts is what we often do e.g. with Lines 20 to 34 in bfe64fe
Basically, the make targets are the files you want to have generated, the command section of those targets provide said script (you can also call external scripts there) provide the instructions how this file will be generated. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. If you want me to ignore this issue, please mark it with the "State: don't stale" label. Thank you for your contributions. |
@forellendev did my last comment solve your problem? |
Let's assume the problem has been solved. If not, please reopen the issue - we are happy to help. |
Hi guys,
I tried adding a larger library to RIOT OS, but found that it isn't optimized enough. I compiled the library for the appropriate device architecture that I'm using RIOT on, but I have no idea how to add the compiled library to the project? Should I use PKG or MODULE in this case?
Best regards
The text was updated successfully, but these errors were encountered: