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

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



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 <odyx@debian.org>
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


Reply to: