nuttx/tools
Marco Casaroli 295f0e373c tools/nxflat: Leave ARM unwind tables out of an NXFLAT module.
CONFIG_UNWINDER_ARM compiles everything with -funwind-tables, modules
included, so each module carries .ARM.exidx and .ARM.extab.  The NXFLAT
link scripts do not name them, and ldnxflat placed them in D-Space, where
the first R_ARM_PREL31 entry stopped the conversion:

  ldnxflat: arm relocation 42 at D-Space 00000018 is not handled

That relocation cannot be handled: an exidx entry is an offset from itself
to a function in I-Space, and the distance between the two segments is only
known when the loader places them.  Nothing unwinds through a module
either, since the unwinder only reads the firmware's own table.

So ldnxflat leaves both sections out of the images, and with them the
relocations against them, as it already does for sections it does not
place.  A module without unwind tables converts exactly as before.

On mps3-an547:nsh under QEMU with CONFIG_UNWINDER_ARM and examples/nxflat,
the modules failed to convert; now they convert and errno, hello, mutex,
pthread and struct run.  The eleven modules of tools/nxflat/testsuite.sh
convert to the same bytes as before.

Assisted-by: Claude Code:claude-opus-5-5
Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
2026-09-28 16:45:09 -03:00
..
ameba arch/arm/ameba: resolve the asdk toolchain per-IC 2026-07-17 08:30:47 -03:00
bcm2711
bl602
ci tools/ci: Build the NXFLAT configurations that convert a module. 2026-09-27 11:25:12 -03:00
codeowners
cxd56 tools/cxd56/mkspk: proper resources free on error. 2026-08-17 14:17:37 +08:00
esp32
esp32c3
esp32s2
esp32s3
espressif cmake: Use NUTTX(_DIR/_BIN_DIR) instead CMAKE(_SRC_DIR/_BIN_DIR) 2026-08-09 11:13:08 -03:00
imx9
imxrt1180 tools/imxrt1180: Add a standalone C program for simple AHAB container creation 2026-09-19 22:38:45 +08:00
licensing tools: escape Python string backslashes 2026-08-21 20:07:26 +08:00
lwl
mpfs
nix
nxflat tools/nxflat: Leave ARM unwind tables out of an NXFLAT module. 2026-09-28 16:45:09 -03:00
pic32
pynuttx tools/pynuttx: Update the preemption field annotations. 2026-09-07 21:06:53 +08:00
rp23xx
rp2040 tools: rp2040: Drop uninitialized name length check 2026-07-10 12:39:44 +08:00
simwifi
zds
.gitignore tools/nxflat: Add an Apache-licensed NXFLAT converter. 2026-09-27 11:25:12 -03:00
aarch64-unknown-nuttx-macho.json
aarch64-unknown-nuttx.json
abi_check.py
b16.c
bdf-converter.c
board_romfs_mkpasswd.sh sched,fs,docs: support setuid sudo helper 2026-08-18 15:57:52 +08:00
btdecode.sh
build-globals.sh
callstack.py
cfgdefine.c
cfgdefine.h
cfgparser.c
cfgparser.h
check_passwd_keys.sh !boards: enforce secure ROMFS passwd and TEA key setup 2026-07-09 22:41:11 +08:00
checkkconfig.py
checkpatch.sh
checkrelease.sh
CMakeLists.txt
cmpconfig.c
cnvwindeps.c
Config.mk tools: pass TOPDIR in SDIR_template and MAKE_template 2026-09-17 13:49:05 +08:00
configure.bat
configure.c
configure.sh !tools/mkpasswd: PBKDF2 host tool and ROMFS passwd build integration 2026-07-21 20:19:14 +08:00
configure_completion.bash
convert-comments.c
copydir.bat
copydir.sh
coredump.py
csvparser.c
csvparser.h
D.defs
define.bat
define.sh
detab.c
Directories.mk
discover.py
doreleasenotes.py
Export.mk
find_symbol_callers.sh
flash_writer.py
FlatLibs.mk
gcov.py
gdbserver.py
gen_passwd_keys.sh boards: add CI ROMFS passwd credentials and refresh docs 2026-07-09 22:41:11 +08:00
gencromfs.c
host_info_dump.py
host_info_parse.py
i486-unknown-nuttx.json tools/rust: Fix softfloat abi target spec name 2026-08-13 12:41:54 +02:00
ide_exporter.py tools: escape Python string backslashes 2026-08-21 20:07:26 +08:00
incdir.bat
incdir.c
incdir.sh
indent.sh
initialconfig.c
jlink-nuttx.c
kasan_global.py
kconfig.bat
kconfig2html.c tools: kconfig2html: Explain blank-line guard 2026-08-21 20:08:18 +08:00
KernelLibs.mk
LibTargets.mk
link.bat
link.sh
lowhex.c
macar-qcs.sh
Make.defs
Makefile.host tools/nxflat: Add an Apache-licensed NXFLAT converter. 2026-09-27 11:25:12 -03:00
merge_config.py
mkallsyms.py libs/libc/symtab: fix bogus symbol names for out-of-range addresses 2026-08-05 21:51:25 +08:00
mkallsyms.sh
mkconfig.c
mkconfigvars.sh
mkctags.sh
mkdeps.c
mkexport.sh
mkfsdata.pl
mkfsdata.py
mknulldeps.sh
mkpasswd.c !tools/mkpasswd: PBKDF2 host tool and ROMFS passwd build integration 2026-07-21 20:19:14 +08:00
mkromfsimg.sh
mksymtab.c
mksyscall.c
mkversion.c tools/mkversion: Fix missing free in case of error. 2026-08-14 08:03:15 +02:00
mkwindeps.sh
netusb.sh
noteinfo.c
nxstyle.c tools/nxstyle: allow the OpenGL and TinyGL identifier prefixes 2026-09-25 18:18:10 +08:00
nxstyle_sweep.sh tools/nxstyle: add a script to check a whole tree at once 2026-07-28 02:43:24 +08:00
nxtagspkgsfetch.sh
parsecallstack.py
parsememdump.py
parsetrace.py
passwd_keys.mk !tools/mkpasswd: PBKDF2 host tool and ROMFS passwd build integration 2026-07-21 20:19:14 +08:00
pre-commit
process_config.py
process_config.sh
promptpasswd.sh !tools/mkpasswd: PBKDF2 host tool and ROMFS passwd build integration 2026-07-21 20:19:14 +08:00
ProtectedLibs.mk
refresh.sh tools/refresh.sh: Fix multi-argument parsing 2026-09-10 16:26:53 +02:00
rmcr.c
Rust.defs
sethost.sh
showsize.sh
simbridge.sh
simhostroute.sh
simlaunch.sh
size_report.py
splashscreen_converter.py
stackusage.py
stm32_pinmap_tool.py
Swift.defs
testbuild.ps1
testbuild.sh
toolchain.cmake.export tools/export: prefix each linker script in toolchain.cmake. 2026-09-01 17:41:42 +08:00
uncrustify.cfg tools/uncrustify: Update uncrustify for better support 2026-07-17 15:00:06 -03:00
Unix.mk tools/nxflat: Add an Apache-licensed NXFLAT converter. 2026-09-27 11:25:12 -03:00
unlink.bat
unlink.sh
update_romfs_password.sh sched,fs,docs: support setuid sudo helper 2026-08-18 15:57:52 +08:00
version.sh
Win.mk
x86_64-unknown-nuttx-macho.json
x86_64-unknown-nuttx.json tools/rust: Fix softfloat abi target spec name 2026-08-13 12:41:54 +02:00
xmlrpc_test.py
Zig.defs tools/Zig.defs: Fix Zig builds on sim:x86_64 2026-07-20 09:36:56 +08:00
zipme.sh