Package: bird
Version: 1.4.5-1+deb8u1
Severity: important
Tags: patch

Dear Maintainer,

bird currently ships its own native systemd unit files, but does not 
take care of enabling the units. On systems with systemd, this means 
that BIRD will not start automatically on boot unless manually enabled, 
although it will be started by dh_installinit during installation. This 
is visible in the output of systemctl:

 $ systemctl status bird
 ● bird.service - BIRD Internet Routing Daemon (IPv4)
    Loaded: loaded (/lib/systemd/system/bird.service; disabled)

Note that the unit is loaded (running) but `disabled`, i.e. will not 
start automatically. This is in contrast with the behaviour on sysvinit 
systems, where bird is started on boot by default.

Please fix this (preferrably even in Jessie) using dh-systemd, as is 
does the attached patch.

Regards,
Apollon

-- System Information:
Debian Release: stretch/sid
  APT prefers testing
  APT policy: (500, 'testing'), (500, 'stable'), (90, 'unstable'), (1, 
'experimental')
Architecture: amd64 (x86_64)
Foreign Architectures: i386, mips

Kernel: Linux 3.16.0-4-amd64 (SMP w/4 CPU cores)
Locale: LANG=el_GR.UTF-8, LC_CTYPE=el_GR.UTF-8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
>From 0fd4e221fb0d7dc09fe26b570c350dd72770ca4f Mon Sep 17 00:00:00 2001
From: Apollon Oikonomopoulos <apoi...@debian.org>
Date: Wed, 21 Oct 2015 15:49:12 +0300
Subject: [PATCH] Use dh-systemd

BIRD ships systemd unit files, but currently does not use dh-systemd to
make sure the units are properly enabled. Fix this by B-D'ing on
dh-systemd and using it during build.
---
 debian/control | 1 +
 debian/rules   | 6 +++++-
 2 files changed, 6 insertions(+), 1 deletion(-)

diff --git a/debian/control b/debian/control
index 4bbcb17..f4fa26d 100644
--- a/debian/control
+++ b/debian/control
@@ -4,6 +4,7 @@ Priority: extra
 Build-Depends: autotools-dev,
                bison,
                debhelper (>= 9~),
+               dh-systemd (>= 1.5),
                docbook-xsl,
                dpkg-dev (>= 1.16.1.1~),
                flex,
diff --git a/debian/rules b/debian/rules
index 9531bd5..352c3c2 100755
--- a/debian/rules
+++ b/debian/rules
@@ -17,7 +17,7 @@ CFLAGS += -g -O2 -fno-strict-aliasing -fno-strict-overflow -fPIC
 LDFLAGS += -g -O2 -fno-strict-aliasing -fno-strict-overflow -fPIC -Wl,-z,defs -Wl,--as-needed
 
 %:
-	dh $@ --with autotools_dev
+	dh $@ --with autotools_dev,systemd
 
 override_dh_auto_configure:
 	CFLAGS="$(CFLAGS)" LDFLAGS="$(LDFLAGS)" dh_auto_configure -Bbuild-ipv4 -- $(COMMON_FLAGS) --disable-ipv6 --with-protocols=all
@@ -70,3 +70,7 @@ override_dh_installman: bird.8
 override_dh_clean:
 	dh_clean
 	-rm -f bird.8 birdc.8 bird6.8 birdc6.8
+
+override_dh_systemd_enable:
+	dh_systemd_enable --name=bird
+	dh_systemd_enable --name=bird6
-- 
2.6.1

Reply via email to