ports: add ARMv7-A SMP Linux build scripts(A5,A7,A9) - #674
Conversation
Two lines named assembly sources that eclipse-threadx#672 renamed. That change moved twenty-nine files under gnu trees from .s to .S, because GAS runs the C preprocessor on .S and not on .s: in a .s file every # line is a comment, so a #define is never substituted and an #if/#else pair emits both arms. Four files were silently doing the wrong thing as a result, including ports_smp/cortex_a7_smp/gnu/src/tx_thread_smp_unprotect.s, which ignored all four of its own feature macros. These scripts had worked around the same defect with -x assembler-with-cpp rather than hitting it, which was correct when they were written. With the rename the flag is redundant and the lowercase names no longer resolve, so cortex_a5_smp/build_threadx.sh failed with "cc1: fatal error: tx_initialize_low_level.s: No such file or directory". The other seven references to those two files across these three scripts already named them with a capital S. Verified with the pinned Arm GNU 14.3.rel1 rather than the 13.2 that a distro package supplies: build_threadx.sh and build_threadx_sample.sh both succeed for a5, a7 and a9, all three link a sample_threadx.out, and scripts/check_gcc.sh passes end to end with its example stage reading 45 of 45, up from 42. Assisted-by: Claude Opus 5 <noreply@anthropic.com>
393e064 to
f4c4982
Compare
|
Thanks for this — these are exactly the three ports I've rebased your branch onto current Heads up on your local clone: the rebase rewrote the commit SHAs, so before you touch the branch again you'll want rather than pulling, or git will try to merge the old and new histories together. What the extra commit changes, and whyTwo lines used
The reason for the rename is that GAS runs the C preprocessor on So after #672 the extension carries the preprocessing and no caller has to remember the flag — and the lowercase names no longer resolve at all. Unmodified on the new base, The rebase itself was clean — no conflicts, and the nine files you add are untouched. Verified rather than assumedWith the pinned Arm GNU 14.3.rel1 toolchain, on the rebased branch:
Your Two things about the checks, neither of them your faultNothing had actually run on this PR before now. The checks list showed only
One last note, purely informational: your verification used GCC 13.2.1, which is what the distro All seven checks are green and the PR is ready to merge. Please do give the extra commit a look first, and shout if you'd rather it were done differently. |
|
Thanks for updating the branch and explaining everything. I checked the extra commit and understand the .S changes after #672. I also noted the GCC 14.3 version and the updated assembly count of 840. Thanks for rerunning the checks. |
Summary
crt0.Sto each example and link with-nostartfiles, keepingVectorsas the entry point.Closes #605
Verification
build_threadx.shandbuild_threadx_sample.shcompleted for A5, A7, and A9; all three sample images linked.scripts/check_clang.shcompleted with 724/724 assembly sources, all feature-macro checks, all common C profiles, and 45/45 example builds passing.Relevant output from
check_clang.sh:NOTE: These examples were link-verified only and were not run on hardware.