Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.bugs.dist > #1018450

Bug#690210: strange sources.list when using debootstrap with option --extra-suite

From jhcha54008 <jhcha54008@free.fr>
Newsgroups linux.debian.bugs.dist, linux.debian.maint.boot
Subject Bug#690210: strange sources.list when using debootstrap with option --extra-suite
Date 2020-07-18 20:30 +0200
Message-ID <AtZKV-4se-1@gated-at.bofh.it> (permalink)
References <jTmjv-3XS-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Cross-posted to 2 groups.

Show all headers | View raw


Hi again,

It seems that components are duplicated when using option --extra-suite in debootstrap.

I got the following /etc/apt/sources.list (note the 'main' component repeated twice or four times)

   --------------8<----------/etc/apt/sources.list---------------8<----------
deb http://deb.debian.org/debian stable main main
deb http://deb.debian.org/debian buster-proposed-updates main main main main
   --------------8<----------/etc/apt/sources.list---------------8<----------

as a result of the invocation of debootstrap (version 1.0.123) :

# debootstrap --variant=minbase --extra-suites=buster-proposed-updates stable \
  my_stable_chroot_with_updates

The partial fix for bug #690210 seems to be the culprit. I recover the expected 
sources.list with the patch below.

Thank you for your ongoing work on debootstrap !

Regards,
JH Chatenet 

diff -Naur a/usr/share/debootstrap/functions b/usr/share/debootstrap/functions
--- a/usr/share/debootstrap/functions	2020-03-14 02:07:20.000000000 +0100
+++ b/usr/share/debootstrap/functions	2020-07-15 18:49:15.214419623 +0200
@@ -547,6 +547,9 @@
 		mv "$reldest" "$reldest.malformed"
 		error 1 INVALIDREL "Invalid Release file, no valid components"
 	fi
+
+	# Suppress duplicated components (this may occur if EXTRA_SUITES are selected)
+	COMPONENTS=$(echo "$COMPONENTS" | tr ' ' '\n' | sort | uniq | tr '\n' ' ')
 }
 
 CODENAME=""
@@ -1110,6 +1113,7 @@
 	for m in "$@"; do
 		for s in $SUITE $EXTRA_SUITES; do
 			local cs c path pkgdest
+			cs=""
 			for c in ${COMPONENTS:-$USE_COMPONENTS}; do
 				path="dists/$s/$c/binary-$ARCH/Packages"
 				pkgdest="$TARGET/$($DLDEST pkg "$s" "$c" "$ARCH" "$m" "$path")"

Back to linux.debian.bugs.dist | Previous | Next | Find similar | Unroll thread


Thread

Bug#690210: strange sources.list when using debootstrap with option --extra-suite jhcha54008 <jhcha54008@free.fr> - 2020-07-18 20:30 +0200

csiph-web