summaryrefslogtreecommitdiff
path: root/functions
diff options
context:
space:
mode:
authorLyndon Brown <jnqnfe@gmail.com>2020-05-04 23:15:52 +0100
committerLyndon Brown <jnqnfe@gmail.com>2020-05-04 23:22:10 +0100
commit8a1bbe0841ced044444ebf4d7f2b44a689b9c26b (patch)
tree242ad330b4567c6352956b4dbd589a11dbba9305 /functions
parent08c86dc8ace433bd1efacc807357dc92661510ab (diff)
downloadvyos-live-build-8a1bbe0841ced044444ebf4d7f2b44a689b9c26b.tar.gz
vyos-live-build-8a1bbe0841ced044444ebf4d7f2b44a689b9c26b.zip
arches: tidy
Gbp-Dch: Ignore
Diffstat (limited to 'functions')
-rwxr-xr-xfunctions/architectures.sh29
1 files changed, 9 insertions, 20 deletions
diff --git a/functions/architectures.sh b/functions/architectures.sh
index b7f8b979c..43822b54a 100755
--- a/functions/architectures.sh
+++ b/functions/architectures.sh
@@ -12,23 +12,18 @@
Check_architectures ()
{
local ARCHITECTURE
- for ARCHITECTURE in "${@}"
- do
- if [ "${ARCHITECTURE}" = "${LB_ARCHITECTURE}" ]
- then
+ for ARCHITECTURE in "${@}"; do
+ if [ "${ARCHITECTURE}" = "${LB_ARCHITECTURE}" ]; then
return
fi
- if [ "${ARCHITECTURE}" = "${LB_BOOTSTRAP_QEMU_ARCHITECTURE}" ]
- then
- if [ ! -e "${LB_BOOTSTRAP_QEMU_STATIC}" ]
- then
+ if [ "${ARCHITECTURE}" = "${LB_BOOTSTRAP_QEMU_ARCHITECTURE}" ]; then
+ if [ ! -e "${LB_BOOTSTRAP_QEMU_STATIC}" ]; then
Echo_warning "skipping %s, qemu-static binary ${LB_BOOTSTRAP_QEMU_ARCHITECTURE} was not found" "${0}"
continue
fi
- if [ ! -x "${LB_BOOTSTRAP_QEMU_STATIC}" ]
- then
+ if [ ! -x "${LB_BOOTSTRAP_QEMU_STATIC}" ]; then
Echo_warning "skipping %s, qemu-static binary ${LB_BOOTSTRAP_QEMU_STATIC} is not executable" "${0}"
continue
fi
@@ -44,8 +39,7 @@ Check_architectures ()
Check_crossarchitectures ()
{
local HOST
- if command -v dpkg >/dev/null
- then
+ if command -v dpkg >/dev/null; then
HOST="$(dpkg --print-architecture)"
else
HOST="$(uname -m)"
@@ -66,23 +60,18 @@ Check_crossarchitectures ()
;;
esac
- if [ "${LB_ARCHITECTURE}" = "${LB_BOOTSTRAP_QEMU_ARCHITECTURE}" ]
- then
-
- if [ ! -e "${LB_BOOTSTRAP_QEMU_STATIC}" ]
- then
+ if [ "${LB_ARCHITECTURE}" = "${LB_BOOTSTRAP_QEMU_ARCHITECTURE}" ]; then
+ if [ ! -e "${LB_BOOTSTRAP_QEMU_STATIC}" ]; then
Echo_warning "skipping %s, qemu-static binary ${LB_BOOTSTRAP_QEMU_ARCHITECTURE} was not found" "${0}"
exit 0
fi
- if [ ! -x "${LB_BOOTSTRAP_QEMU_STATIC}" ]
- then
+ if [ ! -x "${LB_BOOTSTRAP_QEMU_STATIC}" ]; then
Echo_warning "skipping %s, qemu-static binary ${LB_BOOTSTRAP_QEMU_STATIC} is not executable" "${0}"
exit 0
fi
return
fi
-
Check_architectures "${CROSS}"
}