From 74fa1a40ca32873e538f1664578ef0f4e8515faf Mon Sep 17 00:00:00 2001 From: Takuya ASADA Date: Mon, 8 Oct 2018 20:07:24 +0900 Subject: [PATCH] dist/debian: install GPG key for cross-building We found on some Debian environment Ubuntu .deb build fails with gpg error because lack of Ubuntu GPG key, so we need to install it before start pbuilder. Same as on Ubuntu, it needs to install Debian GPG key. See scylladb/scylla#3823 Signed-off-by: Takuya ASADA Message-Id: <20181008110724.18335-1-syuu@scylladb.com> --- dist/debian/build_deb.sh | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/dist/debian/build_deb.sh b/dist/debian/build_deb.sh index 49c98ab..996558d 100755 --- a/dist/debian/build_deb.sh +++ b/dist/debian/build_deb.sh @@ -96,6 +96,12 @@ if [ ! -f /usr/bin/pystache ]; then fi 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 if [ -z "$TARGET" ]; then if is_debian_variant; then