Source: ntpsec Version: 1.2.2+dfsg1-2 Severity: normal Tags: ftbfs patch User: helm...@debian.org Usertags: dep17m2
We want to change the value of systemdsystemunitdir in systemd.pc to point below /usr. ntpsec's upstream build system consumes this variable, but the packaging hard codes the current value. Consequently, ntpsec FTBFS when it changes. Consider applying the attached patch to avoid this failure. Helmut
diff -Nru ntpsec-1.2.2+dfsg1/debian/changelog ntpsec-1.2.2+dfsg1/debian/changelog --- ntpsec-1.2.2+dfsg1/debian/changelog 2023-07-30 21:04:02.000000000 +0200 +++ ntpsec-1.2.2+dfsg1/debian/changelog 2023-09-25 22:51:13.000000000 +0200 @@ -1,3 +1,10 @@ +ntpsec (1.2.2+dfsg1-2.1) UNRELEASED; urgency=medium + + * Non-maintainer upload. + * Fix FTBFS when systemd.pc changes systemdsystemunitdir. (Closes: #-1) + + -- Helmut Grohne <hel...@subdivi.de> Mon, 25 Sep 2023 22:51:13 +0200 + ntpsec (1.2.2+dfsg1-2) unstable; urgency=high * copyright: Update libjsmn comment diff -Nru ntpsec-1.2.2+dfsg1/debian/ntpsec-ntpviz.install ntpsec-1.2.2+dfsg1/debian/ntpsec-ntpviz.install --- ntpsec-1.2.2+dfsg1/debian/ntpsec-ntpviz.install 2023-01-17 00:31:00.000000000 +0100 +++ ntpsec-1.2.2+dfsg1/debian/ntpsec-ntpviz.install 2023-09-25 22:50:52.000000000 +0200 @@ -1,9 +1,9 @@ -debian/tmp/lib/systemd/system/ntplogtemp.service -debian/tmp/lib/systemd/system/ntplogtemp.timer -debian/tmp/lib/systemd/system/ntpviz-daily.service -debian/tmp/lib/systemd/system/ntpviz-daily.timer -debian/tmp/lib/systemd/system/ntpviz-weekly.service -debian/tmp/lib/systemd/system/ntpviz-weekly.timer +debian/tmp/${env:systemdsystemunitdir}/ntplogtemp.service +debian/tmp/${env:systemdsystemunitdir}/ntplogtemp.timer +debian/tmp/${env:systemdsystemunitdir}/ntpviz-daily.service +debian/tmp/${env:systemdsystemunitdir}/ntpviz-daily.timer +debian/tmp/${env:systemdsystemunitdir}/ntpviz-weekly.service +debian/tmp/${env:systemdsystemunitdir}/ntpviz-weekly.timer debian/tmp/usr/bin/ntpviz debian/tmp/usr/sbin/ntploggps debian/tmp/usr/sbin/ntplogtemp diff -Nru ntpsec-1.2.2+dfsg1/debian/ntpsec.install ntpsec-1.2.2+dfsg1/debian/ntpsec.install --- ntpsec-1.2.2+dfsg1/debian/ntpsec.install 2023-01-17 00:31:00.000000000 +0100 +++ ntpsec-1.2.2+dfsg1/debian/ntpsec.install 2023-09-25 22:51:03.000000000 +0200 @@ -1,7 +1,7 @@ debian/ntp-systemd-wrapper usr/libexec/ntpsec debian/rotate-stats usr/libexec/ntpsec -debian/tmp/lib/systemd/system/ntpsec-wait.service -debian/tmp/lib/systemd/system/ntpsec.service +debian/tmp/${env:systemdsystemunitdir}/ntpsec-wait.service +debian/tmp/${env:systemdsystemunitdir}/ntpsec.service debian/tmp/usr/bin/ntpleapfetch usr/sbin debian/tmp/usr/bin/ntpmon debian/tmp/usr/bin/ntpq diff -Nru ntpsec-1.2.2+dfsg1/debian/rules ntpsec-1.2.2+dfsg1/debian/rules --- ntpsec-1.2.2+dfsg1/debian/rules 2023-01-17 00:31:00.000000000 +0100 +++ ntpsec-1.2.2+dfsg1/debian/rules 2023-09-25 22:50:13.000000000 +0200 @@ -6,6 +6,7 @@ export DEB_BUILD_MAINT_OPTIONS = hardening=+bindnow,+pie export DEB_CFLAGS_MAINT_APPEND = -fno-strict-aliasing +export systemdsystemunitdir = $(shell pkg-config --variable=systemdsystemunitdir systemd) %: dh $@ --with apache2,python3 @@ -78,11 +79,11 @@ override_dh_install: python3 waf install --destdir=$(CURDIR)/debian/tmp mv \ - debian/tmp/lib/systemd/system/ntpd.service \ - debian/tmp/lib/systemd/system/ntpsec.service + debian/tmp/$(systemdsystemunitdir)/ntpd.service \ + debian/tmp/$(systemdsystemunitdir)/ntpsec.service mv \ - debian/tmp/lib/systemd/system/ntp-wait.service \ - debian/tmp/lib/systemd/system/ntpsec-wait.service + debian/tmp/$(systemdsystemunitdir)/ntp-wait.service \ + debian/tmp/$(systemdsystemunitdir)/ntpsec-wait.service rm -rf debian/tmp/usr/lib/python3/dist-packages/ntp/__pycache__ # ntpfrob probes internal, mostly undocumented settings. It is # extremely unlikely that anyone needs this. @@ -129,19 +130,19 @@ debian/ntpsec.certbot \ debian/ntpsec/etc/letsencrypt/renewal-hooks/deploy/ntpsec - install -d debian/ntpsec/lib/systemd/system + install -d debian/ntpsec/$(systemdsystemunitdir) install -m 644 \ debian/ntpsec.ntpsec-rotate-stats.service \ - debian/ntpsec/lib/systemd/system/ntpsec-rotate-stats.service + debian/ntpsec/$(systemdsystemunitdir)/ntpsec-rotate-stats.service install -m 644 \ debian/ntpsec.ntpsec-rotate-stats.timer \ - debian/ntpsec/lib/systemd/system/ntpsec-rotate-stats.timer + debian/ntpsec/$(systemdsystemunitdir)/ntpsec-rotate-stats.timer - install -d debian/ntpsec-ntpviz/lib/systemd/system + install -d debian/ntpsec-ntpviz/$(systemdsystemunitdir) install -m 644 \ etc/ntploggps.service \ etc/ntploggps.timer \ - debian/ntpsec-ntpviz/lib/systemd/system/ + debian/ntpsec-ntpviz/$(systemdsystemunitdir) install -d debian/ntpsec-ntpviz/etc/ntpviz/day install -m 644 www/day/footer \ @@ -175,9 +176,9 @@ install -D -m 0755 debian/ntpsec-ntpdate.networkmanager \ debian/ntpsec-ntpdate/etc/NetworkManager/dispatcher.d/ntpsec-ntpdate install -D -m 0644 debian/ntpsec-systemd-netif.path \ - debian/ntpsec/lib/systemd/system/ntpsec-systemd-netif.path + debian/ntpsec/$(systemdsystemunitdir)/ntpsec-systemd-netif.path install -D -m 0644 debian/ntpsec-systemd-netif.service \ - debian/ntpsec/lib/systemd/system/ntpsec-systemd-netif.service + debian/ntpsec/$(systemdsystemunitdir)/ntpsec-systemd-netif.service ifeq (yes,$(shell dpkg-vendor --derives-from Ubuntu && echo yes)) install -D -m 0644 debian/ntp.conf.ubuntu debian/ntpsec/etc/ntpsec/ntp.conf