diff options
| author | Josh Triplett <josh@joshtriplett.org> | 2021-12-06 14:09:24 -0800 |
|---|---|---|
| committer | Josh Triplett <josh@joshtriplett.org> | 2022-01-09 13:22:50 -0800 |
| commit | cd626fec2bcfa6b78d34a1ae023943c8a15a6641 (patch) | |
| tree | c7067f69adca54d329ae71926a9f3f7b4354eb8b /src | |
| parent | 0fb1c371d4a14f9ce7a721d8aea683a6e6774f6c (diff) | |
| download | rust-cd626fec2bcfa6b78d34a1ae023943c8a15a6641.tar.gz rust-cd626fec2bcfa6b78d34a1ae023943c8a15a6641.zip | |
Stabilize -Z print-link-args as --print link-args
We have stable options for adding linker arguments; we should have a stable option to help debug linker arguments.
Diffstat (limited to 'src')
7 files changed, 9 insertions, 9 deletions
diff --git a/src/test/run-make-fulldeps/codegen-options-parsing/Makefile b/src/test/run-make-fulldeps/codegen-options-parsing/Makefile index 39e9a9bdd6b..f1410b69b3f 100644 --- a/src/test/run-make-fulldeps/codegen-options-parsing/Makefile +++ b/src/test/run-make-fulldeps/codegen-options-parsing/Makefile @@ -24,8 +24,8 @@ all: $(RUSTC) -C lto dummy.rs # Should not link dead code... - $(RUSTC) -Z print-link-args dummy.rs 2>&1 | \ + $(RUSTC) --print link-args dummy.rs 2>&1 | \ $(CGREP) -e '--gc-sections|-z[^ ]* [^ ]*<ignore>|-dead_strip|/OPT:REF' # ... unless you specifically ask to keep it - $(RUSTC) -Z print-link-args -C link-dead-code dummy.rs 2>&1 | \ + $(RUSTC) --print link-args -C link-dead-code dummy.rs 2>&1 | \ $(CGREP) -ve '--gc-sections|-z[^ ]* [^ ]*<ignore>|-dead_strip|/OPT:REF' diff --git a/src/test/run-make-fulldeps/interdependent-c-libraries/Makefile b/src/test/run-make-fulldeps/interdependent-c-libraries/Makefile index 1268022e37b..0a50859cdaa 100644 --- a/src/test/run-make-fulldeps/interdependent-c-libraries/Makefile +++ b/src/test/run-make-fulldeps/interdependent-c-libraries/Makefile @@ -11,4 +11,4 @@ all: $(call NATIVE_STATICLIB,foo) $(call NATIVE_STATICLIB,bar) $(RUSTC) foo.rs $(RUSTC) bar.rs - $(RUSTC) main.rs -Z print-link-args + $(RUSTC) main.rs --print link-args diff --git a/src/test/run-make-fulldeps/link-arg/Makefile b/src/test/run-make-fulldeps/link-arg/Makefile index d7c9fd27112..0360ede7625 100644 --- a/src/test/run-make-fulldeps/link-arg/Makefile +++ b/src/test/run-make-fulldeps/link-arg/Makefile @@ -1,5 +1,5 @@ -include ../tools.mk -RUSTC_FLAGS = -C link-arg="-lfoo" -C link-arg="-lbar" -Z print-link-args +RUSTC_FLAGS = -C link-arg="-lfoo" -C link-arg="-lbar" --print link-args all: $(RUSTC) $(RUSTC_FLAGS) empty.rs | $(CGREP) lfoo lbar diff --git a/src/test/run-make-fulldeps/metadata-flag-frobs-symbols/Makefile b/src/test/run-make-fulldeps/metadata-flag-frobs-symbols/Makefile index 09e6ae0bbf7..3ffbba9444b 100644 --- a/src/test/run-make-fulldeps/metadata-flag-frobs-symbols/Makefile +++ b/src/test/run-make-fulldeps/metadata-flag-frobs-symbols/Makefile @@ -6,5 +6,5 @@ all: $(RUSTC) bar.rs \ --extern foo1=$(TMPDIR)/libfoo-a.rlib \ --extern foo2=$(TMPDIR)/libfoo-b.rlib \ - -Z print-link-args + --print link-args $(call RUN,bar) diff --git a/src/test/run-make-fulldeps/no-builtins-lto/Makefile b/src/test/run-make-fulldeps/no-builtins-lto/Makefile index b9688f16c64..2e41be39d5d 100644 --- a/src/test/run-make-fulldeps/no-builtins-lto/Makefile +++ b/src/test/run-make-fulldeps/no-builtins-lto/Makefile @@ -6,4 +6,4 @@ all: # Build an executable that depends on that crate using LTO. The no_builtins crate doesn't # participate in LTO, so its rlib must be explicitly linked into the final binary. Verify this by # grepping the linker arguments. - $(RUSTC) main.rs -C lto -Z print-link-args | $(CGREP) 'libno_builtins.rlib' + $(RUSTC) main.rs -C lto --print link-args | $(CGREP) 'libno_builtins.rlib' diff --git a/src/test/run-make-fulldeps/redundant-libs/Makefile b/src/test/run-make-fulldeps/redundant-libs/Makefile index 8468d102bec..e09841fb42e 100644 --- a/src/test/run-make-fulldeps/redundant-libs/Makefile +++ b/src/test/run-make-fulldeps/redundant-libs/Makefile @@ -16,7 +16,7 @@ RUSTC_FLAGS = \ -l foo \ -l static=baz \ -l foo \ - -Z print-link-args + --print link-args all: $(call DYLIB,foo) $(call STATICLIB,bar) $(call STATICLIB,baz) $(RUSTC) $(RUSTC_FLAGS) main.rs diff --git a/src/test/run-make-fulldeps/static-nobundle/Makefile b/src/test/run-make-fulldeps/static-nobundle/Makefile index abc32d4423b..8f78c401a11 100644 --- a/src/test/run-make-fulldeps/static-nobundle/Makefile +++ b/src/test/run-make-fulldeps/static-nobundle/Makefile @@ -13,9 +13,9 @@ all: $(call NATIVE_STATICLIB,aaa) nm $(TMPDIR)/libbbb.rlib | $(CGREP) -e "U _*native_func" # Check that aaa gets linked (either as `-l aaa` or `aaa.lib`) when building ccc. - $(RUSTC) ccc.rs -C prefer-dynamic --crate-type=dylib -Z print-link-args | $(CGREP) -e '-l[" ]*aaa|aaa\.lib' + $(RUSTC) ccc.rs -C prefer-dynamic --crate-type=dylib --print link-args | $(CGREP) -e '-l[" ]*aaa|aaa\.lib' # Check that aaa does NOT get linked when building ddd. - $(RUSTC) ddd.rs -Z print-link-args | $(CGREP) -ve '-l[" ]*aaa|aaa\.lib' + $(RUSTC) ddd.rs --print link-args | $(CGREP) -ve '-l[" ]*aaa|aaa\.lib' $(call RUN,ddd) |
