(OSX PPC) Improve upon some build rules

This commit is contained in:
twinaphex 2014-04-14 07:24:58 +02:00
parent d053448171
commit 5cd97263ce
2 changed files with 18 additions and 2 deletions

View File

@ -3,7 +3,7 @@ CFLAGS += -Wall -ggdb -falign-functions=2
CFLAGS += -I. -DINLINE=inline
ifndef DEBUG
CFLAGS += -O2 -DNDEBUG -ffunction-sections
ifeq ($(findstring clang,$(CC)),)
ifneq ($(APPLE),1)
LDFLAGS += -Wl,--gc-sections
endif
endif

View File

@ -8,6 +8,10 @@ else ifneq ($(findstring MINGW,$(shell uname -a)),)
platform = win
else ifneq ($(findstring Darwin,$(shell uname -a)),)
platform = osx
arch = intel
ifeq ($(shell uname -p),powerpc)
arch = ppc
endif
else ifneq ($(findstring win,$(shell uname -a)),)
platform = win
endif
@ -34,10 +38,22 @@ ifeq ($(platform), unix)
SHARED := -shared
else ifeq ($(platform), osx)
TARGET := $(TARGET_NAME)_libretro.dylib
SHARED := -dynamiclib -mmacosx-version-min=10.6
SHARED := -dynamiclib
APPLE := 1
arch = intel
ifeq ($(shell uname -p),powerpc)
arch = ppc
endif
ifeq ($(arch),ppc)
else
SHARED += -mmacosx-version-min=10.6
endif
else ifeq ($(platform), ios)
TARGET := $(TARGET_NAME)_libretro_ios.dylib
SHARED := -dynamiclib
APPLE := 1
CC = clang -arch armv7 -isysroot $(IOSSDK) -miphoneos-version-min=5.0
CXX = clang++ -arch armv7 -isysroot $(IOSSDK) -miphoneos-version-min=5.0