BUG 1093830 - builds need moztt package r=lightsofapollo
authorGreg Arndt <garndt@mozilla.com>
Wed, 26 Nov 2014 10:11:37 -0800
changeset 243186 990ed2c33a9c5f019bad12f5a445e14f403dedc7
parent 243185 2be33897385a637380e0edc49fbfc5e6e4b1f878
child 243187 8549f41c5215832c962857607a3245f53906cefa
push id7677
push userraliiev@mozilla.com
push dateMon, 23 Feb 2015 18:11:24 +0000
treeherdermozilla-aurora@f531d838c055 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewerslightsofapollo
bugs1093830
milestone38.0a1
BUG 1093830 - builds need moztt package r=lightsofapollo
testing/docker/builder/VERSION
testing/docker/builder/bin/build-b2g-desktop.sh
testing/docker/builder/bin/build-mulet-linux.sh
testing/docker/builder/bin/install_packages.sh
testing/docker/builder/system-setup.sh
testing/taskcluster/tasks/builds/b2g_desktop.yml
testing/taskcluster/tasks/builds/b2g_desktop_debug.yml
testing/taskcluster/tasks/builds/mulet_linux.yml
--- a/testing/docker/builder/VERSION
+++ b/testing/docker/builder/VERSION
@@ -1,1 +1,1 @@
-0.0.18
+0.0.19
--- a/testing/docker/builder/bin/build-b2g-desktop.sh
+++ b/testing/docker/builder/bin/build-b2g-desktop.sh
@@ -9,24 +9,18 @@ test $REPOSITORY  # Should be an hg repo
 test $REVISION    # Should be an hg revision to pull down
 test $MOZCONFIG   # Should be a mozconfig file from mozconfig/ folder
 
 ### Pull and update mozilla-central
 cd $gecko_dir
 hg pull -r $REVISION $REPOSITORY;
 hg update $REVISION;
 
-### Retrieve and install latest tooltool manifest
-tooltool=/home/worker/tools/tooltool.py
-manifest=b2g/config/tooltool-manifests/linux64/releng.manifest
-tooltool_url=http://tooltool.pub.build.mozilla.org/temp-sm-stuff
-
-python $tooltool --url $tooltool_url --overwrite -m $manifest fetch -c $TOOLTOOL_CACHE
-chmod +x setup.sh
-./setup.sh
+### Install package dependencies
+. install_packages.sh
 
 ### Clone gaia
 if [ ! -d "$gaia_dir" ]; then
   create_parent_dir $gaia_dir
   hg clone https://hg.mozilla.org/integration/gaia-central/ $gaia_dir
 fi
 
 ### Pull and update gaia
--- a/testing/docker/builder/bin/build-mulet-linux.sh
+++ b/testing/docker/builder/bin/build-mulet-linux.sh
@@ -9,24 +9,18 @@ test $REPOSITORY  # Should be an hg repo
 test $REVISION    # Should be an hg revision to pull down
 test $MOZCONFIG   # Should be a mozconfig file from mozconfig/ folder
 
 ### Pull and update mozilla-central
 cd $gecko_dir
 hg pull -r $REVISION $REPOSITORY;
 hg update $REVISION;
 
-### Retrieve and install latest tooltool manifest
-tooltool=/home/worker/tools/tooltool.py
-manifest=browser/config/tooltool-manifests/linux64/releng.manifest
-tooltool_url=http://tooltool.pub.build.mozilla.org/temp-sm-stuff
-
-python $tooltool --url $tooltool_url --overwrite -m $manifest fetch -c $TOOLTOOL_CACHE
-chmod +x setup.sh
-./setup.sh
+### Install package dependencies
+. install_packages.sh
 
 export MOZ_OBJDIR=$(get-objdir.py $gecko_dir)
 
 ./mach build;
 
 ### Make package
 cd $MOZ_OBJDIR;
 make package package-tests;
new file mode 100755
--- /dev/null
+++ b/testing/docker/builder/bin/install_packages.sh
@@ -0,0 +1,26 @@
+#!/bin/bash -vex
+
+if [ ! -d "gcc" ]; then
+    curl https://s3-us-west-2.amazonaws.com/test-caching/packages/gcc.tar.xz | tar Jx
+fi
+
+if [ ! -d "sccache" ]; then
+    curl https://s3-us-west-2.amazonaws.com/test-caching/packages/sccache.tar.bz2 | tar jx
+fi
+
+# Remove cached moztt directory if it exists when a user supplied a git url/revision
+if [ ! -z $MOZTT_GIT_URL ] || [ ! -z $MOZTT_REVISION ]; then
+    echo "Removing cached moztt package"
+    rm -rf moztt
+fi
+
+if [ ! -d "moztt" ]; then
+    moztt_url=${MOZTT_GIT_URL:=https://github.com/mozilla-b2g/moztt}
+    moztt_revision=${MOZTT_REVISION:=master}
+    git clone $moztt_url moztt
+    cd moztt && git checkout $moztt_revision
+    echo "moztt repository: $moztt_url"
+    echo "moztt revision: $(git rev-parse HEAD)"
+    cd $gecko_dir
+fi
+
--- a/testing/docker/builder/system-setup.sh
+++ b/testing/docker/builder/system-setup.sh
@@ -2,19 +2,16 @@
 
 ############################### system-setup.sh ###############################
 
 home="/home/worker"
 tools_dir="/tmp/tools"
 
 mkdir -p $home/bin
 mkdir -p $home/tools
-mkdir -p $home/tools/tooltool-cache
-
-wget -O $home/tools/tooltool.py https://raw.githubusercontent.com/mozilla/build-tooltool/master/tooltool.py
 
 chown -R worker:worker $home/* $home/.*
 
 # Install android repo tool
 curl https://storage.googleapis.com/git-repo-downloads/repo > $home/bin/repo
 chmod a+x $home/bin/repo
 
 # Install build tools
--- a/testing/taskcluster/tasks/builds/b2g_desktop.yml
+++ b/testing/taskcluster/tasks/builds/b2g_desktop.yml
@@ -22,16 +22,18 @@ task:
       sources-mozilla-central: '/home/worker/mozilla-central'
       build-b2g-desktop-objects: '/home/worker/object-folder'
 
     env:
       MOZCONFIG: '/home/worker/mozilla-central/source/b2g/config/mozconfigs/linux64_gecko/nightly'
       # revision/project params defined originally here https://github.com/taskcluster/taskcluster-try/blob/master/try/instantiate.js
       REVISION: '{{revision}}'
       REPOSITORY: '{{repository}}'
+      MOZTT_GIT_URL: '{{moztt_git_url}}'
+      MOZTT_REVISION: '{{moztt_revision}}'
 
     image: '{{#docker_image}}builder{{/docker_image}}'
     maxRunTime: 3600
 
     command:
       - bin/build-b2g-desktop.sh
 
     artifacts:
--- a/testing/taskcluster/tasks/builds/b2g_desktop_debug.yml
+++ b/testing/taskcluster/tasks/builds/b2g_desktop_debug.yml
@@ -22,16 +22,18 @@ task:
       sources-mozilla-central: '/home/worker/mozilla-central'
       build-b2g-desktop-objects: '/home/worker/object-folder'
 
     env:
       MOZCONFIG: '/home/worker/mozilla-central/source/b2g/config/mozconfigs/linux64_gecko/debug'
       # revision/project params defined originally here https://github.com/taskcluster/taskcluster-try/blob/master/try/instantiate.js
       REVISION: '{{revision}}'
       REPOSITORY: '{{repository}}'
+      MOZTT_GIT_URL: '{{moztt_git_url}}'
+      MOZTT_REVISION: '{{moztt_revision}}'
 
     image: '{{#docker_image}}builder{{/docker_image}}'
     maxRunTime: 3600
 
     command:
       - bin/build-b2g-desktop.sh
 
     artifacts:
--- a/testing/taskcluster/tasks/builds/mulet_linux.yml
+++ b/testing/taskcluster/tasks/builds/mulet_linux.yml
@@ -22,16 +22,18 @@ task:
       build-mulet-linux-objects: '/home/worker/object-folder'
       tooltool-cache: '/home/worker/tools/tooltool-cache'
 
     env:
       MOZCONFIG: 'b2g/dev/config/mozconfigs/linux64/mulet'
       # revision/project params defined originally here https://github.com/taskcluster/taskcluster-try/blob/master/try/instantiate.js
       REVISION: '{{revision}}'
       REPOSITORY: '{{repository}}'
+      MOZTT_GIT_URL: '{{moztt_git_url}}'
+      MOZTT_REVISION: '{{moztt_revision}}'
 
     image: '{{#docker_image}}builder{{/docker_image}}'
     maxRunTime: 3600
 
     command:
       - bin/build-mulet-linux.sh
 
     artifacts: