diff options
| author | Eduard-Mihai Burtescu <edy.burt@gmail.com> | 2016-10-19 08:00:00 +0300 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2016-10-19 08:00:00 +0300 |
| commit | fc8f9b950b93dc6a7b9e3945b7b36ded64a64e04 (patch) | |
| tree | 47aa4b4d3bfbf6fa781cfaf44ca11936611a807a /src/tools | |
| parent | 5c643435d157f7cd20f50a01fe246373970b3098 (diff) | |
| parent | 06d173adb76e3f5f30c168a4c48316823b08e650 (diff) | |
Rollup merge of #37182 - alexcrichton:appveyor, r=brson
Add AppVeyor configuration to the repo We hope to move to AppVeyor in the near future off of Buildbot + EC2. This adds an `appveyor.yml` configuration file which is ready to run builds on the auto branch. This is also accompanied with a few minor fixes to the build system and such to accomodate AppVeyor. The intention is that we're not switching over to AppVeyor entirely just yet, but rather we'll watch the builds for a week or so. If everything checks out then we'll start gating on AppVeyor instead of Buildbot!
Diffstat (limited to 'src/tools')
| -rw-r--r-- | src/tools/cargotest/main.rs | 14 | ||||
| -rw-r--r-- | src/tools/compiletest/src/runtest.rs | 5 |
2 files changed, 19 insertions, 0 deletions
diff --git a/src/tools/cargotest/main.rs b/src/tools/cargotest/main.rs index 633ff6271b7..978e991d508 100644 --- a/src/tools/cargotest/main.rs +++ b/src/tools/cargotest/main.rs @@ -36,6 +36,20 @@ const TEST_REPOS: &'static [Test] = &[Test { fn main() { + // One of the projects being tested here is Cargo, and when being tested + // Cargo will at some point call `nmake.exe` on Windows MSVC. Unfortunately + // `nmake` will read these two environment variables below and try to + // intepret them. We're likely being run, however, from MSYS `make` which + // uses the same variables. + // + // As a result, to prevent confusion and errors, we remove these variables + // from our environment to prevent passing MSYS make flags to nmake, causing + // it to blow up. + if cfg!(target_env = "msvc") { + env::remove_var("MAKE"); + env::remove_var("MAKEFLAGS"); + } + let args = env::args().collect::<Vec<_>>(); let ref cargo = args[1]; let out_dir = Path::new(&args[2]); diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 35b93392baf..e10420bf291 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -2105,12 +2105,17 @@ actual:\n\ .collect::<Vec<_>>().join(" "); cmd.env("IS_MSVC", "1") + .env("IS_WINDOWS", "1") .env("MSVC_LIB", format!("'{}' -nologo", lib.display())) .env("CC", format!("'{}' {}", self.config.cc, cflags)) .env("CXX", &self.config.cxx); } else { cmd.env("CC", format!("{} {}", self.config.cc, self.config.cflags)) .env("CXX", format!("{} {}", self.config.cxx, self.config.cflags)); + + if self.config.target.contains("windows") { + cmd.env("IS_WINDOWS", "1"); + } } let output = cmd.output().expect("failed to spawn `make`"); |
