pussuw opened a new pull request, #14364: URL: https://github.com/apache/nuttx/pull/14364
## Summary This fixes issue where empty and unallocated sections are left without a VMA. Some relocations depend on the section VMA being set even if there is no data there, as the binary can refer to the symbols. Linker defined symbols do not contain data -> they can produce empty sections. This issue is seen when building a loadable file which declares _sctors / _sdtors linker defined symbols for ctor/dtor sections which are empty. crt0 references these symbols, so they need to be relocated, but the section VMA is not set -> they go outside of the addressable range of the user binary causing a potential crash. ## Impact Impact is on loadable files, such as .elf files. ## Testing rv-virt:knsh64 + modifications: -CONFIG_BINFMT_ELF_EXECUTABLE=y +CONFIG_HAVE_CXX=y More about the subject can be found here https://github.com/apache/nuttx/pull/12853 Removing libelf broke RISC-V C++ support again. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected]
