aboutsummaryrefslogtreecommitdiffstats
path: root/utils/release
diff options
context:
space:
mode:
authorStephen Hines <srhines@google.com>2015-03-23 12:10:34 -0700
committerStephen Hines <srhines@google.com>2015-03-23 12:10:34 -0700
commitebe69fe11e48d322045d5949c83283927a0d790b (patch)
treec92f1907a6b8006628a4b01615f38264d29834ea /utils/release
parentb7d2e72b02a4cb8034f32f8247a2558d2434e121 (diff)
downloadexternal_llvm-ebe69fe11e48d322045d5949c83283927a0d790b.zip
external_llvm-ebe69fe11e48d322045d5949c83283927a0d790b.tar.gz
external_llvm-ebe69fe11e48d322045d5949c83283927a0d790b.tar.bz2
Update aosp/master LLVM for rebase to r230699.
Change-Id: I2b5be30509658cb8266be782de0ab24f9099f9b9
Diffstat (limited to 'utils/release')
-rwxr-xr-xutils/release/merge.sh10
-rwxr-xr-xutils/release/tag.sh39
-rwxr-xr-xutils/release/test-release.sh48
3 files changed, 65 insertions, 32 deletions
diff --git a/utils/release/merge.sh b/utils/release/merge.sh
index 2cf39b2..949c298 100755
--- a/utils/release/merge.sh
+++ b/utils/release/merge.sh
@@ -66,9 +66,11 @@ svn log -c $rev http://llvm.org/svn/llvm-project/$proj/trunk >> $tempfile 2>&1
cd $proj.src
echo "# Updating tree"
svn up
-echo "# Merging r$rev into $proj"
+echo "# Merging r$rev into $proj locally"
svn merge -c $rev https://llvm.org/svn/llvm-project/$proj/trunk . || exit 1
-echo "# Committing changes"
-svn commit -F $tempfile || exit 1
-rm -f $tempfile
+
+echo
+echo "# To commit the merge, run the following in $proj.src/:"
+echo svn commit -F $tempfile
+
exit 0
diff --git a/utils/release/tag.sh b/utils/release/tag.sh
index 390acaf..503413b 100755
--- a/utils/release/tag.sh
+++ b/utils/release/tag.sh
@@ -18,17 +18,21 @@ release=""
rc=""
rebranch="no"
projects="llvm cfe dragonegg test-suite compiler-rt libcxx libcxxabi clang-tools-extra polly lldb lld openmp"
+dryrun=""
+revision="HEAD"
base_url="https://llvm.org/svn/llvm-project"
function usage() {
- echo "usage: `basename $0` -release <num> [-rebranch]"
- echo "usage: `basename $0` -release <num> -rc <num>"
+ echo "usage: `basename $0` -release <num> [-rebranch] [-revision <num>] [-dry-run]"
+ echo "usage: `basename $0` -release <num> -rc <num> [-dry-run]"
echo " "
- echo " -release <num> The version number of the release"
- echo " -rc <num> The release candidate number"
- echo " -rebranch Remove existing branch, if present, before branching"
- echo " -final Tag final release candidate"
+ echo " -release <num> The version number of the release"
+ echo " -rc <num> The release candidate number"
+ echo " -rebranch Remove existing branch, if present, before branching"
+ echo " -final Tag final release candidate"
+ echo " -revision <num> Revision to branch off (default: HEAD)"
+ echo " -dry-run Make no changes to the repository, just print the commands"
}
function tag_version() {
@@ -38,10 +42,11 @@ function tag_version() {
if [ $rebranch = "no" ]; then
continue
fi
- svn remove -m "Removing old release_$branch_release branch for rebranching." \
+ ${dryrun} svn remove -m "Removing old release_$branch_release branch for rebranching." \
$base_url/$proj/branches/release_$branch_release
fi
- svn copy -m "Creating release_$branch_release branch" \
+ ${dryrun} svn copy -m "Creating release_$branch_release branch off revision ${revision}" \
+ -r ${revision} \
$base_url/$proj/trunk \
$base_url/$proj/branches/release_$branch_release
done
@@ -52,10 +57,10 @@ function tag_release_candidate() {
set -x
for proj in $projects ; do
if ! svn ls $base_url/$proj/tags/RELEASE_$tag_release > /dev/null 2>&1 ; then
- svn mkdir -m "Creating release directory for release_$tag_release." $base_url/$proj/tags/RELEASE_$tag_release
+ ${dryrun} svn mkdir -m "Creating release directory for release_$tag_release." $base_url/$proj/tags/RELEASE_$tag_release
fi
if ! svn ls $base_url/$proj/tags/RELEASE_$tag_release/$rc > /dev/null 2>&1 ; then
- svn copy -m "Creating release candidate $rc from release_$tag_release branch" \
+ ${dryrun} svn copy -m "Creating release candidate $rc from release_$tag_release branch" \
$base_url/$proj/branches/release_$branch_release \
$base_url/$proj/tags/RELEASE_$tag_release/$rc
fi
@@ -79,6 +84,13 @@ while [ $# -gt 0 ]; do
-final | --final )
rc="final"
;;
+ -revision | --revision )
+ shift
+ revision="$1"
+ ;;
+ -dry-run | --dry-run )
+ dryrun="echo"
+ ;;
-h | --help | -help )
usage
exit 0
@@ -105,6 +117,13 @@ tag_release=`echo $release | sed -e 's,\.,,g'`
if [ "x$rc" = "x" ]; then
tag_version
else
+ if [ "$revision" != "HEAD" ]; then
+ echo "error: cannot use -revision with -rc"
+ echo
+ usage
+ exit 1
+ fi
+
tag_release_candidate
fi
diff --git a/utils/release/test-release.sh b/utils/release/test-release.sh
index b028924..20f8d97 100755
--- a/utils/release/test-release.sh
+++ b/utils/release/test-release.sh
@@ -39,27 +39,30 @@ do_debug="no"
do_asserts="no"
do_compare="yes"
BuildDir="`pwd`"
+BuildTriple=""
function usage() {
echo "usage: `basename $0` -release X.Y -rc NUM [OPTIONS]"
echo ""
- echo " -release X.Y The release number to test."
- echo " -rc NUM The pre-release candidate number."
- echo " -final The final release candidate."
- echo " -triple TRIPLE The target triple for this machine."
- echo " -j NUM Number of compile jobs to run. [default: 3]"
- echo " -build-dir DIR Directory to perform testing in. [default: pwd]"
- echo " -no-checkout Don't checkout the sources from SVN."
- echo " -no-64bit Don't test the 64-bit version. [default: yes]"
- echo " -enable-ada Build Ada. [default: disable]"
- echo " -disable-clang Do not test clang. [default: enable]"
- echo " -enable-dragonegg Test dragonegg. [default: disable]"
- echo " -enable-fortran Enable Fortran build. [default: disable]"
- echo " -disable-objc Disable ObjC build. [default: enable]"
- echo " -test-debug Test the debug build. [default: no]"
- echo " -test-asserts Test with asserts on. [default: no]"
- echo " -no-compare-files Don't test that phase 2 and 3 files are identical."
- echo " -use-gzip Use gzip instead of xz."
+ echo " -release X.Y The release number to test."
+ echo " -rc NUM The pre-release candidate number."
+ echo " -final The final release candidate."
+ echo " -triple TRIPLE The target triple for this machine."
+ echo " -j NUM Number of compile jobs to run. [default: 3]"
+ echo " -build-dir DIR Directory to perform testing in. [default: pwd]"
+ echo " -no-checkout Don't checkout the sources from SVN."
+ echo " -no-64bit Don't test the 64-bit version. [default: yes]"
+ echo " -enable-ada Build Ada. [default: disable]"
+ echo " -disable-clang Do not test clang. [default: enable]"
+ echo " -enable-dragonegg Test dragonegg. [default: disable]"
+ echo " -enable-fortran Enable Fortran build. [default: disable]"
+ echo " -disable-objc Disable ObjC build. [default: enable]"
+ echo " -test-debug Test the debug build. [default: no]"
+ echo " -test-asserts Test with asserts on. [default: no]"
+ echo " -no-compare-files Don't test that phase 2 and 3 files are identical."
+ echo " -use-gzip Use gzip instead of xz."
+ echo " -build-triple TRIPLE The build triple for this machine"
+ echo " [default: use config.guess]"
}
while [ $# -gt 0 ]; do
@@ -80,6 +83,10 @@ while [ $# -gt 0 ]; do
shift
Triple="$1"
;;
+ -build-triple | --build-triple )
+ shift
+ BuildTriple="$1"
+ ;;
-j* )
NumJobs="`echo $1 | sed -e 's,-j\([0-9]*\),\1,g'`"
if [ -z "$NumJobs" ]; then
@@ -295,16 +302,21 @@ function configure_llvmCore() {
echo "# Using C compiler: $c_compiler"
echo "# Using C++ compiler: $cxx_compiler"
+ build_triple_option="${BuildTriple:+--build=$BuildTriple}"
+
cd $ObjDir
echo "# Configuring llvm $Release-$RC $Flavor"
echo "# $BuildDir/llvm.src/configure --prefix=$InstallDir \
--enable-optimized=$Optimized \
- --enable-assertions=$Assertions"
+ --enable-assertions=$Assertions \
+ --disable-timestamps \
+ $build_triple_option"
env CC="$c_compiler" CXX="$cxx_compiler" \
$BuildDir/llvm.src/configure --prefix=$InstallDir \
--enable-optimized=$Optimized \
--enable-assertions=$Assertions \
--disable-timestamps \
+ $build_triple_option \
2>&1 | tee $LogDir/llvm.configure-Phase$Phase-$Flavor.log
cd $BuildDir
}