Bug#989306: cups-filters: parallel port modules force included on ARM kernels

2021-06-02 Thread Didier 'OdyX' Raboud
Control: tags -1 +pending

Hello Jonathan, and thanks for your bugreport,

It might be very old, but it was apparently never properly reported to Debian; 
so thanks for that!

Le lundi, 31 mai 2021, 20.28:39 h CEST Jonathan Lane a écrit :
> The file /etc/modules-load.d/cups.conf contains invocations to load
> modules lp, ppdev, and parport_pc, which are unavailable on the latest
> arm64 kernels in Debian 10, and will likely remain so forever, at least
> parport_pc, because ARM systems do not have PC parallel ports.  This
> results in systemd-load-modules.service reporting failure every boot.
> The fix is only including this file on architectures where those kernel
> modules are meaningful.  This is a very old bug and appears to be a
> regression, since it was known at least as far back as 2015 by the
> Ubuntu maintainers.

Would the attached patch solve this bug meaningfully? It seems to work as-is 
on amd64; could you confirm it's working on arm*?

Best,
OdyX>From 9a629787fd476efceb1885bc6fe9c9df336c689b Mon Sep 17 00:00:00 2001
From: Didier Raboud 
Date: Wed, 2 Jun 2021 20:33:19 +0200
Subject: [PATCH] Only install /etc/modules-load.d/cups-filters.conf in amd64
 i386 mips64el mipsel alpha hppa ia64 sparc64

Closes: #989306
---
 debian/rules | 7 ++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/debian/rules b/debian/rules
index 30b23d06d..7246a2fe1 100755
--- a/debian/rules
+++ b/debian/rules
@@ -1,5 +1,7 @@
 #!/usr/bin/make -f
 
+include /usr/share/dpkg/architecture.mk
+
 derives_from_ubuntu := $(shell (dpkg-vendor --derives-from Ubuntu && echo "yes") || echo "no")
 
 export DEB_BUILD_MAINT_OPTIONS = hardening=+all
@@ -48,8 +50,11 @@ else
 	rsvg-convert debian/local/default-testpage-debian.svg -f pdf > debian/cups-filters/usr/share/cups/data/default-testpage.pdf
 endif
 
-	# Install the modules loader for lp, ppdev and parport_pc
+# Known not-present: m68k hurd-i386 kfreebsd-{amd64,i386}
+ifneq ($(filter $(DEB_HOST_ARCH),amd64 i386 mips64el mipsel alpha hppa ia64 sparc64),)
+	# Install the modules loader for lp, ppdev and parport_pc, only on allow-listed architectures where these are known-present
 	install -D -m 644 debian/local/modules-load.conf debian/cups-filters/etc/modules-load.d/cups-filters.conf
+endif
 
 	dh_apparmor -pcups-browsed --profile-name=usr.sbin.cups-browsed
 
-- 
2.32.0.rc2



Bug#989306: cups-filters: parallel port modules force included on ARM kernels

2021-05-31 Thread Jonathan Lane
Package: cups-filters
Version: 1.21.6-5
Severity: important
Tags: patch

Dear Maintainer,

The file /etc/modules-load.d/cups.conf contains invocations to load
modules lp, ppdev, and parport_pc, which are unavailable on the latest
arm64 kernels in Debian 10, and will likely remain so forever, at least
parport_pc, because ARM systems do not have PC parallel ports.  This
results in systemd-load-modules.service reporting failure every boot.
The fix is only including this file on architectures where those kernel
modules are meaningful.  This is a very old bug and appears to be a
regression, since it was known at least as far back as 2015 by the
Ubuntu maintainers.

https://github.com/raphael/linux-samus/issues/25

-- System Information:
Debian Release: 10.9
  APT prefers stable-updates
  APT policy: (500, 'stable-updates'), (500, 'stable')
Architecture: arm64 (aarch64)

Kernel: Linux 4.19.0-16-arm64 (SMP w/4 CPU cores)
Locale: LANG=en_US.UTF-8, LC_CTYPE=en_US.UTF-8 (charmap=UTF-8), 
LANGUAGE=en_US.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
LSM: AppArmor: enabled

Versions of packages cups-filters depends on:
ii  bc 1.07.1-2+b1
ii  cups-filters-core-drivers  1.21.6-5
ii  ghostscript9.27~dfsg-2+deb10u4
ii  libc6  2.28-10
ii  libcups2   2.2.10-6+deb10u4
ii  libcupsfilters11.21.6-5
ii  libcupsimage2  2.2.10-6+deb10u4
ii  libfontconfig1 2.13.1-2
ii  libfontembed1  1.21.6-5
ii  libgcc11:8.3.0-6
ii  libqpdf21  8.4.0-2
ii  libstdc++6 8.3.0-6
ii  poppler-utils  0.71.0-5

Versions of packages cups-filters recommends:
ii  colord 1.4.3-4
ii  liblouisutdml-bin  2.7.0-5+b1

Versions of packages cups-filters suggests:
pn  antiword 
pn  docx2txt 
ii  foomatic-db  20181217-2
ii  imagemagick  8:6.9.10.23+dfsg-2.1+deb10u1
ii  imagemagick-6.q16 [imagemagick]  8:6.9.10.23+dfsg-2.1+deb10u1

-- Configuration Files:
/etc/modules-load.d/cups-filters.conf changed:


-- no debconf information