[BUG] Standalone service build can succeed without its declared entry point #2
Labels
No labels
bug
ci
docs
duplicate
enhancement
help wanted
invalid
performance
phase-6
question
refactor
security
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
erix/e2fsd#2
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
The standalone e2fsd CI freestanding build does not select the repository linker script. On Rust 1.97.1, the existing command returns success while rust-lld reports a missing default entry symbol. The retained local ELF has entry address zero and lacks the declared e2fsd_entry symbol. This command therefore does not establish a correctly linked standalone service.
Reproduction
Use e2fsd production sources from commit
f3eec737b7, the unchanged exact Git dependency revisions, and Rust 1.97.1. Prepare original sources through Integration e2b1cf5995bcf6334839cda9a013e90fa97787d5, then run from the repository:An explicitly selected target output directory was used for the retained local checks; adjust the inspection paths accordingly. The same omitted-script configuration was also built once with --all-features. Both commands returned zero with the same missing-entry warning; both retained ELF files have entry address zero. No guest or boot-image execution is part of this reproduction.
Expected and actual behavior
Expected: the standalone link uses the existing linker.ld, whose ENTRY(e2fsd_entry), text placement and __e2fs_state_arena_start definition describe this binary. Any linker warning must fail the purported warning-free build.
Actual: the workflow's freestanding build step calls cargo build without the linker script. The selected linker instead searches for _start. Rust 1.97.1 reports
rust-lld: cannot find entry symbol _start; not setting start address, followed by a note that linker_messages ignores -D warnings. The build returns zero. The local runtime/all-feature ELF headers show entry zero, and the declared e2fsd_entry symbol is absent.The proposed correction uses cargo rustc --bin e2fsd and passes the existing linker script plus --fatal-warnings to the final link. It adds no production entry point or capability. A standalone link with placeholder deployment capacities is not a packaged, runnable service image.
Environment and identity
f3eec737b7. Only a new host quota test and its registration were present during local validation; freestanding production code and linker.ld were unchanged. The standalone workflow's existing build command at this base is the affected route.Evidence and prior checks
Standalone CI run 171 at the exact base commit completed successfully. Its complete Rust job 19216 log used Rust 1.93.1 and the same missing-script command. The full Rust and Markdown logs contain no warning lines. This historical log must not be described as warningful, and its ELF artifact was not available for direct inspection.
The current local Rust 1.97.1 runtime/all-feature commands both returned zero but failed warning-free acceptance. Their complete original logs, statuses and ELF files are retained. The runtime ELF SHA-256 is b8c20ca6b6522a1b469214812b14eb5f381d38d9618f66db37570f152255a252; the all-feature ELF SHA-256 is babeef33d118b5e3daf36137d8a40545d5841d36d94a611a8144a38eada95b0a. Each had a 600-second hard and 120-second output-stall budget.
The host quota test and both full 259-test suites passed. Host/freestanding Clippy and rustdoc were warning-free. These successes did not validate the final freestanding ELF entry. The corrected explicit linker-script invocation passes runtime and all-feature debug/release links without warnings; each entry address is 0x64000000 and equals the defined e2fsd_entry symbol, and each contains the required arena symbol. The correction is published in signed commit
829c225767and WIP PR #3. The final host suites contain 261 passing tests each, including explicit checker selection and failure/evidence precedence checks; current-revision CI is tracked separately. No connection to the guest quota timeout is asserted.Tracking
Owner: e2fsd standalone CI build configuration; related component audit #1 and the separate quota VM timeout. Preserve the exact helper pin and existing service feature selection. Regression acceptance requires warning-free runtime/all-feature debug/release links whose ELF entry equals the defined e2fsd_entry symbol and which contain the required arena symbol. Keep the original false-success evidence. This correction does not establish full image-build or guest completion acceptance.