Skip to content

cargo build failed with RUSTFLAGS="--print sysroot" #4510

@mssun

Description

@mssun

cargo build will fail when passing RUSTFLAGS like --print sysroot, --print native-static-libs, etc.

I guess cargo will read stdout for other purposes?

For example:

$ cargo new hello_world --bin
     Created binary (application) `hello_world` project
$ cd hello_world
$ RUSTFLAGS="--print sysroot" cargo build
error: unexpected character in cfg `/`, expected parens, a comma, an identifier, or a string

Versions:

$ cargo -V
cargo 0.23.0-nightly (8118b02ac 2017-09-14)

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