mirror of
https://git.proxmox.com/git/llvm-toolchain
synced 2025-08-15 20:44:07 +00:00
various improvements to the repack scripts
This commit is contained in:
parent
d8862b8e56
commit
7158e73379
3
debian/README
vendored
3
debian/README
vendored
@ -69,7 +69,8 @@ you should use,
|
|||||||
|
|
||||||
For a stable release, the syntax is:
|
For a stable release, the syntax is:
|
||||||
|
|
||||||
$ sh 9/debian/orig-tar.sh 9.0
|
$ sh 9/debian/orig-tar.sh 9.0.0
|
||||||
|
|
||||||
|
|
||||||
Additional maintainer scripts
|
Additional maintainer scripts
|
||||||
=============================
|
=============================
|
||||||
|
47
debian/orig-tar.sh
vendored
47
debian/orig-tar.sh
vendored
@ -14,13 +14,15 @@
|
|||||||
set -e
|
set -e
|
||||||
|
|
||||||
# commands:
|
# commands:
|
||||||
# sh -v 8/debian/orig-tar.sh release/8.x
|
# sh 9/debian/orig-tar.sh release/9.x
|
||||||
# sh -v 8/debian/orig-tar.sh 8.0.0 rc3
|
# sh 9/debian/orig-tar.sh 9.0.0 rc3
|
||||||
# sh -v 8/debian/orig-tar.sh 8.0.1 rc3
|
# sh 9/debian/orig-tar.sh 9.0.1 rc3
|
||||||
|
# Stable release
|
||||||
|
# sh 9/debian/orig-tar.sh 9.0.0 9.0.0
|
||||||
|
|
||||||
|
|
||||||
# To create an rc1 release:
|
# To create an rc1 release:
|
||||||
# sh 4.0/debian/orig-tar.sh RELEASE_40 rc1
|
# sh 4.0/debian/orig-tar.sh release/9.x
|
||||||
|
|
||||||
GIT_BASE_URL=https://github.com/llvm/llvm-project
|
GIT_BASE_URL=https://github.com/llvm/llvm-project
|
||||||
|
|
||||||
@ -36,16 +38,20 @@ if test -z "$CURRENT_VERSION"; then
|
|||||||
echo "Could not detect the full version"
|
echo "Could not detect the full version"
|
||||||
exit 1
|
exit 1
|
||||||
fi
|
fi
|
||||||
echo $MAJOR_VERSION
|
|
||||||
echo $CURRENT_VERSION
|
|
||||||
cd -
|
cd -
|
||||||
|
|
||||||
|
|
||||||
if test -n "$1"; then
|
if test -n "$1"; then
|
||||||
# https://llvm.org/svn/llvm-project/{cfe,llvm,compiler-rt,...}/branches/google/stable/
|
# https://github.com/llvm/llvm-project/tree/release/9.x
|
||||||
# For example: sh 4.0/debian/orig-tar.sh release_400
|
# For example: sh 4.0/debian/orig-tar.sh release/9.x
|
||||||
BRANCH=$1
|
BRANCH=$1
|
||||||
|
if ! echo $1|grep release/; then
|
||||||
|
# The first argument is NOT a branch, means that it is a stable release
|
||||||
|
FINAL_RELEASE=true
|
||||||
|
EXACT_VERSION=$1
|
||||||
|
fi
|
||||||
else
|
else
|
||||||
|
# No argument, we need trunk
|
||||||
cd $PATH_DEBIAN
|
cd $PATH_DEBIAN
|
||||||
SOURCE=$(dpkg-parsechangelog |grep ^Source|awk '{print $2}')
|
SOURCE=$(dpkg-parsechangelog |grep ^Source|awk '{print $2}')
|
||||||
cd -
|
cd -
|
||||||
@ -57,13 +63,11 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
if test -n "$1" -a -n "$2"; then
|
if test -n "$1" -a -n "$2"; then
|
||||||
# https://llvm.org/svn/llvm-project/{cfe,llvm,compiler-rt,...}/tags/RELEASE_34/rc1/
|
# https://github.com/llvm/llvm-project/releases/tag/llvmorg-9.0.0
|
||||||
# For example: sh 4.0/debian/orig-tar.sh RELEASE_401 rc3 4.0.1
|
# For example: sh 4.0/debian/orig-tar.sh 4.0.1 rc3
|
||||||
|
# or sh 9/debian/orig-tar.sh 9.0.0
|
||||||
TAG=$2
|
TAG=$2
|
||||||
RCRELEASE="true"
|
RCRELEASE="true"
|
||||||
if test -z "$3"; then
|
|
||||||
echo "Please provide the exact version. Used for the tarball name Ex: 4.0.1"
|
|
||||||
fi
|
|
||||||
EXACT_VERSION=$1
|
EXACT_VERSION=$1
|
||||||
fi
|
fi
|
||||||
|
|
||||||
@ -73,10 +77,10 @@ cd git-archive
|
|||||||
if test -d llvm-project; then
|
if test -d llvm-project; then
|
||||||
# Update it
|
# Update it
|
||||||
cd llvm-project
|
cd llvm-project
|
||||||
git remote update
|
git remote update > /dev/null
|
||||||
git reset --hard origin/master
|
git reset --hard origin/master > /dev/null
|
||||||
git clean -qfd
|
git clean -qfd
|
||||||
git checkout master
|
git checkout master > /dev/null
|
||||||
cd ..
|
cd ..
|
||||||
else
|
else
|
||||||
# Download it
|
# Download it
|
||||||
@ -84,7 +88,7 @@ else
|
|||||||
fi
|
fi
|
||||||
|
|
||||||
cd llvm-project
|
cd llvm-project
|
||||||
if test -z "$TAG"; then
|
if test -z "$TAG" -a -z "$FINAL_RELEASE"; then
|
||||||
# Building a branch
|
# Building a branch
|
||||||
git checkout $BRANCH
|
git checkout $BRANCH
|
||||||
if test $BRANCH != "master"; then
|
if test $BRANCH != "master"; then
|
||||||
@ -110,12 +114,11 @@ else
|
|||||||
fi
|
fi
|
||||||
git_tag="llvmorg-$EXACT_VERSION"
|
git_tag="llvmorg-$EXACT_VERSION"
|
||||||
VERSION=$EXACT_VERSION
|
VERSION=$EXACT_VERSION
|
||||||
|
if test -n "$TAG" -a -z "$FINAL_RELEASE"; then
|
||||||
if test -n "$TAG"; then
|
|
||||||
git_tag="$git_tag-$TAG"
|
git_tag="$git_tag-$TAG"
|
||||||
VERSION="$VERSION~+$TAG"
|
VERSION="$VERSION~+$TAG"
|
||||||
fi
|
fi
|
||||||
echo $git_tag
|
|
||||||
git checkout $git_tag > /dev/null
|
git checkout $git_tag > /dev/null
|
||||||
|
|
||||||
fi
|
fi
|
||||||
@ -123,11 +126,11 @@ fi
|
|||||||
# cleanup
|
# cleanup
|
||||||
rm -rf */www/
|
rm -rf */www/
|
||||||
|
|
||||||
cd -
|
cd ../
|
||||||
BASE="llvm-toolchain-${MAJOR_VERSION}_${VERSION}"
|
BASE="llvm-toolchain-${MAJOR_VERSION}_${VERSION}"
|
||||||
FILENAME="${BASE}.orig.tar.xz"
|
FILENAME="${BASE}.orig.tar.xz"
|
||||||
echo "Compressing to $FILENAME"
|
echo "Compressing to $FILENAME"
|
||||||
tar Jcf $FILENAME --exclude .git --transform="s/llvm-project/$BASE/" llvm-project
|
tar Jcf ../$FILENAME --exclude .git --transform="s/llvm-project/$BASE/" llvm-project
|
||||||
|
|
||||||
export DEBFULLNAME="Sylvestre Ledru"
|
export DEBFULLNAME="Sylvestre Ledru"
|
||||||
export DEBEMAIL="sylvestre@debian.org"
|
export DEBEMAIL="sylvestre@debian.org"
|
||||||
|
Loading…
Reference in New Issue
Block a user