rustbuild: Verify flags are configured

Building with `--target foo` should fail because that target wasn't actually
validated.
This commit is contained in:
Alex Crichton 2016-04-05 10:00:51 -07:00
parent c86e7c4950
commit 4e758722f4

View File

@ -119,4 +119,16 @@ $ pacman -R cmake && pacman -S mingw-w64-x86_64-cmake
}
}
}
for host in build.flags.host.iter() {
if !build.config.host.contains(host) {
panic!("specified host `{}` is not in the ./configure list", host);
}
}
for target in build.flags.target.iter() {
if !build.config.target.contains(target) {
panic!("specified target `{}` is not in the ./configure list",
target);
}
}
}