Commit 62b4713
build: force bash for recipes (Linux dash printf \x1f trap)
What:
Makefile: add `SHELL := /bin/bash`.
Why:
The first Tier C boot-smoke run on the Linux runner failed building the first
user crate:
rust-lld: error: cannot find linker script link.ld\x1f-Clink-arg=-z\x1f...
GNU make defaults SHELL to /bin/sh; on Ubuntu that is dash, whose printf does
not support `\xHH` hex escapes. Every user-crate rule joins rustflags into
CARGO_ENCODED_RUSTFLAGS with `printf '%s\x1f%s' ...`; under dash the 0x1F
separators come through as literal "\x1f" text, so cargo passes the whole
rustflags string as one unsplit linker arg and the linker-script path mangles.
macOS /bin/sh is bash (printf understands \x), so this was invisible locally.
Forcing bash -- present on both macOS and Ubuntu -- makes the Linux build match.
Out of scope:
No recipe text changes; one SHELL assignment fixes every printf-based rule at
once. Any further Linux-portability issues down the boot-smoke path surface on
the next run.
Verification:
- /bin/bash -c "printf '%s\x1f%s' A B" | od -> 41 1f 42 (the real 0x1F byte).
- make fs-service under SHELL:=/bin/bash -> builds clean on macOS (no
regression).
- The Linux build is confirmed by re-running the boot-smoke workflow.
Staged files:
Makefile
Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>1 parent ff4d74b commit 62b4713
1 file changed
Lines changed: 10 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
18 | 28 | | |
19 | 29 | | |
20 | 30 | | |
| |||
0 commit comments