Chromium Code Reviews| OLD | NEW |
|---|---|
| (Empty) | |
| 1 #!/bin/bash | |
| 2 # Copyright (c) 2011 The Chromium Authors. All rights reserved. | |
| 3 # Use of this source code is governed by a BSD-style license that can be | |
| 4 # found in the LICENSE file. | |
| 5 # | |
| 6 # "compile and run tests" script for the android build of chromium. | |
| 7 # Intended for use by buildbot. | |
| 8 # At this time, we only have one bot which is both a builder and | |
| 9 # tester. Script assumes it runs in the "build" directory. | |
| 10 # | |
| 11 # This script uses buildbot "Annotator" style for steps. | |
| 12 # This script does not sync the source tree. | |
| 13 | |
| 14 set -e | |
| 15 set -x | |
| 16 | |
| 17 NEED_CLOBBER=0 | |
| 18 | |
| 19 echo "@@@BUILD_STEP cd into source root@@@" | |
| 20 SRC_ROOT=$(cd "$(dirname $0)/../.."; pwd) | |
| 21 cd $SRC_ROOT | |
| 22 | |
| 23 echo "@@@BUILD_STEP Basic setup@@@" | |
| 24 export ANDROID_SDK_ROOT=/usr/local/google/android-sdk-linux_x86 | |
| 25 export ANDROID_NDK_ROOT=/usr/local/google/android-ndk-r7 | |
| 26 if [ \( ! -d "${ANDROID_SDK_ROOT}" \) -o \( ! -d "${ANDROID_NDK_ROOT}" \) ]; the n | |
|
bradn
2011/11/19 16:40:09
<80 ?
How about [[ syntax?
[[ "${ANDROID_SDK_ROOT}
John Grabowski
2011/11/21 19:23:39
Done.
| |
| 27 echo "Android SDK and NDK are not installed." | |
| 28 echo "Build cannot continue." | |
| 29 exit 1 | |
| 30 fi | |
| 31 | |
| 32 if [ ! -n "$BUILDBOT_CLOBBER" ]; then | |
| 33 NEED_CLOBBER=1 | |
| 34 fi | |
| 35 | |
| 36 ## Build and test steps | |
| 37 | |
| 38 echo "@@@BUILD_STEP Configure with envsetup.sh@@@" | |
| 39 . build/android/envsetup.sh | |
| 40 | |
| 41 if [ "$NEED_CLOBBER" -eq 1 ]; then | |
| 42 echo "@@@BUILD_STEP Clobber@@@" | |
| 43 rm -rf "${SRC_ROOT}"/out | |
| 44 fi | |
| 45 | |
| 46 echo "@@@BUILD_STEP android_gyp@@@" | |
| 47 android_gyp | |
| 48 | |
| 49 echo "@@@BUILD_STEP Compile@@@" | |
| 50 make -j4 | |
| 51 | |
| 52 echo "@@@BUILD_STEP Run Tests@@@" | |
| 53 build/android/run_tests.py -e --xvfb | |
| 54 | |
| 55 exit 0 | |
| OLD | NEW |