aboutsummaryrefslogtreecommitdiff
path: root/BuildScripts
diff options
context:
space:
mode:
authorGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-11-20 20:00:41 +0000
committerGravatar gtm.daemon <gtm.daemon@7dc7ac4e-7543-0410-b95c-c1676fc8e2a3>2009-11-20 20:00:41 +0000
commitfe8a34f1515ffad41dac45e90a3b2096cc5699df (patch)
tree1cbebdacc06c969c28a15345182728c2f48bd0e7 /BuildScripts
parentcc6fc10bc9d001abb200449d311e8f8b8e176647 (diff)
[Author: thomasvl]
Added Xcode configs for iPhone 2.2, 2.2.1, 3.0, 3.1, 3.1.2. Updated the GTMiPhone project to have multiple config support. Updated the helper script to handle all the iPhone configs also. Left the generic configs in for now until the automated builds are updated. Updated one issues with the atomic ops and iphone 3+ sdks. R=dmaclach DELTA=1413 (1397 added, 0 deleted, 16 changed)
Diffstat (limited to 'BuildScripts')
-rwxr-xr-xBuildScripts/BuildAllSDKs.sh90
1 files changed, 80 insertions, 10 deletions
diff --git a/BuildScripts/BuildAllSDKs.sh b/BuildScripts/BuildAllSDKs.sh
index 32a867d..fccccf1 100755
--- a/BuildScripts/BuildAllSDKs.sh
+++ b/BuildScripts/BuildAllSDKs.sh
@@ -4,7 +4,7 @@
# This script builds the Tiger, Leopard, SnowLeopard and iPhone versions of the
# requested target in the current basic config (debug, release, debug-gcov).
#
-# Copyright 2006-2008 Google Inc.
+# Copyright 2006-2009 Google Inc.
#
# Licensed under the Apache License, Version 2.0 (the "License"); you may not
# use this file except in compliance with the License. You may obtain a copy
@@ -18,12 +18,17 @@
# License for the specific language governing permissions and limitations under
# the License.
+# This scrit runs as the build script, it actually exits having really done no
+# build. Instead it creates and launches and AppleScript that then drives
+# Xcode to do the real builds cycling through configurations/projects to get
+# everything done.
+
GTM_PROJECT_TARGET="$1"
GTMIPHONE_PROJECT_TARGET="$2"
STARTING_TARGET="${TARGET_NAME}"
SCRIPT_APP="${TMPDIR}DoBuild.app"
-REQUESTED_BUILD_STYLE=$(echo "${BUILD_STYLE}" | sed -E "s/(.*OrLater-)?(.*)/\2/")
+REQUESTED_BUILD_STYLE=$(echo "${BUILD_STYLE}" | sed -E "s/((iPhone.*)|(.*OrLater))-(.*)/\4/")
# See if we were told to clean instead of build.
PROJECT_ACTION="build"
if [ "${ACTION}" == "clean" ]; then
@@ -38,6 +43,7 @@ AVAILABLE_PLATFORMS=`eval ls ${DEVELOPER_DIR}/Platforms`
GTMIPHONE_OPEN_EXTRAS=""
GTMIPHONE_BUILD_EXTRAS=""
if [ "${GTMIPHONE_PROJECT_TARGET}" != "" ]; then
+ AVAILABLE_IPHONE_SDKS=`eval ls ${DEVELOPER_DIR}/Platforms/iPhoneSimulator.platform/Developer/SDKs`
GTMIPHONE_OPEN_EXTRAS="
if \"${AVAILABLE_PLATFORMS}\" contains \"iPhoneSimulator.platform\" then
-- make sure both project files are open
@@ -46,13 +52,77 @@ if [ "${GTMIPHONE_PROJECT_TARGET}" != "" ]; then
end if"
GTMIPHONE_BUILD_EXTRAS="
if \"${AVAILABLE_PLATFORMS}\" contains \"iPhoneSimulator.platform\" then
- with timeout of 9999 seconds
- tell project \"GTMiPhone\"
- -- do the GTMiPhone build
- ${PROJECT_ACTION} using build configuration \"${REQUESTED_BUILD_STYLE}\"
- set active target to target \"${STARTING_TARGET}\"
- end tell
- end timeout
+ tell project \"GTMiPhone\"
+ -- wait for stub build to finish before kicking off the real builds.
+ set x to 0
+ repeat while currently building
+ delay 0.5
+ set x to x + 1
+ if x > 6 then
+ display alert \"GTMiPhone is still building, can't start.\"
+ return
+ end if
+ end repeat
+ -- do the GTMiPhone builds
+ with timeout of 9999 seconds
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator2.0.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone2.0-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator2.1.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone2.1-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator2.2.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone2.2-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator2.2.1.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone2.2.1-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator3.0.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone3.0-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator3.1.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone3.1-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ if \"{$AVAILABLE_IPHONE_SDKS}\" contains \"iPhoneSimulator3.1.2.sdk\" then
+ set active target to target \"${GTMIPHONE_PROJECT_TARGET}\"
+ set buildResult to ${PROJECT_ACTION} using build configuration \"iPhone3.1.2-${REQUESTED_BUILD_STYLE}\"
+ set active target to target \"${STARTING_TARGET}\"
+ if buildResult is not equal to \"Build succeeded\" then
+ return
+ end if
+ end if
+ end timeout
+ end tell
end if"
fi
@@ -63,7 +133,7 @@ OUR_BUILD_SCRIPT="on run
${GTMIPHONE_OPEN_EXTRAS}
if \"${AVAILABLE_PLATFORMS}\" contains \"MacOSX.platform\" then
tell project \"GTM\"
- -- wait for build to finish
+ -- wait for stub build to finish before kicking off the real builds.
set x to 0
repeat while currently building
delay 0.5