diff options
| author | bors <bors@rust-lang.org> | 2016-05-28 19:19:27 -0700 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2016-05-28 19:19:27 -0700 |
| commit | 397cfaec0ce28289b0ab04ed6f6c3ba6ee1042ea (patch) | |
| tree | 3f7bbfc11d945a9a51e3a3edee46f7522aaad4c3 | |
| parent | 7746a334da364e5e4c25360cd52e97691cbddc08 (diff) | |
| parent | 0f3e8650f7f5a2658b639a3b84ee2946dd1fd98d (diff) | |
| download | rust-397cfaec0ce28289b0ab04ed6f6c3ba6ee1042ea.tar.gz rust-397cfaec0ce28289b0ab04ed6f6c3ba6ee1042ea.zip | |
Auto merge of #33848 - alexcrichton:android-gdb-sysroot, r=michaelwoerister
test: Use `set sysroot` for more NDK compatibility Recent versions of the Android NDK no longer ship debuggers like `arm-linux-androideabi-gdb`, but instead one prebuilt binary `gdb`. We can symlink this into place at least to get our detection still working, but it now needs to be told what the sysroot is so it can correctly do... something. Long story short, tests didn't pass with this change and after this change they pass.
| -rw-r--r-- | src/tools/compiletest/src/runtest.rs | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/src/tools/compiletest/src/runtest.rs b/src/tools/compiletest/src/runtest.rs index 4040b55ff98..953e060465a 100644 --- a/src/tools/compiletest/src/runtest.rs +++ b/src/tools/compiletest/src/runtest.rs @@ -440,9 +440,15 @@ actual:\n\ cmds = cmds.replace("run", "continue"); + let tool_path = match self.config.android_cross_path.to_str() { + Some(x) => x.to_owned(), + None => self.fatal("cannot find android cross path") + }; + // write debugger script let mut script_str = String::with_capacity(2048); script_str.push_str(&format!("set charset {}\n", Self::charset())); + script_str.push_str(&format!("set sysroot {}\n", tool_path)); script_str.push_str(&format!("file {}\n", exe_file.to_str().unwrap())); script_str.push_str("target remote :5039\n"); script_str.push_str(&format!("set solib-search-path \ @@ -515,11 +521,6 @@ actual:\n\ } } - let tool_path = match self.config.android_cross_path.to_str() { - Some(x) => x.to_owned(), - None => self.fatal("cannot find android cross path") - }; - let debugger_script = self.make_out_name("debugger.script"); // FIXME (#9639): This needs to handle non-utf8 paths let debugger_opts = |
