From 3c89c295461be17d29d0dd988f3516c6cd4412c6 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Mon, 11 Nov 2013 23:15:49 +0100 Subject: Install debian/$package.socket files, just like .service files MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit They will get enabled when they have an [Install] section. Some special handling for .socket files when upgrading might be necessary at some point in time. We’ll see how it goes. Closes: #718592 --- script/dh_systemd_enable | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'script') diff --git a/script/dh_systemd_enable b/script/dh_systemd_enable index 02dc4ad..ea61301 100755 --- a/script/dh_systemd_enable +++ b/script/dh_systemd_enable @@ -135,6 +135,16 @@ foreach my $package (@{$dh{DOPACKAGES}}) { doit("install","-p","-m644",$service,"$path/$script.service"); } + my $socket=pkgfile($package,"socket"); + if ($socket ne '') { + my $path="$tmpdir/lib/systemd/system"; + if (! -d "$path") { + doit("install","-d","$path"); + } + + doit("install","-p","-m644",$socket,"$path/$script.socket"); + } + my $tmpfile=pkgfile($package,"tmpfile"); if ($tmpfile ne '') { my $path="$tmpdir/usr/lib/tmpfiles.d"; -- cgit v1.2.3