[oe-core][PATCH] cups: use xdg-open for the CUPS web interface desktop entry

From: Markus Volk <hidden>
Date: 2026-09-10 19:34:26
Subsystem: the rest · Maintainer: Linus Torvalds

The configure check for xdg-open is an AC_PATH_PROG, so in a cross build it
inspects the build host instead of the target. xdg-open is not part of the
native sysroot, so CUPS_HTMLVIEW falls back to "htmlview" and the installed
cups.desktop ends up with "Exec=htmlview http://localhost:631/". No recipe
provides that Fedora specific wrapper, so the "Manage Printing" entry is dead
on every image.

Set the autoconf cache variable to the target path instead, so the desktop
entry uses xdg-open as provided by xdg-utils.

Tested by building cups for a corei7-64 image and checking that
/usr/share/applications/cups.desktop now reads
"Exec=/usr/bin/xdg-open http://localhost:631/".

AI-Generated: Uses Claude Code (Claude Opus 5)
Signed-off-by: Markus Volk <redacted>
---
 meta/recipes-extended/cups/cups.inc | 2 ++
 1 file changed, 2 insertions(+)
diff --git a/meta/recipes-extended/cups/cups.inc b/meta/recipes-extended/cups/cups.inc
index 2724ce72fb..f82fc0a1aa 100644
--- a/meta/recipes-extended/cups/cups.inc
+++ b/meta/recipes-extended/cups/cups.inc
@@ -48,6 +48,8 @@ PACKAGECONFIG[systemd] = "--with-systemd=${systemd_system_unitdir},--without-sys
 PACKAGECONFIG[xinetd] = "--with-xinetd=${sysconfdir}/xinetd.d,--without-xinetd,xinetd"
 PACKAGECONFIG[webif] = "--enable-webif,--disable-webif"
 
+CACHED_CONFIGUREVARS += "ac_cv_path_XDGOPEN=${bindir}/xdg-open"
+
 EXTRA_OECONF = " \
                --enable-dbus \
                --with-dbusdir=${sysconfdir}/dbus-1 \
-- 
2.55.0

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help