nuttx-apps icon indicating copy to clipboard operation
nuttx-apps copied to clipboard

[EXPERIMENTAL] Makefile: EXTRA_APPS_LIBS and EXTRA_APPS_INCPATHS vars

Open zdebanos opened this issue 5 months ago • 7 comments

The variables are to be used to mainly by the export rule to export external libraries (.a files) and respective include paths.

The exported external libraries are packed together in the libapps.a library (basically, every .o files are extracted and then packed together).

Signed-off-by: Stepan Pressl [email protected]

Summary

Improving the build system with these variables so all the symbols from the external libraries can be packed together within the libapps.a library. This is particularly useful, when we'd like to use this external library and all of its symbols in the nuttx export.

I'm not expecting to be this merged, yet. But I'd like to start a debate over possible solutions and discuss other solutions and improvements. I'm thinking about generalizing the variables over multiple Makefiles, so any directory in the NuttX project would have some kind of a variable. Or possibly only one variable.

A different way of doing this is to just all of these libraries separately, and not withing libapps.a, etc.

Also, external libraries are, in the current state, linked using the EXTRA_LIBS variable. But that is done only in the last stage of the build and the linker only picks symbols that are needed. In the end, the exported library only has a subset of all the symbols.

Also cmake support must be added.

zdebanos avatar Aug 09 '25 08:08 zdebanos