Commit 53e3722a authored by Frans Pop's avatar Frans Pop
Browse files

Don't install Recommends during base system installation

Analysis has shown that the previous change to install Recommends as set
in debconf leads to inconsistent results (as debootstrap does not honor
Recommends) and would require --no-recommends for most system boot related
packages (udev, initramfs-tools, mdadm, etc.) to ensure consistency between
installs and to avoid premature installation of e.g. exim4.

Therefore initially set up APT not to install Recommends and reconfigure it
at the very end according to the debconf setting.

References:
- http://lists.debian.org/debian-boot/2010/02/msg00033.html

r62344
parent 2fb8abab
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -144,6 +144,7 @@ waypoint 2 install_filesystems
waypoint 1	pick_kernel
waypoint 20	install_linux
waypoint 10	install_extra
waypoint 0	final_apt_preferences
waypoint 0	cleanup

run_waypoints base-installer/progress/installing-base
+5 −0
Original line number Diff line number Diff line
@@ -8,6 +8,11 @@ base-installer (1.105) UNRELEASED; urgency=low

  [ Frans Pop ]
  * powerpc: add kernel selection support for PlayStation 3 systems.
  * Don't install Recommends during base system installation as it leads to
    inconsistencies and requires too many exceptions. Instead delay enabling
    installation of Recommends to the very end of base system installation.
    Any package installations after base-installer will follow the debconf
    setting install-recommends, unless overridden in a call to 'apt-install'.

 -- Frans Pop <fjp@debian.org>  Thu, 18 Feb 2010 16:07:31 +0100

+11 −5
Original line number Diff line number Diff line
@@ -159,12 +159,10 @@ install_filesystems () {
configure_apt_preferences () {
	[ ! -d "$APT_CONFDIR" ] && mkdir -p "$APT_CONFDIR"

	# Install Recommends?
	if db_get base-installer/install-recommends && [ "$RET" = false ]; then
	# Don't install Recommends during base-installer
	cat >$APT_CONFDIR/00InstallRecommends <<EOT
APT::Install-Recommends "false";
EOT
	fi

	# Make apt trust Debian CDs. This is not on by default (we think).
	# This will be left in place on the installed system.
@@ -187,6 +185,14 @@ EOT
	fi
}

final_apt_preferences () {
	# From here on install Recommends as configured
	db_get base-installer/install-recommends
	if [ "$RET" = true ]; then
		rm -f $APT_CONFDIR/00InstallRecommends
	fi
}

apt_update () {
	log-output -t base-installer chroot /target apt-get update \
		|| apt_update_failed=$?