[asterisk-dev] Change in asterisk[13]: For OS X, change -Xlinker to -Wl,

David M. Lee (Code Review) asteriskteam at digium.com
Mon Apr 13 13:22:05 CDT 2015


David M. Lee has uploaded a new change for review.

  https://gerrit.asterisk.org/87

Change subject: For OS X, change -Xlinker to -Wl,
......................................................................

For OS X, change -Xlinker to -Wl,

For [reasons unknown][], newer versions of GCC, when compiling the
Homebrew formula for Asterisk, are not properly passing the -Xlinker
options to the linker.

Given that -Wl, does exactly the [same thing][], and does it properly,
this patch changes the -Xlinker options to use -Wl, instead.

 [reasons unknown]: https://github.com/leedm777/homebrew-asterisk/issues/10#issuecomment-64676921
 [same thing]: https://gcc.gnu.org/onlinedocs/gcc/Link-Options.html

Change-Id: I9ab8ad8145916a136fa33cd6d4827c936c1be19e
---
M Makefile
1 file changed, 2 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/87/87/1

diff --git a/Makefile b/Makefile
index c2e1fba..da14214 100644
--- a/Makefile
+++ b/Makefile
@@ -254,10 +254,10 @@
 
 ifneq ($(findstring darwin,$(OSARCH)),)
   _ASTCFLAGS+=-D__Darwin__ -mmacosx-version-min=10.6
-  _SOLINK=-mmacosx-version-min=10.6 -Xlinker -undefined -Xlinker dynamic_lookup
+  _SOLINK=-mmacosx-version-min=10.6 -Wl,-undefined,dynamic_lookup
   _SOLINK+=/usr/lib/bundle1.o
   SOLINK=-bundle $(_SOLINK)
-  DYLINK=-Xlinker -dylib $(_SOLINK)
+  DYLINK=-Wl,-dylib $(_SOLINK)
   _ASTLDFLAGS+=-L/usr/local/lib
 else
 # These are used for all but Darwin

-- 
To view, visit https://gerrit.asterisk.org/87
To unsubscribe, visit https://gerrit.asterisk.org/settings

Gerrit-MessageType: newchange
Gerrit-Change-Id: I9ab8ad8145916a136fa33cd6d4827c936c1be19e
Gerrit-PatchSet: 1
Gerrit-Project: asterisk
Gerrit-Branch: 13
Gerrit-Owner: David M. Lee <dlee at digium.com>



More information about the asterisk-dev mailing list