From cbe01d71660f2594fb68262ab12aeb9cde34a577 Mon Sep 17 00:00:00 2001 From: "Sergey \"Shnatsel\" Davidoff" Date: Tue, 3 Mar 2026 16:17:45 +0000 Subject: [PATCH] Fix bare linker argument passing on Apple platforms --- cargo-auditable/src/rustc_wrapper.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/cargo-auditable/src/rustc_wrapper.rs b/cargo-auditable/src/rustc_wrapper.rs index 92d34f4..51ffba4 100644 --- a/cargo-auditable/src/rustc_wrapper.rs +++ b/cargo-auditable/src/rustc_wrapper.rs @@ -128,7 +128,8 @@ fn rustc_command_with_audit_data(rustc_path: &OsStr) -> Option { // Prevent the symbol from being removed as unused by the linker if is_apple(&target_info) { if args.bare_linker() { - command.arg("-Clink-arg=-u,_AUDITABLE_VERSION_INFO"); + command.arg("-Clink-arg=-u"); + command.arg("-Clink-arg=_AUDITABLE_VERSION_INFO"); } else { command.arg("-Clink-arg=-Wl,-u,_AUDITABLE_VERSION_INFO"); }