Skip to content

RUSTFLAGS sometimes isn't passed to all rustc command lines #127727

@yurivict

Description

@yurivict

In some projects the RUSTFLAGS are ignored and not passed to rustc, at least on the i386 architecture.

Testcase: https://github.com/drahnr/cargo-spellcheck
cargo is called with the RUSTFLAGS environment variable containing "-C target-feature=+sse,+sse2".
Yet this RUSTFLAGS value is not passed to rustc.

Build log on i386.
It shows the build failure because the above RUSTFLAGS wasn't passed to the rustc command line.

Meta

$ rustc --version --verbose
rustc 1.79.0 (129f3b996 2024-06-10) (built from a source tarball)
binary: rustc
commit-hash: 129f3b9964af4d4a709d1383930ade12dfe7c081
commit-date: 2024-06-10
host: x86_64-unknown-freebsd
release: 1.79.0
LLVM version: 18.1.7

OS: FreeBSD 14.1
The builds are done in the FreeBSD ports framework.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions