This fixes, e.g., hurd installs from mini ISOs,
which require libp11-kit0 from unreleased for a functioning apt.
is_ports_architecture() extracted from apt-setup's 50mirror:
https://salsa.debian.org/installer-team/apt-setup/-/blob/584e84b5a1d6e71ecb94e503a1a8e546048d215b/generators/50mirror#L28-45
which already included unreleased for new installs on ports arches.
Ref: thread of https://lists.debian.org/debian-hurd/2020/06/msg00015.html
---
debian/bootstrap-base.postinst | 4 ++++
debian/changelog | 8 ++++++++
library.sh | 11 +++++++++++
3 files changed, 23 insertions(+)
diff --git a/debian/bootstrap-base.postinst b/debian/bootstrap-base.postinst
index f25fd167..7e872197 100755
--- a/debian/bootstrap-base.postinst
+++ b/debian/bootstrap-base.postinst
@@ -96,6 +96,9 @@ install_base_system () {
if [ "${EXCLUDES}" ]; then
exclude="--exclude=${EXCLUDES}"
fi
+ if is_ports_architecture "${ARCH}"; then
+ extra_suites="--extra-suites=unreleased"
+ fi
sigcheck="--no-check-gpg"
if [ "$PROTOCOL" = http ] || [ "$PROTOCOL" = ftp ]; then
if type gpgv >/dev/null; then
@@ -149,6 +152,7 @@ install_base_system () {
--debian-installer \
--resolve-deps \
${include} ${exclude} \
+ ${extra_suites} \
${sigcheck} \
${DEBOOTSTRAP_VARIANT} \
${DISTRIBUTION} /target \
diff --git a/debian/changelog b/debian/changelog
index 43ce8dbb..38501c62 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,11 @@
+base-installer (1.195) UNRELEASED; urgency=medium
+
+ [ наб ]
+ * Pass "--extra-suites=unreleased" to debootstrap for ports architectures,
+ fixing, e.g., hurd installs from mini ISOs.
+
+ -- Holger Wansing <hwansing@mailbox.org> Mon, 15 Jun 2020 22:17:27 +0200
+
base-installer (1.194) unstable; urgency=medium
* Team upload
diff --git a/library.sh b/library.sh
index d7f05024..e7fb8f60 100644
--- a/library.sh
+++ b/library.sh
@@ -887,3 +887,14 @@ EOT
cleanup () {
rm -f "$KERNEL_LIST" "$KERNEL_LIST.unfiltered"
}
+
+is_ports_architecture() {
+ case "$1" in
+ alpha|hppa|hurd-i386|ia64|kfreebsd-amd64|kfreebsd-i386|m68k|powerpc|ppc64|riscv64|sh4|sparc64|x32)
+ return 0
+ ;;
+ *)
+ return 1
+ ;;
+ esac
+}
--
2.20.1
Attachment:
signature.asc
Description: PGP signature