- Use $(PROJECT_ROOT) or a custom variable (e.g., $(CRL_DIR)) defined in Project Files > Settings > Project Paths/Variables.
- In model config: Include directories = $(CRL_DIR)/include
How to bring absolute path of code replacement library to makefile generated during Software In Loop build?
35 views (last 30 days)
Show older comments
I use a Code replacement library but in a directory outside the Simulink Project root folder. Hence, the path is metioned relatively. This creates a problem in build because, the INCLUDES_BUILDINFO contains now relative path.
simple question is: How to absolutize the relative path of code replacement library in makefile generated during Software In Loop build?
note: Code generation is successful, only Build fails.
0 Comments
Answers (1)
Yashwanth
on 14 Jan 2026 at 9:57
Hi Noufal,
If you’re managing paths via Simulink Project, reference project variables in your include directories (e.g., Custom Code > Include directories) and let Simulink expand to absolute paths during build:
During code generation and build, Simulink replaces these tokens with absolute paths, which resolves the makefile issue.
0 Comments
See Also
Categories
Find more on Test Model Components in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!