Skip to content

Commit 0654444

Browse files
committed
compiletest: rename run_lib_path -> target_run_lib_path
1 parent ae93635 commit 0654444

File tree

6 files changed

+11
-14
lines changed

6 files changed

+11
-14
lines changed

src/tools/compiletest/src/common.rs

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,13 +260,10 @@ pub struct Config {
260260
/// For example:
261261
/// - `/home/ferris/rust/build/x86_64-unknown-linux-gnu/stage1/lib/rustlib/i686-unknown-linux-gnu/lib`
262262
///
263-
/// FIXME: maybe rename this to reflect (1) which target platform (target, not host), and (2)
264-
/// what "run libraries" are against.
265-
///
266263
/// FIXME: this is very under-documented in conjunction with the `remote-test-client` scheme and
267264
/// `RUNNER` scheme to actually run the target executable under the target platform environment,
268265
/// cf. [`Self::remote_test_client`] and [`Self::runner`].
269-
pub run_lib_path: Utf8PathBuf,
266+
pub target_run_lib_path: Utf8PathBuf,
270267

271268
/// Path to the *staged* `rustc`-under-test. Unless forced, this `rustc` is *staged*, and must
272269
/// not be confused with [`Self::stage0_rustc_path`].

src/tools/compiletest/src/lib.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -376,7 +376,7 @@ fn parse_config(args: Vec<String>) -> Config {
376376
|| env::var_os("RUSTC_TEST_FAIL_FAST").is_some(),
377377

378378
host_compile_lib_path: make_absolute(opt_path(matches, "compile-lib-path")),
379-
run_lib_path: make_absolute(opt_path(matches, "run-lib-path")),
379+
target_run_lib_path: make_absolute(opt_path(matches, "run-lib-path")),
380380
rustc_path: opt_path(matches, "rustc-path"),
381381
cargo_path: matches.opt_str("cargo-path").map(Utf8PathBuf::from),
382382
stage0_rustc_path: matches.opt_str("stage0-rustc-path").map(Utf8PathBuf::from),
@@ -688,7 +688,7 @@ fn common_inputs_stamp(config: &Config) -> Stamp {
688688

689689
stamp.add_dir(&src_root.join("src/etc/natvis"));
690690

691-
stamp.add_dir(&config.run_lib_path);
691+
stamp.add_dir(&config.target_run_lib_path);
692692

693693
if let Some(ref rustdoc_path) = config.rustdoc_path {
694694
stamp.add_path(&rustdoc_path);

src/tools/compiletest/src/runtest.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1060,7 +1060,7 @@ impl<'test> TestCx<'test> {
10601060
rustdoc.current_dir(current_dir);
10611061
rustdoc
10621062
.arg("-L")
1063-
.arg(self.config.run_lib_path.as_path())
1063+
.arg(self.config.target_run_lib_path.as_path())
10641064
.arg("-L")
10651065
.arg(aux_dir)
10661066
.arg("-o")
@@ -1151,7 +1151,7 @@ impl<'test> TestCx<'test> {
11511151

11521152
self.compose_and_run(
11531153
test_client,
1154-
self.config.run_lib_path.as_path(),
1154+
self.config.target_run_lib_path.as_path(),
11551155
Some(aux_dir.as_path()),
11561156
None,
11571157
)
@@ -1166,7 +1166,7 @@ impl<'test> TestCx<'test> {
11661166

11671167
self.compose_and_run(
11681168
wr_run,
1169-
self.config.run_lib_path.as_path(),
1169+
self.config.target_run_lib_path.as_path(),
11701170
Some(aux_dir.as_path()),
11711171
None,
11721172
)
@@ -1181,7 +1181,7 @@ impl<'test> TestCx<'test> {
11811181

11821182
self.compose_and_run(
11831183
program,
1184-
self.config.run_lib_path.as_path(),
1184+
self.config.target_run_lib_path.as_path(),
11851185
Some(aux_dir.as_path()),
11861186
None,
11871187
)

src/tools/compiletest/src/runtest/debuginfo.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ impl TestCx<'_> {
9090

9191
let debugger_run_result = self.compose_and_run(
9292
cdb,
93-
self.config.run_lib_path.as_path(),
93+
self.config.target_run_lib_path.as_path(),
9494
None, // aux_path
9595
None, // input
9696
);
@@ -313,7 +313,7 @@ impl TestCx<'_> {
313313
gdb.args(debugger_opts).env("PYTHONPATH", pythonpath);
314314

315315
debugger_run_result =
316-
self.compose_and_run(gdb, self.config.run_lib_path.as_path(), None, None);
316+
self.compose_and_run(gdb, self.config.target_run_lib_path.as_path(), None, None);
317317
}
318318

319319
if !debugger_run_result.status.success() {

src/tools/compiletest/src/runtest/run_make.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -175,7 +175,7 @@ impl TestCx<'_> {
175175
.env("HOST_RUSTC_DYLIB_PATH", &self.config.host_compile_lib_path)
176176
// Provide the directory to libraries that might be needed to run binaries created
177177
// by a compiler invoked by the recipe.
178-
.env("TARGET_EXE_DYLIB_PATH", &self.config.run_lib_path)
178+
.env("TARGET_EXE_DYLIB_PATH", &self.config.target_run_lib_path)
179179
// Provide the target.
180180
.env("TARGET", &self.config.target)
181181
// Some tests unfortunately still need Python, so provide path to a Python interpreter.

src/tools/compiletest/src/rustdoc_gui_test.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ fn incomplete_config_for_rustdoc_gui_test() -> Config {
5959
bless: Default::default(),
6060
fail_fast: Default::default(),
6161
host_compile_lib_path: Utf8PathBuf::default(),
62-
run_lib_path: Utf8PathBuf::default(),
62+
target_run_lib_path: Utf8PathBuf::default(),
6363
rustc_path: Utf8PathBuf::default(),
6464
cargo_path: Default::default(),
6565
stage0_rustc_path: Default::default(),

0 commit comments

Comments
 (0)