From 38d2dd6d2a21efd3c87dec51476740f8ef1dddf6 Mon Sep 17 00:00:00 2001 From: Jonathan Schwender Date: Sun, 25 Aug 2024 15:07:17 +0800 Subject: [PATCH] uplift windows gnullvm import libraries Same changes as #8141, but for gnullvm. gnullvm does not seem to be tested in CI, so tests were not adjusted. --- src/cargo/core/compiler/build_context/target_info.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/cargo/core/compiler/build_context/target_info.rs b/src/cargo/core/compiler/build_context/target_info.rs index 39e0515de36..f36fc173bcc 100644 --- a/src/cargo/core/compiler/build_context/target_info.rs +++ b/src/cargo/core/compiler/build_context/target_info.rs @@ -389,7 +389,10 @@ impl TargetInfo { crate_type: Some(crate_type.clone()), should_replace_hyphens: true, }); - } else if target_triple.ends_with("windows-gnu") && suffix == ".dll" { + } else if suffix == ".dll" + && (target_triple.ends_with("windows-gnu") + || target_triple.ends_with("windows-gnullvm")) + { // See https://cygwin.com/cygwin-ug-net/dll.html for more // information about GNU import libraries. // LD can link DLL directly, but LLD requires the import library.