aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--components/servo/Cargo.lock2
-rw-r--r--components/util/opts.rs30
-rw-r--r--ports/cef/Cargo.lock2
-rw-r--r--ports/gonk/Cargo.lock2
-rw-r--r--python/servo/command_base.py3
5 files changed, 25 insertions, 14 deletions
diff --git a/components/servo/Cargo.lock b/components/servo/Cargo.lock
index 47422c35832..df4759a0ca3 100644
--- a/components/servo/Cargo.lock
+++ b/components/servo/Cargo.lock
@@ -72,7 +72,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "angle"
version = "0.1.0"
-source = "git+https://github.com/emilio/angle?branch=servo#b31e70ef5cb675582de910d09b0c385ea2000a64"
+source = "git+https://github.com/emilio/angle?branch=servo#ebe29683474ac13a448cc03f772d33179c030cc2"
dependencies = [
"libc 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
]
diff --git a/components/util/opts.rs b/components/util/opts.rs
index 2a146a27642..78ac6f9cee6 100644
--- a/components/util/opts.rs
+++ b/components/util/opts.rs
@@ -635,43 +635,51 @@ pub fn from_cmdline_args(args: &[String]) -> ArgumentParsingResult {
};
let tile_size: usize = match opt_match.opt_str("s") {
- Some(tile_size_str) => tile_size_str.parse().expect("Error parsing option: -s"),
+ Some(tile_size_str) => tile_size_str.parse()
+ .unwrap_or_else(|err| args_fail(&format!("Error parsing option: -s ({})", err))),
None => 512,
};
let device_pixels_per_px = opt_match.opt_str("device-pixel-ratio").map(|dppx_str|
- dppx_str.parse().expect("Error parsing option: --device-pixel-ratio")
+ dppx_str.parse()
+ .unwrap_or_else(|err| args_fail(&format!("Error parsing option: --device-pixel-ratio ({})", err)))
);
let mut paint_threads: usize = match opt_match.opt_str("t") {
- Some(paint_threads_str) => paint_threads_str.parse().expect("Error parsing option: -t"),
+ Some(paint_threads_str) => paint_threads_str.parse()
+ .unwrap_or_else(|err| args_fail(&format!("Error parsing option: -t ({})", err))),
None => cmp::max(num_cpus::get() * 3 / 4, 1),
};
// If only the flag is present, default to a 5 second period for both profilers.
let time_profiler_period = opt_match.opt_default("p", "5").map(|period| {
- period.parse().expect("Error parsing option: -p")
+ period.parse().unwrap_or_else(|err| args_fail(&format!("Error parsing option: -p ({})", err)))
});
let mem_profiler_period = opt_match.opt_default("m", "5").map(|period| {
- period.parse().expect("Error parsing option: -m")
+ period.parse().unwrap_or_else(|err| args_fail(&format!("Error parsing option: -m ({})", err)))
});
let gpu_painting = !FORCE_CPU_PAINTING && opt_match.opt_present("g");
let mut layout_threads: usize = match opt_match.opt_str("y") {
- Some(layout_threads_str) => layout_threads_str.parse().expect("Error parsing option: -y"),
+ Some(layout_threads_str) => layout_threads_str.parse()
+ .unwrap_or_else(|err| args_fail(&format!("Error parsing option: -y ({})", err))),
None => cmp::max(num_cpus::get() * 3 / 4, 1),
};
let nonincremental_layout = opt_match.opt_present("i");
let random_pipeline_closure_probability = opt_match.opt_str("random-pipeline-closure-probability").map(|prob|
- prob.parse().expect("Error parsing option: --random-pipeline-closure-probability")
+ prob.parse().unwrap_or_else(|err| {
+ args_fail(&format!("Error parsing option: --random-pipeline-closure-probability ({})", err))
+ })
);
let random_pipeline_closure_seed = opt_match.opt_str("random-pipeline-closure-seed").map(|seed|
- seed.parse().expect("Error parsing option: --random-pipeline-closure-seed")
+ seed.parse().unwrap_or_else(|err| {
+ args_fail(&format!("Error parsing option: --random-pipeline-closure-seed ({})", err))
+ })
);
let mut bubble_inline_sizes_separately = debug_options.bubble_widths;
@@ -682,17 +690,17 @@ pub fn from_cmdline_args(args: &[String]) -> ArgumentParsingResult {
}
let devtools_port = opt_match.opt_default("devtools", "6000").map(|port| {
- port.parse().expect("Error parsing option: --devtools")
+ port.parse().unwrap_or_else(|err| args_fail(&format!("Error parsing option: --devtools ({})", err)))
});
let webdriver_port = opt_match.opt_default("webdriver", "7000").map(|port| {
- port.parse().expect("Error parsing option: --webdriver")
+ port.parse().unwrap_or_else(|err| args_fail(&format!("Error parsing option: --webdriver ({})", err)))
});
let initial_window_size = match opt_match.opt_str("resolution") {
Some(res_string) => {
let res: Vec<u32> = res_string.split('x').map(|r| {
- r.parse().expect("Error parsing option: --resolution")
+ r.parse().unwrap_or_else(|err| args_fail(&format!("Error parsing option: --resolution ({})", err)))
}).collect();
Size2D::typed(res[0], res[1])
}
diff --git a/ports/cef/Cargo.lock b/ports/cef/Cargo.lock
index df4a7788f60..6cecb400a9a 100644
--- a/ports/cef/Cargo.lock
+++ b/ports/cef/Cargo.lock
@@ -57,7 +57,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "angle"
version = "0.1.0"
-source = "git+https://github.com/emilio/angle?branch=servo#b31e70ef5cb675582de910d09b0c385ea2000a64"
+source = "git+https://github.com/emilio/angle?branch=servo#ebe29683474ac13a448cc03f772d33179c030cc2"
dependencies = [
"libc 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
]
diff --git a/ports/gonk/Cargo.lock b/ports/gonk/Cargo.lock
index e7c940e4002..f1afd0fa28c 100644
--- a/ports/gonk/Cargo.lock
+++ b/ports/gonk/Cargo.lock
@@ -50,7 +50,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index"
[[package]]
name = "angle"
version = "0.1.0"
-source = "git+https://github.com/emilio/angle?branch=servo#b31e70ef5cb675582de910d09b0c385ea2000a64"
+source = "git+https://github.com/emilio/angle?branch=servo#ebe29683474ac13a448cc03f772d33179c030cc2"
dependencies = [
"libc 0.2.4 (registry+https://github.com/rust-lang/crates.io-index)",
]
diff --git a/python/servo/command_base.py b/python/servo/command_base.py
index 35c35cfe6e9..cf25bc41927 100644
--- a/python/servo/command_base.py
+++ b/python/servo/command_base.py
@@ -261,6 +261,9 @@ class CommandBase(object):
if not self.config["tools"]["system-rust"] \
or self.config["tools"]["rust-root"]:
env["RUST_ROOT"] = self.config["tools"]["rust-root"]
+ # Add mingw64 binary path before rust paths to avoid conflict with libstdc++-6.dll
+ if sys.platform == "msys":
+ extra_path += [path.join(os.sep, "mingw64", "bin")]
# These paths are for when rust-root points to an unpacked installer
extra_path += [path.join(self.config["tools"]["rust-root"], "rustc", "bin")]
extra_lib += [path.join(self.config["tools"]["rust-root"], "rustc", "lib")]