linking local embedded library when code generation
Mostrar comentarios más antiguos
Hello. I am generating c++ program from my s-function in simulink for processor in the loop (PIL) simulation. In the s-function, I utilized a library for window x64.
I hope to link the same library but for arm64 linux. My local embedded board already has the library. I tried to link this library but failed.
I tried several ways.
- to attach linking option like -L"PATH to the library" -lmylib. because the generated compile command put this option before the enumeration of objects files. So linking failed
- to attach external library options. I think this is the standard way to link external library however, the program failed to find the shared object (so.0) file / I tried to fix this problem, I couldn't
At the moment, the best way to link the library is add the linking option at the end of the compile command like
CXX CPPFLAGS OBJ LIB + <MY linking option>.
Because PIL updates makefile right before the simulation, it seems like that it's impossible to edit makefile in the local embedded board.
So the point is how to link local library when generating code using code generator.
Respuesta aceptada
Más respuestas (0)
Categorías
Más información sobre Simulink Coder en Centro de ayuda y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!