Incorrect binary size after compilation.
There is a magic word in linker command file : NOLOAD
look here for more details :
https://ftp.gnu.org/old-gnu/Manuals/ld-2.9.1/html_node/ld_21.html
excerpt
(NOLOAD)
The `(NOLOAD)’ directive will mark a section to not be loaded at run time. The linker will process the section normally, but will mark it so that a program loader will not load it into memory. For example, in the script sample below, the ROM section is addressed at memory location `0’ and does not need to be loaded when the program is run. The contents of the ROM section will appear in the linker output file as usual.
SECTIONS {
ROM 0 (NOLOAD) : { ... }
...
}