# HG changeset patch # User Ryan C. Gordon # Date 1256758936 0 # Node ID 6f74b80cca1dbfe7a776e08906bbd56af68f080b # Parent 8d67936e32ec35bcacac4d7e12bdab4a29e499cd fatbuild.sh: work around directory name change in Xcode 3.2. diff -r 8d67936e32ec -r 6f74b80cca1d build-scripts/fatbuild.sh --- a/build-scripts/fatbuild.sh Thu Oct 22 04:53:44 2009 +0000 +++ b/build-scripts/fatbuild.sh Wed Oct 28 19:42:16 2009 +0000 @@ -70,6 +70,17 @@ CONFIG_X86="--build=`uname -p`-apple-darwin --host=i386-apple-darwin \ --x-includes=/usr/X11R6/include --x-libraries=/usr/X11R6/lib" +# They changed this to "darwin10" in Xcode 3.2 (Snow Leopard). +GCCUSRPATH="$SDK_PATH/MacOSX10.4u.sdk/usr/lib/gcc/i686-apple-darwin9/4.0.1" +if [ ! -d "$GCCUSRPATH" ]; then + GCCUSRPATH="$SDK_PATH/MacOSX10.4u.sdk/usr/lib/gcc/i686-apple-darwin10/4.0.1" +fi + +if [ ! -d "$GCCUSRPATH" ]; then + echo "Couldn't find any GCC usr path" + exit 1 +fi + # Intel compiler flags CC_X86="gcc-4.0 -arch i386" CXX_X86="g++-4.0 -arch i386" @@ -77,12 +88,12 @@ CPPFLAGS_X86="-DMAC_OS_X_VERSION_MIN_REQUIRED=1040 \ -nostdinc \ -F$SDK_PATH/MacOSX10.4u.sdk/System/Library/Frameworks \ --I$SDK_PATH/MacOSX10.4u.sdk/usr/lib/gcc/i686-apple-darwin9/4.0.1/include \ +-I$GCCUSRPATH/include \ -isystem $SDK_PATH/MacOSX10.4u.sdk/usr/include" # Intel linker flags LFLAGS_X86="-Wl,-headerpad_max_install_names -arch i386 -mmacosx-version-min=10.4 \ --L$SDK_PATH/MacOSX10.4u.sdk/usr/lib/gcc/i686-apple-darwin9/4.0.1 \ +-L$GCCUSRPATH \ -Wl,-syslibroot,$SDK_PATH/MacOSX10.4u.sdk" #