Conversation
The Makefile said "Most of these do no build yet" and built three of the nine. Eight build and convert: errno, hello, longjmp, mutex, pthread, signal, struct and task. What had kept most of them out was read-only data reached PC-relative, which the tree now compiles GOT-relative. BUILD_SUBDIRS was assigned but never read, so mutex, pthread and task stayed out even where the configuration allowed them. The conditionals now append to SUBDIRS, which the recipes walk. hello++ stays out: two of its four modules convert, the third needs R_ARM_TARGET1 from the converter and the fourth needs an iostream. Assisted-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
install -D is GNU's, and creates the leading directories. The BSD install that macOS carries has no such option and fails the build of every module. mkdir -p does that part, and the mode stays explicit. longjmp is built only where CONFIG_ARCH_SETJMP_H is set. It imports setjmp() and longjmp(), which the firmware exports only when it supplies its own implementation; without the guard the kernel link fails on two undefined references. Verified on lm3s6965-ek:qemu-nxflat with the option off and on. Assisted-by: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Marco Casaroli <marco.casaroli@gmail.com>
casaroli
force-pushed
the
nxflat-tests-enable
branch
from
September 27, 2026 09:49
1101a6a to
f397be5
Compare
🔗 Cross-repo PR dependenciesThe read-only Build run reported the following dependent PR(s) and fetched head SHA(s): CI run: https://github.com/apache/nuttx-apps/actions/runs/36310578373 |
| # longjmp imports setjmp() and longjmp(), which the symbol table exports only | ||
| # where NuttX supplies them itself. | ||
|
|
||
| ifeq ($(CONFIG_ARCH_SETJMP_H),y) |
Contributor
There was a problem hiding this comment.
move to the first patch
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
depends-on: [apache/nuttx/pull/20377]
Summary
apps/examples/nxflat/testscarries nine test modules and the Makefile built three, under a comment saying "Most of these do no build yet". Eight build and convert, and between them they cover a function pointer in D-Space, a callback from the firmware, a non-local return, threads, task creation and thread-localerrno.What had kept most of them out was read-only data reached PC-relative, which apache/nuttx#20377 makes the tree compile GOT-relative.
hello++stays out: two of its four modules convert, the third needsR_ARM_TARGET1from the converter in that PR, and the fourth needs aniostream.The other two changes are a latent bug and a portability one.
BUILD_SUBDIRSwas assigned and never read, somutex,pthreadandtaskwere excluded even where the configuration allowed them. Andinstall -Dis a GNU extension: the BSDinstallthat macOS carries fails the build of every module with its usage message.Impact
Only a board that sets
CONFIG_EXAMPLES_NXFLATis affected, and its ROMFS grows by roughly 9 KB for the five further modules.Testing
lm3s6965-ek:qemu-nxflat, both ways round thelongjmpguard. WithCONFIG_ARCH_SETJMP_Hoff the ROMFS holds the other seven modules and the image links, where before it failed onsetjmpandlongjmp. With it on, all eight run underqemu-system-arm -M lm3s6965evbtoEnd-of-Test.. Exit-ing,structreportingpf = 0x13335 (vs 0x13335) PASSand thenIn dummyfunc() -- PASS.Built with BSD
installrather than GNU, which is what made the portability fix necessary.tools/checkpatch.sh -c -u -m -gpasses.