Commit e4d67730 authored by Rich Prohaska's avatar Rich Prohaska Committed by Yoni Fogel

#3464 fix the run.db-benchmark-test.bash script closes[t:3464]

git-svn-id: file:///svn/toku/tokudb@30319 c7de825b-a66e-492c-adef-691d508d4ae1
parent dc814945
...@@ -57,14 +57,22 @@ done ...@@ -57,14 +57,22 @@ done
# require a revision # require a revision
if [ $revision -eq 0 ] ; then exit 1; fi if [ $revision -eq 0 ] ; then exit 1; fi
if [ $branch = "." ] ; then branch="toku"; fi
function append() {
local s=""; local x
for x in $*; do
if [ "$s" != "" ] ; then s=$s-$x; else s=$x; fi
done
echo $s
}
# setup the branchrevision string # setup the branchrevision string
if [ $branch = "toku" ] ; then branchrevision=""
branchrevision=$revision if [ $branch != "toku" ] ; then branchrevision=$(append $branchrevision $(basename $branch)); fi
else if [ $tokudb != "tokudb" ] ; then branchrevision=$(append $branchrevision $tokudb); fi
branchrevision=`basename $branch`-$revision branchrevision=$(append $branchrevision $revision)
fi if [ $suffix != "." ] ; then branchrevision=$(append $branchrevision $suffix); fi
if [ $suffix != "." ] ; then branchrevision=$branchrevision-$suffix; fi
# goto the base directory # goto the base directory
if [ ! -d $basedir ] ; then mkdir $basedir; fi if [ ! -d $basedir ] ; then mkdir $basedir; fi
...@@ -72,31 +80,17 @@ if [ ! -d $basedir ] ; then mkdir $basedir; fi ...@@ -72,31 +80,17 @@ if [ ! -d $basedir ] ; then mkdir $basedir; fi
pushd $basedir pushd $basedir
# update the build directory # update the build directory
if [ ! -d $builddir ] ; then if [ ! -d $builddir ] ; then mkdir $builddir; fi
retry svn checkout -q $svnserver/tokudb.build
exitcode=$?
if [ $exitcode -ne 0 ] ; then exit 1; fi
else
pushd $builddir
retry svn update -q
exitcode=$?
if [ $exitcode -ne 0 ] ; then exit 1; fi
popd
fi
date=`date +%Y%m%d` date=`date +%Y%m%d`
testresultsdir=$builddir/$date
pushd $builddir pushd $builddir
while [ ! -d $date ] ; do while [ ! -d $date ] ; do
mkdir $date svn mkdir $svnserver/mysql.build/$date -m ""
svn add $date svn co -q $svnserver/mysql.build/$date
svn commit $date -m "" if [ $? -ne 0 ] ; then rm -rf $date; fi
if [ $? -eq 0 ] ; then break; fi
rm -rf $date
svn remove $date
svn update -q
done done
popd popd
testresultsdir=$builddir/$date
gccversion=`$cc --version|head -1|cut -f3 -d" "` gccversion=`$cc --version|head -1|cut -f3 -d" "`
...@@ -110,10 +104,9 @@ rm -rf $testdir ...@@ -110,10 +104,9 @@ rm -rf $testdir
# checkout the tokudb branch # checkout the tokudb branch
if [ $testresult = "PASS" ] ; then if [ $testresult = "PASS" ] ; then
retry svn checkout -q https://svn.tokutek.com/tokudb/$branch/$tokudb retry svn export -q https://svn.tokutek.com/tokudb/$branch/$tokudb $testdir
exitcode=$? exitcode=$?
if [ $exitcode != 0 ] ; then testresult="FAIL"; fi if [ $exitcode != 0 ] ; then testresult="FAIL"; fi
mv $tokudb $testdir
fi fi
# build it # build it
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment