diff options
| author | Daniel Sommermann <dcsommer@gmail.com> | 2022-08-01 11:47:32 -0700 |
|---|---|---|
| committer | Daniel Sommermann <dcsommer@gmail.com> | 2022-08-02 15:47:18 -0700 |
| commit | 9cf556dca9e4fb731035a51e75974c78d52295ce (patch) | |
| tree | 2b8a60f3966384f8dcf46f12f85cb5897fb20be4 /compiler/rustc_codegen_ssa/src/back | |
| parent | 4493a0f4724c0bae1436242d76cccc9c0a287b80 (diff) | |
| download | rust-9cf556dca9e4fb731035a51e75974c78d52295ce.tar.gz rust-9cf556dca9e4fb731035a51e75974c78d52295ce.zip | |
Fix backwards-compatibility check for tests with `+whole-archive`
Fixes #100066
Diffstat (limited to 'compiler/rustc_codegen_ssa/src/back')
| -rw-r--r-- | compiler/rustc_codegen_ssa/src/back/link.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/compiler/rustc_codegen_ssa/src/back/link.rs b/compiler/rustc_codegen_ssa/src/back/link.rs index 13a7b6be947..326dce8011e 100644 --- a/compiler/rustc_codegen_ssa/src/back/link.rs +++ b/compiler/rustc_codegen_ssa/src/back/link.rs @@ -2267,7 +2267,7 @@ fn add_local_native_libraries( // be added explicitly if necessary, see the error in `fn link_rlib`) compiled // as an executable due to `--test`. Use whole-archive implicitly, like before // the introduction of native lib modifiers. - || (bundle != Some(false) && sess.opts.test) + || (whole_archive == None && bundle != Some(false) && sess.opts.test) { cmd.link_whole_staticlib( name, |
