use std::fmt;
use std::str::FromStr;
+use std::path::PathBuf;
#[derive(Clone, Copy, PartialEq, Debug)]
pub enum Mode {
CompileFail,
+ ParseFail,
RunFail,
RunPass,
RunPassValgrind,
Pretty,
DebugInfoGdb,
DebugInfoLldb,
- Codegen
+ Codegen,
+ Rustdoc,
+ CodegenUnits
}
impl FromStr for Mode {
fn from_str(s: &str) -> Result<Mode, ()> {
match s {
"compile-fail" => Ok(CompileFail),
+ "parse-fail" => Ok(ParseFail),
"run-fail" => Ok(RunFail),
"run-pass" => Ok(RunPass),
"run-pass-valgrind" => Ok(RunPassValgrind),
"debuginfo-lldb" => Ok(DebugInfoLldb),
"debuginfo-gdb" => Ok(DebugInfoGdb),
"codegen" => Ok(Codegen),
+ "rustdoc" => Ok(Rustdoc),
+ "codegen-units" => Ok(CodegenUnits),
_ => Err(()),
}
}
fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
fmt::Display::fmt(match *self {
CompileFail => "compile-fail",
+ ParseFail => "parse-fail",
RunFail => "run-fail",
RunPass => "run-pass",
RunPassValgrind => "run-pass-valgrind",
DebugInfoGdb => "debuginfo-gdb",
DebugInfoLldb => "debuginfo-lldb",
Codegen => "codegen",
+ Rustdoc => "rustdoc",
+ CodegenUnits => "codegen-units",
}, f)
}
}
pub run_lib_path: String,
// The rustc executable
- pub rustc_path: Path,
+ pub rustc_path: PathBuf,
- // The clang executable
- pub clang_path: Option<Path>,
+ // The rustdoc executable
+ pub rustdoc_path: PathBuf,
+
+ // The python executable
+ pub python: String,
// The llvm binaries path
- pub llvm_bin_path: Option<Path>,
+ pub llvm_bin_path: Option<PathBuf>,
// The valgrind path
pub valgrind_path: Option<String>,
pub force_valgrind: bool,
// The directory containing the tests to run
- pub src_base: Path,
+ pub src_base: PathBuf,
// The directory where programs should be built
- pub build_base: Path,
+ pub build_base: PathBuf,
// Directory for auxiliary libraries
- pub aux_base: Path,
+ pub aux_base: PathBuf,
// The name of the stage being built (stage1, etc)
pub stage_id: String,
pub filter: Option<String>,
// Write out a parseable log of tests that were run
- pub logfile: Option<Path>,
+ pub logfile: Option<PathBuf>,
// A command line to prefix program execution with,
// for running under valgrind
// Flags to pass to the compiler when building for the target
pub target_rustcflags: Option<String>,
- // Run tests using the JIT
- pub jit: bool,
-
// Target system to be tested
pub target: String,
pub lldb_version: Option<String>,
// Path to the android tools
- pub android_cross_path: Path,
+ pub android_cross_path: PathBuf,
// Extra parameter to run adb on arm-linux-androideabi
pub adb_path: String,