Skip to content

Commit

Permalink
[buildbot] Wait for apt lock
Browse files Browse the repository at this point in the history
  • Loading branch information
vitalybuka authored Jan 9, 2024
1 parent b586eaf commit 6bbe0ff
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions buildbot/install_deps.sh
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,13 @@
for i in `seq 1 5`; do
sleep $SLEEP
SLEEP=$(( SLEEP + 10))
APT_OPTS="-o DPkg::Lock::Timeout=300 -qq -y"

(
set -ex
apt-get -qq -y update || exit 1
apt-get install -qq -y gnupg || exit 1
rm -f /etc/apt/sources.list.d/scalibr-apt.list # can't update
apt ${APT_OPTS} update || exit 1
apt ${APT_OPTS} install gnupg || exit 1

ARCH_PACKAGES=
if [[ "$(arch)" == "x86_64" ]]; then
Expand All @@ -19,9 +21,9 @@

echo 'debconf debconf/frontend select Noninteractive' | debconf-set-selections
dpkg --configure -a
apt-get -qq -y update || exit 1
apt ${APT_OPTS} update || exit 1

apt-get install -qq -y \
apt ${APT_OPTS} install \
${ARCH_PACKAGES} \
automake \
bc \
Expand Down Expand Up @@ -85,4 +87,4 @@ update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.lld" 30
update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.gold" 20
update-alternatives --install "/usr/bin/ld" "ld" "/usr/bin/ld.bfd" 10

apt-get -qq -y clean
apt ${APT_OPTS} clean

0 comments on commit 6bbe0ff

Please sign in to comment.