aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar Unit 193 <unit193@ubuntu.com>2018-10-23 20:26:40 -0400
committerLibravatar Unit 193 <unit193@ubuntu.com>2018-10-23 20:26:40 -0400
commit827a047f6fe1a8eff30c6059c8822a4b65665aa9 (patch)
treea52dd6a9bf2a0f6276f5bc043a37d91ad885b792
parent781cf3aa0d3f9a93d84481833f5c83aa9ee68ac0 (diff)
downloadarch-install-scripts-827a047f6fe1a8eff30c6059c8822a4b65665aa9.tar.bz2
arch-install-scripts-827a047f6fe1a8eff30c6059c8822a4b65665aa9.tar.xz
arch-install-scripts-827a047f6fe1a8eff30c6059c8822a4b65665aa9.tar.zst
New upstream version 20upstream/20
-rw-r--r--Makefile2
-rw-r--r--arch-chroot.in11
-rw-r--r--common5
-rw-r--r--genfstab.in3
-rw-r--r--pacstrap.in2
5 files changed, 19 insertions, 4 deletions
diff --git a/Makefile b/Makefile
index fd2be13..403744b 100644
--- a/Makefile
+++ b/Makefile
@@ -1,4 +1,4 @@
-VER=19
+VER=20
PREFIX = /usr/local
diff --git a/arch-chroot.in b/arch-chroot.in
index bfb83a3..fd6140e 100644
--- a/arch-chroot.in
+++ b/arch-chroot.in
@@ -13,6 +13,13 @@ usage: ${0##*/} chroot-dir [command]
If 'command' is unspecified, ${0##*/} will launch /bin/bash.
+Note that when using arch-chroot, the target chroot directory *should* be a
+mountpoint. This ensures that tools such as pacman(8) or findmnt(8) have an
+accurate hierarchy of the mounted filesystems within the chroot.
+
+If your chroot target is not a mountpoint, you can bind mount the directory on
+itself to make it a mountpoint, i.e. 'mount --bind /your/chroot /your/chroot'.
+
EOF
}
@@ -70,6 +77,10 @@ shift
[[ -d $chrootdir ]] || die "Can't create chroot on non-directory %s" "$chrootdir"
+if ! mountpoint -q "$chrootdir"; then
+ warning "$chrootdir is not a mountpoint. This may have undesirable side effects."
+fi
+
chroot_setup "$chrootdir" || die "failed to setup chroot %s" "$chrootdir"
chroot_add_resolv_conf "$chrootdir" || die "failed to setup resolv.conf"
diff --git a/common b/common
index 65f3362..c3c2bd5 100644
--- a/common
+++ b/common
@@ -46,6 +46,7 @@ declare -A fsck_types=([cramfs]=1
out() { printf "$1 $2\n" "${@:3}"; }
error() { out "==> ERROR:" "$@"; } >&2
+warning() { out "==> WARNING:" "$@"; } >&2
msg() { out "==>" "$@"; }
msg2() { out " ->" "$@";}
die() { error "$@"; exit 1; }
@@ -91,7 +92,9 @@ chroot_setup() {
}
chroot_teardown() {
- umount "${CHROOT_ACTIVE_MOUNTS[@]}"
+ if (( ${#CHROOT_ACTIVE_MOUNTS[@]} )); then
+ umount "${CHROOT_ACTIVE_MOUNTS[@]}"
+ fi
unset CHROOT_ACTIVE_MOUNTS
}
diff --git a/genfstab.in b/genfstab.in
index 7663522..0ebb831 100644
--- a/genfstab.in
+++ b/genfstab.in
@@ -83,7 +83,8 @@ usage: ${0##*/} [options] root
-L Use labels for source identifiers (shortcut for -t LABEL)
-p Exclude pseudofs mounts (default behavior)
-P Include pseudofs mounts
- -t TAG Use TAG for source identifiers
+ -t TAG Use TAG for source identifiers (TAG should be one of: LABEL,
+ UUID, PARTLABEL, PARTUUID)
-U Use UUIDs for source identifiers (shortcut for -t UUID)
-h Print this help message
diff --git a/pacstrap.in b/pacstrap.in
index 72f2809..0c34df4 100644
--- a/pacstrap.in
+++ b/pacstrap.in
@@ -24,7 +24,7 @@ usage: ${0##*/} [options] root [packages...]
-C config Use an alternate config file for pacman
-c Use the package cache on the host, rather than the target
-G Avoid copying the host's pacman keyring to the target
- -i Avoid auto-confirmation of package selections
+ -i Prompt for package confirmation when needed
-M Avoid copying the host's mirrorlist to the target
-h Print this help message