Source: autorandr
Version: 1.12.1-1.1
Severity: normal
Tags: patch
User: helm...@debian.org
Usertags: dep17m2

We want to change dh_installsystemd such that it installs units below
/usr in order to finalize the /usr-merge transition via DEP17. When
doing so, autorandr happes to install the upstream unit (via
dh_auto_install) below /lib and debian/autorand.service (via
dh_installsystemd) below /usr/lib. Doing so is a policy violation and
this bug will become release critical once I upload debhelper. I'm
attaching a patch that disables the installation of the upstream unit.
Once you go back to the upstream unit, please leave SYSTEMD_UNIT_DIR
unset, because it'll then pick up the right value from pkgconfig and
dh_installsystemd now supports generating maintainer scripts from both
locations.

Helmut
diff -Nru autorandr-1.12.1/debian/changelog autorandr-1.12.1/debian/changelog
--- autorandr-1.12.1/debian/changelog   2022-10-15 11:53:17.000000000 +0200
+++ autorandr-1.12.1/debian/changelog   2023-10-24 09:56:57.000000000 +0200
@@ -1,3 +1,10 @@
+autorandr (1.12.1-1.2) UNRELEASED; urgency=medium
+
+  * Non-maintainer upload.
+  * Install systemd unit only once. (Closes: #-1)
+
+ -- Helmut Grohne <hel...@subdivi.de>  Tue, 24 Oct 2023 09:56:57 +0200
+
 autorandr (1.12.1-1.1) unstable; urgency=medium
 
   * Non-maintainer upload.
diff -Nru autorandr-1.12.1/debian/rules autorandr-1.12.1/debian/rules
--- autorandr-1.12.1/debian/rules       2020-04-26 01:40:31.000000000 +0200
+++ autorandr-1.12.1/debian/rules       2023-10-24 09:56:57.000000000 +0200
@@ -5,13 +5,13 @@
 
 override_dh_auto_build:
        dh_auto_build -- UDEV_RULES_DIR=/lib/udev/rules.d \
-               SYSTEMD_UNIT_DIR=/lib/systemd/system \
+               SYSTEMD_UNIT_DIR= \
                BASH_COMPLETIONS_DIR=/usr/share/bash-completion/completions \
                PM_SLEEPHOOKS_DIR=/etc/pm/sleep.d/
 
 override_dh_auto_install:
        dh_auto_install -- UDEV_RULES_DIR=/lib/udev/rules.d \
-               SYSTEMD_UNIT_DIR=/lib/systemd/system \
+               SYSTEMD_UNIT_DIR= \
                BASH_COMPLETIONS_DIR=/usr/share/bash-completion/completions \
                PM_SLEEPHOOKS_DIR=/etc/pm/sleep.d/
        install -D -m 755 contrib/pm-utils/40autorandr 
debian/autorandr/etc/pm/sleep.d/40autorandr

Reply via email to