Skip to content

Commit

Permalink
Use MACOSX_VERSION_MIN=11 on Apple silicon (JuliaLang#39735)
Browse files Browse the repository at this point in the history
  • Loading branch information
omus authored Feb 19, 2021
1 parent 0d47bfe commit 11cbaf6
Showing 1 changed file with 6 additions and 20 deletions.
26 changes: 6 additions & 20 deletions Make.inc
Original file line number Diff line number Diff line change
Expand Up @@ -488,26 +488,15 @@ USEGCC := 0
USECLANG := 1
endif

# Note: Supporting only macOS Mavericks and above
ifeq ($(OS), Darwin)
DARWINVER := $(shell uname -r | cut -b 1-2)
DARWINVER_GTE11 := $(shell expr $(DARWINVER) \>= 11)
DARWINVER_GTE13 := $(shell expr $(DARWINVER) \>= 13)
ifeq ($(DARWINVER_GTE11),0) # Snow Leopard specific configuration
USEGCC := 1
USECLANG := 0
MACOSX_VERSION_MIN := 10.6
OPENBLAS_TARGET_ARCH:=NEHALEM
OPENBLAS_DYNAMIC_ARCH:=0
USE_SYSTEM_LIBUNWIND:=1
else
ifeq ($(DARWINVER_GTE13),0) # Lion / Mountain Lion specific configuration
USEGCC := 0
USECLANG := 1
MACOSX_VERSION_MIN := 10.6
else # Newer versions
APPLE_ARCH := $(shell uname -m)
USEGCC := 0
USECLANG := 1
endif
ifneq ($(APPLE_ARCH),arm64)
MACOSX_VERSION_MIN := 10.9
else
MACOSX_VERSION_MIN := 11.0
endif
endif

Expand Down Expand Up @@ -539,9 +528,6 @@ JCXXFLAGS := -pipe $(fPIC) -fno-rtti -pedantic -std=c++14
DEBUGFLAGS := -O0 -g -DJL_DEBUG_BUILD -fstack-protector
SHIPFLAGS := -O3 -g
ifeq ($(OS), Darwin)
ifeq ($(MACOSX_VERSION_MIN),)
MACOSX_VERSION_MIN := 10.9
endif
CC += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
CXX += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
FC += -mmacosx-version-min=$(MACOSX_VERSION_MIN)
Expand Down

0 comments on commit 11cbaf6

Please sign in to comment.