Kaydet (Commit) 288d4bf3 authored tarafından Tor Lillqvist's avatar Tor Lillqvist

Move -isysroot from gb_CFLAGS/gb_CXXFLAGS to CC/CXX

That is a much better place for it. The gb_C(XX)FLAGS don't get passed
on to "external" modules, so they should not contain flags that are
essential for the compilation to work at all. I think.

At least for me, in my MacOSX SDK 10.4 -based build tree, using Xcode
3 installed in /Xcode3, on OS X 10.8, the -isysroot is essential for
liborcus to compile.

Change-Id: I1f11c690585e4ba512eb87d2fddf11872b91dd57
üst 90fc5593
......@@ -2740,19 +2740,19 @@ if test "$_os" = "Darwin"; then
AC_MSG_ERROR([Cannot guess gcc location for this SDK])
;;
esac
CC="${gccprefix}gcc-4.0 -mmacosx-version-min=$with_macosx_version_min_required"
CXX="${gccprefix}g++-4.0 -mmacosx-version-min=$with_macosx_version_min_required"
CC="${gccprefix}gcc-4.0 -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
CXX="${gccprefix}g++-4.0 -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
;;
10.6)
# Is similar logic as above needed? Is it likely somebody
# has both an older Xcode with the 10.6 SDK and a current
# Xcode?
CC="gcc-4.2 $bitness -mmacosx-version-min=$with_macosx_version_min_required"
CXX="g++-4.2 $bitness -mmacosx-version-min=$with_macosx_version_min_required"
CC="gcc-4.2 $bitness -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
CXX="g++-4.2 $bitness -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
;;
10.7|10.8)
CC="`xcrun -find clang` $bitness -mmacosx-version-min=$with_macosx_version_min_required"
CXX="`xcrun -find clang++` $bitness -mmacosx-version-min=$with_macosx_version_min_required"
CC="`xcrun -find clang` $bitness -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
CXX="`xcrun -find clang++` $bitness -mmacosx-version-min=$with_macosx_version_min_required -isysroot $MACOSX_SDK_PATH"
;;
esac
AC_MSG_RESULT([$CC and $CXX])
......
......@@ -49,7 +49,6 @@ gb_OSDEFS := \
gb_CFLAGS := \
-isysroot $(gb_SDKDIR) \
$(gb_CFLAGS_COMMON) \
-fPIC \
-fno-strict-aliasing \
......@@ -59,7 +58,6 @@ gb_CFLAGS := \
# "Re: [dev] warnings01: -Wnon-virtual-dtor" message to dev@openoffice.org from
# Feb 1, 2006:
gb_CXXFLAGS := \
-isysroot $(gb_SDKDIR) \
$(gb_CXXFLAGS_COMMON) \
-fPIC \
-Wno-ctor-dtor-privacy \
......
......@@ -49,7 +49,7 @@ CDEFS+=-DGLIBC=2 -D_PTHREADS -D_REENTRANT -DNO_PTHREAD_PRIORITY $(PROCESSOR_DEFI
#.EXPORT: MACOSX_DEPLOYMENT_TARGET
CDEFS+:=-DQUARTZ
EXTRA_CDEFS+:=-isysroot $(MACOSX_SDK_PATH) -DMAC_OS_X_VERSION_MIN_REQUIRED=$(MAC_OS_X_VERSION_MIN_REQUIRED) -DMAC_OS_X_VERSION_MAX_ALLOWED=$(MAC_OS_X_VERSION_MAX_ALLOWED) -DMACOSX_SDK_VERSION=$(MACOSX_SDK_VERSION)
EXTRA_CDEFS+:=-DMAC_OS_X_VERSION_MIN_REQUIRED=$(MAC_OS_X_VERSION_MIN_REQUIRED) -DMAC_OS_X_VERSION_MAX_ALLOWED=$(MAC_OS_X_VERSION_MAX_ALLOWED) -DMACOSX_SDK_VERSION=$(MACOSX_SDK_VERSION)
# Name of library where static data members are initialized
# STATICLIBNAME=static$(DLLPOSTFIX)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment