Skip to content

Cannot pass CG_RUSTFLAGS when building sysroot #491

Closed
@darcagn

Description

@darcagn

I've successfully gotten libc/std building targetting SuperH (SH4/Dreamcast). I need to build sysroot with -matomic-model=soft-imask for it to work properly.

I can insert rustflags.push_str(" -Cllvm-args=-matomic-model=soft-imask"); at this line:

Or insert context.add_command_line_option("-matomic-model=soft-imask"); at this line:

And I seem to get the desired effect. But I'd prefer not to patch things if I can do it without.

If I do CG_RUSTFLAGS=-Cllvm-args=-matomic-model=soft-imask y.sh build it does not seem to honor it when building the sysroot. To test this I can put gibberish flags like -blahblah and get no error when the same would give me errors when building a normal project with y.sh cargo build. Am I doing something wrong here or is this something not supported yet?

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workinggood first issueGood for newcomers

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions