From c45a19eadc4c697b7cc1b095692b04deb73da5ce Mon Sep 17 00:00:00 2001 From: Sven Gothel Date: Tue, 31 Dec 2019 20:04:30 +0100 Subject: Bug 1417: writesoname: xcode.ld uses '-install_name' instead of '-h' or '-soname' regression from commit 07aeed47e484bfec85e749ea721756b8a2571e00 on macos --- .../java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java b/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java index 05392bd..03135a8 100644 --- a/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java +++ b/src/main/java/net/sf/antcontrib/cpptasks/compiler/CommandLineLinker.java @@ -360,7 +360,11 @@ public abstract class CommandLineLinker extends AbstractLinker allArgs[index++] = decorateLinkerOption(buf, preargs[i]); } if( writeSONAME ) { - allArgs[index++] = "-Wl,-h,"+GccProcessor.getEscapedOutputFile(outputFile); + if(isXcoderun) { + allArgs[index++] = "-Wl,-install_name,"+GccProcessor.getEscapedOutputFile(outputFile); + } else { + allArgs[index++] = "-Wl,-h,"+GccProcessor.getEscapedOutputFile(outputFile); + } } for (int i = 0; i < outputSwitch.length; i++) { allArgs[index++] = outputSwitch[i]; -- cgit v1.2.3