Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
path: root/arch-nspawn.in
diff options
context:
space:
mode:
Diffstat (limited to 'arch-nspawn.in')
-rw-r--r--arch-nspawn.in9
1 files changed, 6 insertions, 3 deletions
diff --git a/arch-nspawn.in b/arch-nspawn.in
index 357d950..efdd97e 100644
--- a/arch-nspawn.in
+++ b/arch-nspawn.in
@@ -16,7 +16,7 @@ working_dir=''
usage() {
echo "Usage: ${0##*/} [options] working-dir [systemd-nspawn arguments]"
- echo "A wrapper around systemd-nspawn. Provides support for pacman."
+ echo "A wrapper around systemd-nspawn. Provides support for pacman."
echo
echo ' options:'
echo ' -C <file> Location of a pacman config file'
@@ -34,7 +34,7 @@ while getopts 'hC:M:c:' arg; do
M) makepkg_conf="$OPTARG" ;;
c) cache_dir="$OPTARG" ;;
h|?) usage ;;
- *) error "invalid argument '$arg'"; usage ;;
+ *) error "invalid argument '%s'" "$arg"; usage ;;
esac
done
shift $(($OPTIND - 1))
@@ -88,13 +88,16 @@ umask 0022
if [[ ! -f "$working_dir/.arch-chroot" ]]; then
die "'%s' does not appear to be an Arch chroot." "$working_dir"
elif [[ $(cat "$working_dir/.arch-chroot") != $CHROOT_VERSION ]]; then
- die "chroot '%s' is not at version %s. Please rebuild." "$working_dir" "$CHROOT_VERSION"
+ die "chroot '%s' is not at version %s. Please rebuild." "$working_dir" "$CHROOT_VERSION"
fi
build_mount_args
copy_hostconf
eval $(grep '^CARCH=' "$working_dir/etc/makepkg.conf")
+case "$CARCH" in
+ armv7h) CARCH=armv7l;;
+esac
exec ${CARCH:+setarch "$CARCH"} systemd-nspawn -q \
-D "$working_dir" \