[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Bug#929881: cdimage.debian.org: Unofficial non-free live images have 400+ MB bloat from extra firmware



Package: cdimage.debian.org
Severity: important
Tags: patch

Debian Images Team,

Sizes of netinst images with and without firmware:
   375 MiB  firmware-testing-amd64-netinst.iso
   334 MiB  debian-testing-amd64-netinst.iso
   -------
    41 MiB  difference

Sizes of Live Standard images with and without firmware:
  1285 MiB  debian-live-testing-amd64-standard+nonfree.iso
   824 MiB  debian-live-testing-amd64-standard.iso
  --------
   461 MiB  difference

debian-cd generates netinst images:
  * Only includes firmware|microcode packages that contain files
    in /lib/firmware
  * https://salsa.debian.org/images-team/debian-cd/blob/master/tools/generate_firmware_task
  * https://salsa.debian.org/images-team/debian-cd/blob/master/tools/make-firmware-image

live-setup generates Live images:
  * Includes *all* firmware|microcode main|non-free packages
  * Also includes their massive dependencies
  * https://salsa.debian.org/images-team/live-setup/blob/master/available/run-30live-wrapper

I can think of three fixes for live-setup:
  1) Have live-setup use the firmware task generated by debian-cd
  2) Copy make-firmware-image to live-setup for use there
  3) Patch live-setup run-30live-wrapper with the **untested** patch below

By the way, this bug report supercedes my earlier #929790:
	https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=929790

Thank you!
Daniel Lewart
Urbana, IL
---
diff -ru a/available/run-30live-wrapper b/available/run-30live-wrapper
--- a/available/run-30live-wrapper	2019-05-01 08:24:07.000000000 -0500
+++ b/available/run-30live-wrapper	2019-06-02 00:00:00.000000000 -0500
@@ -98,12 +98,26 @@
 # Work out which packages to add for non-free firmware
 select_firmware_packages () {
     ARCH=$1
-    SECTIONS="main non-free"
-    PKGS=""
-    for SECTION in ${SECTIONS}; do
-	PKGS="$PKGS "$(wget -q $MIRROR/dists/${CODENAME}/${SECTION}/binary-${ARCH}/Packages.gz -O- | gzip -cd - | \
-	      grep-dctrl -Pe '.*(firmware|microcode).*' -s Package -n | sort -u)
-    done
+    case "$ARCH" in
+	amd64|i386)
+	    ;;
+	*)
+	    echo "Unknown ARCH $ARCH; abort!"
+	    exit 1
+	    ;;
+    esac
+
+    # Q.v. debian-cd/tools generate_firmware_task & make-firmware-image
+    PKGS="amd64-microcode atmel-firmware bluez-firmware
+dahdi-firmware-nonfree firmware-amd-graphics firmware-ath9k-htc
+firmware-atheros firmware-b43-installer firmware-b43legacy-installer
+firmware-bnx2 firmware-bnx2x firmware-brcm80211 firmware-cavium
+firmware-intel-sound firmware-intelwimax firmware-ipw2x00 firmware-ivtv
+firmware-iwlwifi firmware-libertas firmware-linux-nonfree
+firmware-misc-nonfree firmware-myricom firmware-netronome
+firmware-netxen firmware-qcom-media firmware-qlogic firmware-realtek
+firmware-samsung firmware-siano firmware-ti-connectivity firmware-zd1211
+hdmi2usb-fx2-firmware intel-microcode"
     echo $PKGS
 }


Reply to: