Auto merge of #10193 - larsbergstrom:use_rustflags, r=Ms2ger

Use rustflags

r? @Ms2ger

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="35" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/servo/10193)
<!-- Reviewable:end -->
This commit is contained in:
bors-servo 2016-03-25 22:42:17 +05:30
commit a211bd1a12
4 changed files with 4 additions and 4 deletions

View file

@ -1 +1 @@
2016-03-04
2016-03-23

View file

@ -1,2 +0,0 @@
#!/bin/sh
rustc -C link-args=-fuse-ld=gold "$@"

View file

@ -225,6 +225,8 @@ class MachCommands(CommandBase):
build_start = time()
env = self.build_env()
if android:
# Ensure Rust uses hard floats on Android
env['RUSTFLAGS'] = env.get('RUSTFLAGS', "") + " -C target-feature=+neon"
# Build OpenSSL for android
make_cmd = ["make"]
if jobs is not None:

View file

@ -385,7 +385,7 @@ class CommandBase(object):
# Don't run the gold linker if on Windows https://github.com/servo/servo/issues/9499
if self.config["tools"]["rustc-with-gold"] and sys.platform not in ("win32", "msys"):
if subprocess.call(['which', 'ld.gold'], stdout=PIPE, stderr=PIPE) == 0:
env['RUSTC'] = path.join(self.context.topdir, 'etc', 'rustc-with-gold')
env['RUSTFLAGS'] = env.get('RUSTFLAGS', "") + " -C link-args=-fuse-ld=gold"
return env