Building universal binary (only works for clang and not for ppc64)

svn path=/trunk/netsurf/; revision=11465
This commit is contained in:
Sven Weidauer 2011-01-23 15:26:26 +00:00
parent 34b42a120a
commit d528da0fd9
1 changed files with 13 additions and 4 deletions

View File

@ -2,6 +2,7 @@
# Mac OS X target setup
# ----------------------------------------------------------------------------
POSTEXES += NetSurf.app
$(eval $(call feature_enabled,PNG,-DWITH_PNG,-lpng,PNG (libpng) ))
@ -25,10 +26,11 @@
CFLAGS += -D_DARWIN_C_SOURCE
MACOSX_VERSION := 10.5
SDK_FLAGS := -isysroot /Developer/SDKs/MacOSX$(MACOSX_VERSION).sdk -mmacosx-version-min=$(MACOSX_VERSION)
CFLAGS += $(SDK_FLAGS)
LDFLAGS += $(SDK_FLAGS)
CXXFLAGS += $(SDK_FLAGS)
SDK_PATH := /Developer/SDKs/MacOSX$(MACOSX_VERSION).sdk
SDK_FLAGS := --sysroot=$(SDK_PATH) -mmacosx-version-min=$(MACOSX_VERSION)
CFLAGS := $(SDK_FLAGS) $(CFLAGS)
LDFLAGS := $(SDK_FLAGS) -Wl,-syslibroot,$(SDK_PATH) $(LDFLAGS)
CXXFLAGS := $(SDK_FLAGS) $(CXXFLAGS)
CFLAGS += -I/opt/local/include
CFLAGS += -I/usr/X11/include
@ -62,6 +64,13 @@
endif
ifneq ($(UNIVERSAL),)
UNIVERSAL_FLAGS := $(foreach arch,$(UNIVERSAL),-arch $(arch) )
CFLAGS += $(UNIVERSAL_FLAGS)
LDFLAGS += $(UNIVERSAL_FLAGS)
CXXFLAGS += $(UNIVERSAL_FLAGS)
endif
# ----------------------------------------------------------------------------
# Source file setup
# ----------------------------------------------------------------------------