[svn-commits] dlee: trunk r392279 - in /trunk: Makefile main/Makefile

SVN commits to the Digium repositories svn-commits at lists.digium.com
Wed Jun 19 17:52:25 CDT 2013


Author: dlee
Date: Wed Jun 19 17:52:23 2013
New Revision: 392279

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=392279
Log:
Fix build problem on OS X Mountain Lion (10.8)

For about forever, our build flags for OS X have been slightly off, but
good enough to build and run. Apparently they aren't good enough any more.

Previously, we would compile with macosx-version-min unset and link with
it set. This combination, using GCC 4.8, on Mountain Lion, would create a
bad executable ("Illegal Instruction: 4", or something like that)

This patch consistently sets macosx-version-min for both compiling and
linking, which makes everything happy enough to build and run.

Modified:
    trunk/Makefile
    trunk/main/Makefile

Modified: trunk/Makefile
URL: http://svnview.digium.com/svn/asterisk/trunk/Makefile?view=diff&rev=392279&r1=392278&r2=392279
==============================================================================
--- trunk/Makefile (original)
+++ trunk/Makefile Wed Jun 19 17:52:23 2013
@@ -251,8 +251,8 @@
 MOD_SUBDIRS_MENUSELECT_TREE:=$(MOD_SUBDIRS:%=%-menuselect-tree)
 
 ifneq ($(findstring darwin,$(OSARCH)),)
-  _ASTCFLAGS+=-D__Darwin__
-  _SOLINK=-Xlinker -macosx_version_min -Xlinker 10.6 -Xlinker -undefined -Xlinker dynamic_lookup
+  _ASTCFLAGS+=-D__Darwin__ -mmacosx-version-min=10.6
+  _SOLINK=-mmacosx-version-min=10.6 -Xlinker -undefined -Xlinker dynamic_lookup
   _SOLINK+=/usr/lib/bundle1.o
   SOLINK=-bundle $(_SOLINK)
   DYLINK=-Xlinker -dylib $(_SOLINK)

Modified: trunk/main/Makefile
URL: http://svnview.digium.com/svn/asterisk/trunk/main/Makefile?view=diff&rev=392279&r1=392278&r2=392279
==============================================================================
--- trunk/main/Makefile (original)
+++ trunk/main/Makefile Wed Jun 19 17:52:23 2013
@@ -56,7 +56,7 @@
 
 ifneq ($(findstring darwin,$(OSARCH)),)
   AST_LIBS+=-lresolv
-  ASTLINK=-Xlinker -macosx_version_min -Xlinker 10.6 -Xlinker -undefined -Xlinker dynamic_lookup -force_flat_namespace
+  ASTLINK=-mmacosx-version-min=10.6 -Xlinker -undefined -Xlinker dynamic_lookup -force_flat_namespace
   ASTLINK+=/usr/lib/bundle1.o
 else
 # These are used for all but Darwin




More information about the svn-commits mailing list