Bug#1063693: xdm: move systemd unit to /usr (DEP17)
Source: xdm
Version: 1:1.1.11-3
Tags: patch trixie sid
User: helmutg@debian.org
Usertags: dep17m2
Hi,
we want to finalize the /usr-merge transition by moving all aliased
files from / to /usr via DEP17 to avoid any negative effects arising
from aliasing. xdm is involved, because it installs a systemd unit. The
systemd.pc file contains a variable systemdsystemunit dir that points to
the right location in different Debian releases and xdm's upstream build
system can automatically use this information. I'm attaching a patch for
xdm that moves the unit in trixie or later, but also is safe for
backporting.
Helmut
diff -u xdm-1.1.11/debian/changelog xdm-1.1.11/debian/changelog
--- xdm-1.1.11/debian/changelog
+++ xdm-1.1.11/debian/changelog
@@ -1,3 +1,10 @@
+xdm (1:1.1.11-3.1) UNRELEASED; urgency=medium
+
+ * Non-maintainer upload.
+ * Let systemd.pc determine the location of systemd units. (Closes: #-1)
+
+ -- Helmut Grohne <helmut@subdivi.de> Sat, 10 Feb 2024 09:00:06 +0100
+
xdm (1:1.1.11-3) unstable; urgency=medium
* Team upload.
diff -u xdm-1.1.11/debian/control xdm-1.1.11/debian/control
--- xdm-1.1.11/debian/control
+++ xdm-1.1.11/debian/control
@@ -5,8 +5,9 @@
Uploaders: Cyril Brulebois <kibi@debian.org>
Build-Depends:
debhelper (>= 9),
+ dh-exec,
dpkg-dev (>= 1.16.1),
- pkg-config,
+ pkgconf,
libxmu-dev (>= 1:1.0.1),
libx11-dev (>= 2:1.0.0),
libxau-dev (>= 1:1.0.0),
@@ -18,6 +19,7 @@
quilt,
automake,
libtool,
+ systemd-dev,
xutils-dev,
Standards-Version: 3.9.6
Vcs-Git: git://anonscm.debian.org/pkg-xorg/app/xdm
diff -u xdm-1.1.11/debian/rules xdm-1.1.11/debian/rules
--- xdm-1.1.11/debian/rules
+++ xdm-1.1.11/debian/rules
@@ -13,6 +13,8 @@
include debian/xsfbs/xsfbs.mk
+export deb_systemdsystemunitdir := $(shell pkgconf --variable=systemdsystemunitdir systemd | sed s,^/,,)
+
confflags += \
--prefix=/usr \
--mandir=\$${prefix}/share/man \
@@ -24,7 +26,7 @@
--with-pixmapdir=/usr/share/X11/xdm/pixmaps \
--with-color-pixmap=debian.xpm \
--with-bw-pixmap=debianbw.xpm \
- --with-systemdsystemunitdir=/lib/systemd/system \
+ --with-systemdsystemunitdir \
--disable-xdm-auth \
--with-xft \
--disable-silent-rules \
@@ -126,6 +128,7 @@
dh_testroot
dh_installdocs
+ chmod +x debian/xdm.install
dh_install --sourcedir=debian/tmp --list-missing
dh_installchangelogs ChangeLog
dh_installinit --noscripts
diff -u xdm-1.1.11/debian/xdm.install xdm-1.1.11/debian/xdm.install
--- xdm-1.1.11/debian/xdm.install
+++ xdm-1.1.11/debian/xdm.install
@@ -1,3 +1,4 @@
+#!/usr/bin/dh-exec
etc/X11/app-defaults/Chooser
etc/X11/xdm/Xaccess
etc/X11/xdm/Xreset
@@ -10,7 +11,7 @@
etc/X11/xdm/xdm-config
etc/X11/xdm/xdm.options
etc/insserv.conf.d/xdm
-lib/systemd/system/xdm.service
+${deb_systemdsystemunitdir}/xdm.service
usr/bin/xdm
usr/lib/X11/xdm/chooser
usr/lib/X11/xdm/libXdmGreet.so
Reply to: