[jffi-next] 43/49: Fix compilation on macos with Xcode4 only installed
Tim Potter
tpot-guest at moszumanska.debian.org
Wed Mar 4 04:51:16 UTC 2015
This is an automated email from the git hooks/post-receive script.
tpot-guest pushed a commit to annotated tag upstream/1.0.10
in repository jffi-next.
commit a53692ae6b9bf983841db1ab33b727e72bf9bacd
Author: Wayne Meissner <wmeissner at gmail.com>
Date: Sun May 29 11:59:10 2011 +1000
Fix compilation on macos with Xcode4 only installed
---
jni/GNUmakefile | 20 +++++++++++---------
libtest/GNUmakefile | 15 +++++++++++----
2 files changed, 22 insertions(+), 13 deletions(-)
diff --git a/jni/GNUmakefile b/jni/GNUmakefile
index ff6c36c..a7fd2fe 100755
--- a/jni/GNUmakefile
+++ b/jni/GNUmakefile
@@ -138,13 +138,20 @@ endif
ifeq ($(OS), darwin)
PLATFORM = darwin
- ARCHES = ppc
+ ARCHES =
+ ifneq ($(findstring $(CPU), ppc powerpc),)
+ ARCHES += ppc
+ endif
ifneq ($(findstring $(CPU), i386 x86_64),)
- ARCHES = ppc i386 x86_64
+ ARCHES += i386 x86_64
endif
- CC = gcc-4.0
+ CC = gcc
- MACSDK = /Developer/SDKs/MacOSX10.4u.sdk
+ ifneq ($(realpath /Developer/SDKs/MacOSX10.4u.sdk),)
+ MACSDK = /Developer/SDKs/MacOSX10.4u.sdk
+ else
+ MACSDK = $(firstword $(strip $(wildcard /Developer/SDKs/MacOSX10.*.sdk)))
+ endif
CFLAGS += -isysroot $(MACSDK) -DTARGET_RT_MAC_CFM=0
CFLAGS += -I$(MACSDK)/System/Library/Frameworks/JavaVM.framework/Headers
CFLAGS += $(foreach arch, $(ARCHES),-arch $(arch))
@@ -232,11 +239,6 @@ $(LIBJFFI): $(OBJS) $(LIBFFI_LIBS)
$(CC) -o $@ $(LDFLAGS) $(SOFLAGS) $(OBJS) $(LIBFFI_LIBS) $(LIBS)
$(STRIP) $@
-# For the primitive int interface, don't do frame pointer save/restore
-$(JFFI_BUILD_DIR)/Fast%Invoke.o : $(JFFI_SRC_DIR)/Fast%Invoke.c $(wildcard $(JFFI_SRC_DIR)/*.h) $(LIBFFI)
- @mkdir -p $(@D)
- @$(CCACHE) $(CC) $(CFLAGS) -fomit-frame-pointer -c $< -o $@
-
$(BUILD_DIR)/%.o : $(SRC_DIR)/%.c $(wildcard $(JFFI_SRC_DIR)/*.h)
@mkdir -p $(@D)
diff --git a/libtest/GNUmakefile b/libtest/GNUmakefile
index 298a612..a74331c 100644
--- a/libtest/GNUmakefile
+++ b/libtest/GNUmakefile
@@ -74,12 +74,19 @@ ifeq ($(OS), win32)
endif
ifeq ($(OS), darwin)
- ARCHFLAGS = -arch ppc
+ ARCHFLAGS =
+ ifneq ($(findstring $(CPU), ppc powerpc),)
+ ARCHES += ppc
+ endif
ifneq ($(findstring $(CPU), i386 x86_64),)
- ARCHFLAGS += -arch i386 -arch x86_64
+ ARCHES += i386 x86_64
+ endif
+ CC = gcc
+ ifneq ($(realpath /Developer/SDKs/MacOSX10.4u.sdk),)
+ MACSDK = /Developer/SDKs/MacOSX10.4u.sdk
+ else
+ MACSDK = $(firstword $(strip $(wildcard /Developer/SDKs/MacOSX10.*.sdk)))
endif
- CC = gcc-4.0
- MACSDK = /Developer/SDKs/MacOSX10.4u.sdk
CFLAGS += $(ARCHFLAGS) -isysroot $(MACSDK) -DTARGET_RT_MAC_CFM=0
CFLAGS += -fno-common
LDFLAGS = $(ARCHFLAGS) -dynamiclib -Wl,-syslibroot,$(MACSDK) -mmacosx-version-min=10.4
--
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-java/jffi-next.git
More information about the pkg-java-commits
mailing list