Skip to content

(v0.9) Change rustc-abi in custom targets from x86-softfloat to softfloat#568

Open
phil-opp wants to merge 2 commits into
v0.9-basefrom
fix/rustc-abi-softfloat
Open

(v0.9) Change rustc-abi in custom targets from x86-softfloat to softfloat#568
phil-opp wants to merge 2 commits into
v0.9-basefrom
fix/rustc-abi-softfloat

Conversation

@phil-opp

@phil-opp phil-opp commented Jul 6, 2026

Copy link
Copy Markdown
Member

The Rust PR rust-lang/rust#157151 removed the x86-softfloat compatibility alias. Nightlies from
2026-07-05 onward reject "rustc-abi": "x86-softfloat" with:

invalid rustc abi: 'x86-softfloat'. allowed values:
'x86-sse2', 'powerpc-spe', 'softfloat'

Switch the three custom JSON target specs to the canonical softfloat value.

Created with Claude Code

@phil-opp phil-opp changed the base branch from main to v0.9-base July 6, 2026 08:35
@phil-opp

phil-opp commented Jul 6, 2026

Copy link
Copy Markdown
Member Author

Sorry for the noise. Opened against the wrong base branch at first

@phil-opp phil-opp changed the title fix/rustc abi softfloat Change rustc-abi in custom targets from x86-softfloat to softfloat Jul 6, 2026
@phil-opp phil-opp changed the title Change rustc-abi in custom targets from x86-softfloat to softfloat Change rustc-abi in custom targets from x86-softfloat to softfloat Jul 6, 2026
@phil-opp phil-opp changed the title Change rustc-abi in custom targets from x86-softfloat to softfloat (v0.9) Change rustc-abi in custom targets from x86-softfloat to softfloat Jul 6, 2026
rust-lang/rust#157151 removed the `x86-softfloat` compatibility alias
that was introduced in rust-lang/rust#151154. Nightlies from
2026-07-05 onward reject `"rustc-abi": "x86-softfloat"` with:

    invalid rustc abi: 'x86-softfloat'. allowed values:
    'x86-sse2', 'powerpc-spe', 'softfloat'

Switch the three custom JSON target specs to the canonical
`softfloat` value.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@phil-opp phil-opp force-pushed the fix/rustc-abi-softfloat branch from 62d9e4a to c510724 Compare July 6, 2026 08:42
The newer nightly (>= 2026-07-05) requires `-Zunstable-options` to load
custom JSON target specs. `cargo objcopy` runs an internal
`rustc --target x86_64-bootloader.json --print cfg` probe (via rustc-cfg)
that doesn't pass the flag and ignores RUSTFLAGS, so it fails to load the
target, silently exits 0, and never produces `bootloader.bin` -- causing
the later QEMU step to fail with "No such file or directory".

`rust-objcopy` is the same tool from cargo-binutils but skips the target
probe (we pass explicit ELF input/output paths), so it works without the
flag.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@phil-opp phil-opp requested a review from Freax13 July 6, 2026 10:53

@Freax13 Freax13 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants