Update the Linux build scripts to also work on Mac.

Now they work on all three supported platforms.  B-)
This commit is contained in:
David Walter Seikel
2013-12-12 14:56:42 +10:00
parent 7b79d4571f
commit ebbfc13dcb
3 changed files with 16 additions and 1 deletions
+1 -1
View File
@@ -65,7 +65,7 @@ else
FATAL_WARNINGS=""
fi
# Configure the sources and download the LL provided libraries:
./develop.py $os_extra --type=$TYPE configure "$FATAL_WARNINGS" \
./develop.py $os_extra --type=$TYPE configure "$FATAL_WARNINGS" $defs_extra \
-DCMAKE_C_FLAGS:STRING="$TUNE_FLAGS" -DCMAKE_CXX_FLAGS:STRING="$TUNE_FLAGS" \
-DCMAKE_C_FLAGS_DEBUG:STRING="-g $TUNE_FLAGS" -DCMAKE_CXX_FLAGS_DEBUG:STRING="-g $TUNE_FLAGS" \
-DCMAKE_C_FLAGS_RELEASE:STRING="$TUNE_FLAGS" -DCMAKE_CXX_FLAGS_RELEASE:STRING="$TUNE_FLAGS" \
+3
View File
@@ -6,6 +6,9 @@ if [[ "$OSTYPE" =~ ^cygwin ]] ; then
# Assumes version has been passed in from outside, coz Windows insists on adding crap to python output.
cd ../../indra/build-nmake/
iscc newview/${TYPE}/package/${version}-Windows-x86.iss
elif [[ "$OSTYPE" =~ ^darwin ]] ; then
cd ../../indra/build-darwin-*
../../scripts/package.py --build-dir=.
else
cd ../../indra/viewer-linux-*
make package
+12
View File
@@ -10,6 +10,7 @@
PWD=`pwd`
os_extra=''
defs_extra=''
ionice='ionice -c 3'
if [ -z "$(which ionice)" ]; then ionice=''; fi
@@ -79,6 +80,17 @@ if [[ "$OSTYPE" =~ ^cygwin ]] ; then
ALLOW_WARNINGS="no"
fi
# Change it all for Mac.
if [[ "$OSTYPE" =~ ^darwin ]] ; then
# Try to figure out which SDK is the earliest this version of Xcode supports.
# This might be fragile, only tested it with Xcode 3.2.6, which is the minimum supported Xcode anyway.
sdk_path="$(xcodebuild -version -sdk | grep Path: | cut -d ' ' -f 2 | grep MacOSX10. | sort | head -n 1)"
sdk="$(echo $sdk_path | cut -d '.' -f 2)"
# Minimum of SDK 10.5
if [ "$sdk" == "4u" ] ; then sdk_path="$(echo $sdk_path | cut -d '.' -f -1)".5.sdk; fi
defs_extra="-DCMAKE_OSX_SYSROOT=$sdk_path"
fi
# Work around python problems.
export PYTHONUNBUFFERED='True'