mynewt-newt icon indicating copy to clipboard operation
mynewt-newt copied to clipboard

newt/build: Workaround for whole-archive flag

Open m-gorecki opened this issue 6 months ago • 1 comments

Flag whole-archive is not supported on Mac and it was causing CI failures. Now instead of using this flag with .a file we just pass a text file with list of all object files from package to the linker. So now it looks like this: @pkg.list instead of: --whole-archive pkg.a --no-whole-archive

Passing list of object files will result in pulling unreferenced object code just like in case of whole-archive flag and should work with all compilers.

m-gorecki avatar Jun 02 '25 14:06 m-gorecki

This seems to work for arm builds and pic32 (except for Windows). Mac not tested by me.

kasjer avatar Jun 06 '25 19:06 kasjer