cancel
Showing results for 
Search instead for 
Did you mean: 

Recompile stdlib (libc/newlib) with position independent option

matteoricciutelli_enel
Associate II

Dear board,

I am seeking to have a position independent firmware, and my latest struggle is to have the stdlib functions like sprintf to be position independent as well.

As far as I have seen from the disassembly by default the library functions load data and jumps from absolute memory addresses instead of being relative to the PC or reference the global offset table which I set in my project.

How can I recompile the standard libraries bundled with stm32CubeIde ( I am using an m33 stm32 mcu) to make the code position independent?


Matteo

0 REPLIES 0