dist: do not install build dependencies on build script

We do not want to install dependencies on package building time,
we want to install it on dbuild container.
So drop package installation from the scripts.

scylladb/scylla#7219
This commit is contained in:
Takuya ASADA 2020-09-13 20:12:58 +09:00
parent 23da40b559
commit 99e491df40
2 changed files with 0 additions and 56 deletions

View File

@ -28,16 +28,6 @@ is_redhat_variant() {
is_debian_variant() { is_debian_variant() {
[ -f /etc/debian_version ] [ -f /etc/debian_version ]
} }
pkg_install() {
if is_redhat_variant; then
sudo yum install -y $1
elif is_debian_variant; then
sudo apt-get install -y $1
else
echo "Requires to install following command: $1"
exit 1
fi
}
if [ ! -e scylla-jmx/SCYLLA-RELOCATABLE-FILE ]; then if [ ! -e scylla-jmx/SCYLLA-RELOCATABLE-FILE ]; then
echo "do not directly execute build_rpm.sh, use reloc/build_rpm.sh instead." echo "do not directly execute build_rpm.sh, use reloc/build_rpm.sh instead."
@ -53,37 +43,6 @@ if [ ! -f "$RELOC_PKG" ]; then
exit 1 exit 1
fi fi
if is_debian_variant; then
sudo apt-get -y update
fi
# this hack is needed since some environment installs 'git-core' package, it's
# subset of the git command and doesn't works for our git-archive-all script.
if is_redhat_variant && [ ! -f /usr/libexec/git-core/git-submodule ]; then
sudo yum install -y git
fi
if [ ! -f /usr/bin/git ]; then
pkg_install git
fi
if [ ! -f /usr/bin/python ]; then
pkg_install python
fi
if [ ! -f /usr/sbin/debuild ]; then
pkg_install devscripts
fi
if [ ! -f /usr/bin/dh_testdir ]; then
pkg_install debhelper
fi
if [ ! -f /usr/bin/fakeroot ]; then
pkg_install fakeroot
fi
if [ "$ID" = "ubuntu" ] && [ ! -f /usr/share/keyrings/debian-archive-keyring.gpg ]; then
sudo apt-get install -y debian-archive-keyring
fi
if [ "$ID" = "debian" ] && [ ! -f /usr/share/keyrings/ubuntu-archive-keyring.gpg ]; then
sudo apt-get install -y ubuntu-archive-keyring
fi
RELOC_PKG=$(readlink -f $RELOC_PKG) RELOC_PKG=$(readlink -f $RELOC_PKG)
mv scylla-jmx/debian debian mv scylla-jmx/debian debian

View File

@ -24,14 +24,6 @@ done
is_redhat_variant() { is_redhat_variant() {
[ -f /etc/redhat-release ] [ -f /etc/redhat-release ]
} }
pkg_install() {
if is_redhat_variant; then
sudo yum install -y $1
else
echo "Requires to install following command: $1"
exit 1
fi
}
if [ ! -e SCYLLA-RELOCATABLE-FILE ]; then if [ ! -e SCYLLA-RELOCATABLE-FILE ]; then
echo "do not directly execute build_rpm.sh, use reloc/build_rpm.sh instead." echo "do not directly execute build_rpm.sh, use reloc/build_rpm.sh instead."
@ -47,13 +39,6 @@ if [ ! -f "$RELOC_PKG" ]; then
exit 1 exit 1
fi fi
if [ ! -f /usr/bin/rpmbuild ]; then
pkg_install rpm-build
fi
if [ ! -f /usr/bin/git ]; then
pkg_install git
fi
SCYLLA_VERSION=$(cat SCYLLA-VERSION-FILE) SCYLLA_VERSION=$(cat SCYLLA-VERSION-FILE)
SCYLLA_RELEASE=$(cat SCYLLA-RELEASE-FILE) SCYLLA_RELEASE=$(cat SCYLLA-RELEASE-FILE)
VERSION=$SCYLLA_VERSION-$SCYLLA_RELEASE VERSION=$SCYLLA_VERSION-$SCYLLA_RELEASE