Index: utils/release/test-release.sh =================================================================== --- utils/release/test-release.sh +++ utils/release/test-release.sh @@ -40,6 +40,7 @@ do_compare="yes" BuildDir="`pwd`" BuildTriple="" +ExportBranch="" function usage() { echo "usage: `basename $0` -release X.Y -rc NUM [OPTIONS]" @@ -63,6 +64,8 @@ echo " -use-gzip Use gzip instead of xz." echo " -build-triple TRIPLE The build triple for this machine" echo " [default: use config.guess]" + echo " -test-trunk Use the trunk instead of a release" + echo " -test-branch BRANCH Use the specified branch instead of a release" } while [ $# -gt 0 ]; do @@ -79,6 +82,25 @@ -final | --final ) RC=final ;; + -test-trunk | --test-trunk ) + Release="test" + Release_no_dot="test" + RC="trunk" + ExportBranch="trunk" + echo "WARNING: Using the trunk instead of a release tag" + echo " This is intended to aid new packagers in trialing " + echo " builds without requiring a tag to be created first" + ;; + -test-branch | --test-branch ) + shift + Release="test" + Release_no_dot="test" + ExportBranch="branches/$1" + RC="`echo $ExportBranch | sed -e 's,/,_,g'`" + echo "WARNING: Using the branch $ExportBranch instead of a release tag" + echo " This is intended to aid new packagers in trialing " + echo " builds without requiring a tag to be created first" + ;; -triple | --triple ) shift Triple="$1" @@ -157,6 +179,9 @@ echo "error: no target triple specified" exit 1 fi +if [ -z "$ExportBranch" ]; then + ExportBranch="tags/RELEASE_$Release_no_dot/$RC" +fi # Figure out how many make processes to run. if [ -z "$NumJobs" ]; then @@ -229,7 +254,7 @@ for proj in $projects ; do echo "# Validating $proj SVN URL" - if ! svn ls $Base_url/$proj/tags/RELEASE_$Release_no_dot/$RC > /dev/null 2>&1 ; then + if ! svn ls $Base_url/$proj/$ExportBranch > /dev/null 2>&1 ; then echo "$proj $Release release candidate $RC doesn't exist!" exit 1 fi @@ -242,7 +267,7 @@ for proj in $projects ; do echo "# Exporting $proj $Release-$RC sources" - if ! svn export -q $Base_url/$proj/tags/RELEASE_$Release_no_dot/$RC $proj.src ; then + if ! svn export -q $Base_url/$proj/$ExportBranch $proj.src ; then echo "error: failed to export $proj project" exit 1 fi