9 echo "Fetching latest revno... "
10 rev=$(wget -q -O - http://build.chromium.org/buildbot/continuous/linux/LATEST/REVISION)
11 rev64=$(wget -q -O - http://build.chromium.org/buildbot/continuous/linux64/LATEST/REVISION)
12 # be sure that we use same rev on both arch
13 if [ "$rev" != "$rev64" ]; then
14 echo "Current 32bit build ($rev) does not match 64bit build ($rev64)"
15 echo "The upstream buildbot probably failed."
16 if [ "$rev" -lt "$rev64" ]; then
17 echo "Using latest 32bit revision..."
20 echo "Using latest 64bit revision..."
25 # TODO: use release branches instead of trunk. Current release can be looked up like this:
26 #linuxdev=$(wget -q -O - http://omahaproxy.appspot.com | grep '^linux,dev' | cut -d, -f3)
29 if [ ! -f chromium-browser32-r$rev.zip ]; then
30 wget http://build.chromium.org/buildbot/snapshots/chromium-rel-linux/$rev/chrome-linux.zip -c -O chromium-browser32-r$rev.zip
31 upload_32="chromium-browser32-r$rev.zip"
33 if [ ! -f chromium-browser64-r$rev.zip ]; then
34 wget http://build.chromium.org/buildbot/snapshots/chromium-rel-linux-64/$rev/chrome-linux.zip -c -O chromium-browser64-r$rev.zip
35 upload_64="chromium-browser64-r$rev.zip"
38 if [ "$dropin" ]; then
39 if [ -x ./dropin ]; then
41 elif [ -x ../dropin ]; then
45 if [ "$upload_32" -o "$upload_64" ]; then
46 echo "Uploading to dropin. ^C to abort"
47 ../dropin $upload_32 $upload_64
51 specfile=chromium-browser-bin.spec
52 oldrev=$(awk '/^%define[ ]+svnrev[ ]+/{print $NF}' $specfile)
53 if [ "$oldrev" != "$rev" ]; then
54 # revno => VERSION hint by Caleb Maclennan <caleb#alerque.com>
55 wget -q -O VERSION.sh http://src.chromium.org/viewvc/chrome/trunk/src/chrome/VERSION?revision=$rev
56 if grep -Ev '^(MAJOR|MINOR|BUILD|PATCH)=[0-9]+$' VERSION.sh >&2; then
57 echo >&2 "I refuse to execute grabbed file for security concerns"
61 version=$MAJOR.$MINOR.$BUILD.$PATCH
63 echo "Updating $specfile for $version r$rev"
65 s/^\(%define[ \t]\+svnrev[ \t]\+\)[0-9]\+\$/\1$rev/
66 s/^\(Version:[ \t]\+\)[.0-9]\+\$/\1$version/
68 ../builder -ncs -5 $specfile