summaryrefslogtreecommitdiff
path: root/scripts/uchroot
diff options
context:
space:
mode:
authorKarel Kočí <karel.koci@nic.cz>2019-12-02 13:28:18 +0100
committerKarel Kočí <karel.koci@nic.cz>2019-12-02 13:28:18 +0100
commitce6be2d4d764533de7c9040c797d9ad307cf7ac7 (patch)
tree9e9e23f6ee9662dd48f2c0539475ee60c206ed24 /scripts/uchroot
parent9fecb394140052194a2ed01e46ad60b0003cd8c1 (diff)
downloadlaminar-cnf-ce6be2d4d764533de7c9040c797d9ad307cf7ac7.tar.gz
laminar-cnf-ce6be2d4d764533de7c9040c797d9ad307cf7ac7.tar.bz2
laminar-cnf-ce6be2d4d764533de7c9040c797d9ad307cf7ac7.zip
Try to fix armhf compilation
Diffstat (limited to 'scripts/uchroot')
-rwxr-xr-xscripts/uchroot3
1 files changed, 2 insertions, 1 deletions
diff --git a/scripts/uchroot b/scripts/uchroot
index 5a876c2..fe07178 100755
--- a/scripts/uchroot
+++ b/scripts/uchroot
@@ -3,6 +3,7 @@
# Configuration has to be passed trough envrionment.
# ROOT: path to directory to chroot in
# ARCH: optional target architecture (if qemu should be used)
+# QEMU_ARCH: optional qemu architecture to replace ARCH
# MOUNT: pairs of two paths separated by colon (LOCAL:INROOT)
set -e
if [ "$(id -u)" != "0" ]; then
@@ -37,7 +38,7 @@ done <<<"$MOUNT"
cp -f /etc/resolv.conf "$ROOT/etc/resolv.conf"
cp -f /etc/hosts "$ROOT/etc/hosts"
if [ "$ARCH" != "$(arch)" ]; then
- qemu_exec="$(which "qemu-$ARCH")"
+ qemu_exec="$(which "qemu-${QEMU_ARCH:-$ARCH}")"
cp -f "$qemu_exec" "$ROOT$qemu_exec"
fi