Use miphone-os-version-min for OSX 10.6 and up

This commit is contained in:
twinaphex 2014-05-20 23:20:33 +02:00
parent 643c5e3cf7
commit 437489e642

View File

@ -369,7 +369,7 @@ ifeq ($(arch),ppc)
else else
ENDIANNESS_DEFINES := -DLSB_FIRST ENDIANNESS_DEFINES := -DLSB_FIRST
endif endif
OSXVER = `sw_vers -productVersion | cut -c 4` OSXVER = $(shell sw_vers -productVersion | cut -c 4)
ifneq ($(OSXVER),9) ifneq ($(OSXVER),9)
fpic += -mmacosx-version-min=10.5 fpic += -mmacosx-version-min=10.5
endif endif
@ -383,13 +383,16 @@ else ifeq ($(platform), ios)
CC = clang -arch armv7 -isysroot $(IOSSDK) CC = clang -arch armv7 -isysroot $(IOSSDK)
CXX = clang++ -arch armv7 -isysroot $(IOSSDK) CXX = clang++ -arch armv7 -isysroot $(IOSSDK)
OSXVER = `sw_vers -productVersion | cut -c 4` OSXVER = $(shell sw_vers -productVersion | cut -c 4)
ifneq ($(OSXVER),9) ifeq ($(OSXVER),5)
LDFLAGS += -miphone-version-min=5.0 IPHONEMINVER = -miphone-version-min=5.0
FLAGS += -miphone-version-min=5.0 else
CC += -miphone-version-min=5.0 IPHONEMINVER = -miphoneos-version-min=5.0
CXX += -miphone-version-min=5.0
endif endif
LDFLAGS += $(IPHONEMINVER)
FLAGS += $(IPHONEMINVER)
CC += $(IPHONEMINVER)
CXX += $(IPHONEMINVER)
else ifeq ($(platform), qnx) else ifeq ($(platform), qnx)
TARGET := $(TARGET_NAME)_qnx.so TARGET := $(TARGET_NAME)_qnx.so
fpic := -fPIC fpic := -fPIC