Skip to content

Commit

Permalink
Debian arch naming needs a wrapper
Browse files Browse the repository at this point in the history
  • Loading branch information
fauust committed Nov 29, 2023
1 parent bff7134 commit df381fd
Show file tree
Hide file tree
Showing 3 changed files with 26 additions and 10 deletions.
24 changes: 24 additions & 0 deletions scripts/bash_lib.sh
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,30 @@ deb_setup_bb_artifacts_mirror() {
set +u
}

deb_arch() {
case $(arch) in
"x86_64")
echo "amd64"
;;
"x86")
echo "i386"
;;
"aarch64")
echo "arm64"
;;
"ppc64le")
echo "ppc64el"
;;
"s390x")
echo "s390x"
;;
*)
echo "unknown arch"
exit 1
;;
esac
}

upgrade_type_mode() {
case "$branch" in
*galera*)
Expand Down
2 changes: 1 addition & 1 deletion scripts/deb-install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ deb_setup_mariadb_mirror "$master_branch"
# setup repository for BB artifacts
deb_setup_bb_artifacts_mirror

wget -O - "${artifactsURL}/${tarbuildnum}/${parentbuildername}/dists/${VERSION_CODENAME}/main/binary-${arch}/Packages.gz" | gunzip >Packages
wget -O - "${artifactsURL}/${tarbuildnum}/${parentbuildername}/dists/${VERSION_CODENAME}/main/binary-$(deb_arch)/Packages.gz" | gunzip >Packages

set -x

Expand Down
10 changes: 1 addition & 9 deletions scripts/deb-upgrade.sh
Original file line number Diff line number Diff line change
Expand Up @@ -17,14 +17,6 @@ manual_run_switch "$1"
upgrade_type_mode
upgrade_test_type "$test_type"

if [[ $arch == "ppc64le" ]]; then
arch=ppc64el
elif [[ $arch == "x86" ]]; then
arch=i386
elif [[ $arch == "aarch64" ]]; then
arch=arm64
fi

bb_print_env

# This test can be performed in four modes:
Expand Down Expand Up @@ -313,7 +305,7 @@ store_mariadb_server_info new
# set -o pipefail
# if [[ $test_mode == "all" ]]; then
# set -o pipefail
# if wget -q --timeout=20 --no-check-certificate "https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/master/buildbot/baselines/ldd.${major_version}.${version_name}.${arch}" -O /tmp/ldd.baseline; then
# if wget -q --timeout=20 --no-check-certificate "https://raw.githubusercontent.com/MariaDB/mariadb.org-tools/master/buildbot/baselines/ldd.${major_version}.${version_name}.$(deb_arch)" -O /tmp/ldd.baseline; then
# ldd_baseline=/tmp/ldd.baseline
# else
# ldd_baseline=/buildbot/ldd.old
Expand Down

0 comments on commit df381fd

Please sign in to comment.