Bug 1106707 - Add in support for win32/win64 builds, r=bhearsum
authorSteve Fink <sfink@mozilla.com>
Mon, 01 Dec 2014 23:07:44 -0800
changeset 5325 72c479940cfb563d515285c4e012e1bb0c1ff21e
parent 5324 7805fa1dd9ed2628b6a73661ba495254662cb6fd
child 5326 b0dc9e1cd9b951c3b34a7c4b4dce72f518691dbb
push id3952
push usersfink@mozilla.com
push dateFri, 16 Jan 2015 21:52:11 +0000
reviewersbhearsum
bugs1106707
Bug 1106707 - Add in support for win32/win64 builds, r=bhearsum --platform allows specifying win32 vs win64 The Windows builders require mozmake, but are currently running MozillaBuild 1.5.1 (!) which does not contain it, so we need to fetch it from tooltool.
scripts/spidermonkey_builds/spidermonkey.sh
--- a/scripts/spidermonkey_builds/spidermonkey.sh
+++ b/scripts/spidermonkey_builds/spidermonkey.sh
@@ -27,25 +27,38 @@ while [ $# -gt 1 ]; do
             hgtool_args+=(--mirror "$1")
             shift
             ;;
         -b|--bundle)
             shift
             hgtool_args+=(--bundle "$1")
             shift
             ;;
+        --ttserver)
+            # Note that this script (and tooltool_wrapper.sh, and tooltool.py)
+            # only accepts a single tooltool server, so all but the last will
+            # be ignored.
+            shift
+            TT_SERVER="$1"
+            shift
+            ;;
         -r|--rev)
             shift
             hgtool_args+=(--clone-by-revision -r "$1")
             shift
             ;;
         --dep)
             shift
             noclean=1
             ;;
+        --platform)
+            shift
+            platform="$1"
+            shift
+            ;;
         *)
             echo "Invalid arguments" >&2
             usage
             exit 1
             ;;
     esac
 done
 
@@ -91,25 +104,38 @@ if [ -f "$PROPERTIES_FILE" ]; then
         -s 4 -n info -n 'rel-*' -n 'tb-rel-*' -n $builddir
 fi
 
 if [ -z "$HG_REPO" ] || [ "$HG_REPO" = none ]; then
   SOURCE=.
 else
   $PYTHON $SCRIPTS_DIR/buildfarm/utils/hgtool.py "${hgtool_args[@]}" $HG_REPO src || exit 2
   SOURCE=src
+
+  # Pull down some standard tools that the build seems to have started
+  # requiring, eg mozmake on windows.
+  if [ "$OSTYPE" = "msys" ] && [ -n "$platform" ]; then
+      if [ -z "$TT_SERVER" ]; then
+          echo "Error: tooltool base url not set (use --ttserver command line option or TT_SERVER environment variable)" >&2
+          exit 1
+      fi
+      $SCRIPTS_DIR/scripts/tooltool/tooltool_wrapper.sh $SOURCE/browser/config/tooltool-manifests/$platform/releng.manifest $TT_SERVER setup.sh c:\mozilla-build\python27\python.exe C:/mozilla-build/tooltool.py
+  fi
 fi
 
 # The build script has been moved into the tree, but this script needs to keep
 # working for older branches.
 if [ -x "$SOURCE/js/src/devtools/automation/autospider.sh" ]; then
     ARGS=""
     if [ -n "$noclean" ]; then
         ARGS="$ARGS --dep"
     fi
+    if [ -n "$platform" ]; then
+        ARGS="$ARGV --platform $platform"
+    fi
     exec $SOURCE/js/src/devtools/automation/autospider.sh $ARGS "$VARIANT"
     exit 1
 fi
 
 # Everything from here down should be deleted when the oldest branch contains
 # the autospider.sh script.
 
 if [ ! -f "$SPIDERDIR/$VARIANT" ]; then