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

[lintian] 01/01: checks/systemd.{desc, pm}: mark service files in /usr/lib as invalid



This is an automated email from the git hooks/post-receive script.

nthykier pushed a commit to branch master
in repository lintian.

commit 97f988d2fde7fd1fb4e60e52512fc80c11a8bbea
Author: Felipe Sateler <fsateler@debian.org>
Date:   Sat Jun 13 11:37:31 2015 -0300

    checks/systemd.{desc,pm}: mark service files in /usr/lib as invalid
    
    Systemd in debian will not look at /usr/lib/service
    
    Signed-off-by: Niels Thykier <niels@thykier.net>
---
 checks/systemd.desc                           | 4 ++++
 checks/systemd.pm                             | 3 +++
 debian/changelog                              | 3 +++
 t/tests/systemd-general/debian/debian/install | 1 +
 t/tests/systemd-general/tags                  | 2 ++
 5 files changed, 13 insertions(+)

diff --git a/checks/systemd.desc b/checks/systemd.desc
index ed1b777..d8a2e55 100644
--- a/checks/systemd.desc
+++ b/checks/systemd.desc
@@ -10,6 +10,10 @@ Certainty: certain
 Info: The package ships a systemd service file outside
  <tt>/lib/systemd/system/</tt>
  .
+ Systemd in Debian searches for unit files in <tt>/lib/systemd/system/</tt>
+ and <tt>/etc/systemd/system</tt>.  Notable, it does <i>not</i> look
+ in <tt>/usr/lib/systemd/system/</tt> for service files.
+ .
  System administrators should have the possibility to overwrite a
  service file (or parts of it, in newer systemd versions) by placing a
  file in <tt>/etc/systemd/system</tt>, so the canonical location used
diff --git a/checks/systemd.pm b/checks/systemd.pm
index 05cb8d1..b79c7ac 100644
--- a/checks/systemd.pm
+++ b/checks/systemd.pm
@@ -55,6 +55,9 @@ sub run {
         if ($file =~ m,^etc/systemd/system/.*\.service$,) {
             tag 'systemd-service-file-outside-lib', $file;
         }
+        if ($file =~ m,^usr/lib/systemd/system/.*\.service$,) {
+            tag 'systemd-service-file-outside-lib', $file;
+        }
         if ($file =~ m,/systemd/system/.*\.service$,) {
             check_systemd_service_file($info, $file);
             for my $name (extract_service_file_names($info, $file)) {
diff --git a/debian/changelog b/debian/changelog
index 133000a..01a5352 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -54,6 +54,9 @@ lintian (2.5.32) UNRELEASED; urgency=medium
       different "public-domain licenses", as they are expected to
       describe why the affected files are in public domain.
       (Closes: #787248)
+  * checks/systemd.{desc,pm}:
+    + [NT] Apply patch from Felipe Sateler to mark service files in
+      /usr/lib as invalid.  (Closes: #788629)
 
   * collection/{debfiles,doc-base-files,init.d,menu-files}{,.desc}:
     + [NT] Remove deprecated and unused collections.  These were
diff --git a/t/tests/systemd-general/debian/debian/install b/t/tests/systemd-general/debian/debian/install
index 363d12a..56cf085 100644
--- a/t/tests/systemd-general/debian/debian/install
+++ b/t/tests/systemd-general/debian/debian/install
@@ -1,2 +1,3 @@
 debian/test.service etc/systemd/system/
+debian/test.service usr/lib/systemd/system/
 debian/test.conf etc/tmpfiles.d/
diff --git a/t/tests/systemd-general/tags b/t/tests/systemd-general/tags
index ad662b4..7a2767c 100644
--- a/t/tests/systemd-general/tags
+++ b/t/tests/systemd-general/tags
@@ -6,8 +6,10 @@ E: systemd-general: special-file etc/systemd/system/fifo-pipe-as-init.service 06
 E: systemd-general: systemd-no-service-for-init-script systemd-general
 E: systemd-general: systemd-service-file-outside-lib etc/systemd/system/fifo-pipe-as-init.service
 E: systemd-general: systemd-service-file-outside-lib etc/systemd/system/test.service
+E: systemd-general: systemd-service-file-outside-lib usr/lib/systemd/system/test.service
 E: systemd-general: systemd-tmpfiles.d-outside-usr-lib etc/tmpfiles.d/test.conf
 W: systemd-general: init.d-script-does-not-source-init-functions etc/init.d/systemd-general
 W: systemd-general: maintainer-script-calls-systemctl postrm:6
 W: systemd-general: script-in-etc-init.d-not-registered-via-update-rc.d etc/init.d/fifo-pipe-as-init
 W: systemd-general: systemd-service-file-refers-to-obsolete-target etc/systemd/system/test.service syslog.target
+W: systemd-general: systemd-service-file-refers-to-obsolete-target usr/lib/systemd/system/test.service syslog.target

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/lintian/lintian.git


Reply to: