Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Apply RUSTFLAGS arguments to rustc builds #2241

Merged
merged 3 commits into from
Mar 17, 2016
Merged

Commits on Mar 16, 2016

  1. Apply RUSTFLAGS env var to rustc builds

    This passes RUSTFLAGS to rustc builds for the target architecture.
    
    We don't want to pass the RUSTFLAGS args to multiple architectures because
    they may contain architecture-specific flags. Ideally, the scheme
    we would use would treat plugins and build scripts - which may not
    be for the target architecture - consistently. Unfortunately it's
    quite difficult in the current Cargo architecture to seperately
    identify build scripts, plugins and their dependencies from
    code used by the target.
    
    So the scheme here is very simple:
    
    1) If --target is not specified, RUSTFLAGS applies to all builds.
    2) If --target is specified, RUSTFLAGS only applies to builds
       with the Kind::Target target kind, which indicates build units
       derived from the requested --target.
    
    Closes rust-lang#2112
    brson committed Mar 16, 2016
    Configuration menu
    Copy the full SHA
    e17933e View commit details
    Browse the repository at this point in the history
  2. Configuration menu
    Copy the full SHA
    e4baac0 View commit details
    Browse the repository at this point in the history
  3. Add rustflags support to config files

    `build.rustflags` is treated exactly like `RUSTFLAGS`.
    
    It is a list, so argument lists with spaces work.
    
    `RUSTFLAGS` takes precedent, then `build.rustflags`.
    brson committed Mar 16, 2016
    Configuration menu
    Copy the full SHA
    2f01868 View commit details
    Browse the repository at this point in the history