]> git.etc.gen.nz Git - mythtv-status.git/commitdiff
Potentially install our molly-guard and update-motd hooks.
authorAndrew Ruthven <andrew@etc.gen.nz>
Wed, 26 Jul 2023 12:35:40 +0000 (00:35 +1200)
committerAndrew Ruthven <andrew@etc.gen.nz>
Wed, 26 Jul 2023 12:58:08 +0000 (00:58 +1200)
ChangeLog
Makefile
debian/dirs
debian/install
debian/patches/makefile-debian-paths.patch

index 1dd53de70f53f126ce1ce0ffdf8efea64373c338..6445effa889740dd0f05eed79cc965c2e6c7b9d4 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -2,6 +2,9 @@
   Install the systemd files into the UsrMerge location so we'll work with
   more distributions, thanks to Göran Uddeborgfor pointing this out.
 
+  If molly-guard or the Ubuntu/Debian style update-motd is present, install
+  our hooks for those.
+
 2023-07-27  Göran Uddebor
   Install update-update-motd
 
index 463f1a74d1969604a3cddfb5ee95db4de49ba036..d76c7224c9404878585b8d9efee05a331611b512 100755 (executable)
--- a/Makefile
+++ b/Makefile
@@ -1,10 +1,12 @@
 #!/usr/bin/make -f
 
 BINDIR=$(DESTDIR)/usr/bin
-SBINDIR=$(DESTDIR)/usr/sbin
 LIBEXECDIR=$(DESTDIR)/usr/libexec/mythtv-status
 MANDIR=$(DESTDIR)/usr/man
+MOLLY_GUARDDIR=$(DESTDIR)/etc/molly-guard/run.d
+SBINDIR=$(DESTDIR)/usr/sbin
 SYSTEMDDIR=$(DESTDIR)/usr/lib/systemd/system
+UPDATE_MOTDDIR=$(DESTDIR)/etc/update-motd.d
 
 package=mythtv-status
 releases=sid
@@ -88,6 +90,12 @@ install:
        install -m 644 man/mythtv_recording_soon.1 $(MANDIR)/man1
        install -m 644 systemd/* $(SYSTEMDDIR)
 
+        # Only install these files if the directories already exist.
+       [ -d $(MOLLY_GUARDDIR) ] && \
+           install -m 775 molly-guard/* $(MOLLY_GUARDDIR)
+       [ -d $(UPDATE_MOTDDIR) ] && \
+           install -m 775 update-motd.d/* $(UPDATE_MOTDDIR)
+
 test:
        PERL_DL_NONLAZY=1 perl "-MExtUtils::Command::MM" "-e" "test_harness($(TEST_VERBOSE))" $(TEST_FILES)
 
index 6892884396811aa42b8ee5c768dddb7a912e6cd3..ef744ddc440e9c522e02b1fd6966c0afb686acfa 100644 (file)
@@ -1 +1,3 @@
 var/lib/mythtv-status
+etc/molly-guard/run.d
+etc/update-motd.d
index abf89cfea7fad09764ee2df74818f673caffd3d2..1d53121da22ba995e2315114d31548c8293e5855 100644 (file)
@@ -1,3 +1 @@
 debian/lintian/overrides/mythtv-status usr/share/lintian/overrides
-molly-guard/40-mythtv-recording-soon etc/molly-guard/run.d
-update-motd.d/50-mythtv-status etc/update-motd.d
index 2f5d2bfe8b84fa811df07b3a636eceb4e72fc85e..e34ce02246122d14630f182f8fad689805b242cd 100644 (file)
@@ -6,14 +6,16 @@ Last-Update: 2023-07-16
 This patch header follows DEP-3: http://dep.debian.net/deps/dep3/
 --- a/Makefile
 +++ b/Makefile
-@@ -3,8 +3,8 @@
+@@ -2,10 +2,10 @@
  BINDIR=$(DESTDIR)/usr/bin
- SBINDIR=$(DESTDIR)/usr/sbin
  LIBEXECDIR=$(DESTDIR)/usr/libexec/mythtv-status
 -MANDIR=$(DESTDIR)/usr/man
--SYSTEMDDIR=$(DESTDIR)/usr/lib/systemd/system
 +MANDIR=$(DESTDIR)/usr/share/man
+ MOLLY_GUARDDIR=$(DESTDIR)/etc/molly-guard/run.d
+ SBINDIR=$(DESTDIR)/usr/sbin
+-SYSTEMDDIR=$(DESTDIR)/usr/lib/systemd/system
 +SYSTEMDDIR=$(DESTDIR)/lib/systemd/system
+ UPDATE_MOTDDIR=$(DESTDIR)/etc/update-motd.d
  
  package=mythtv-status
- releases=sid