From 1d33eef34159fefbafbade2c09ead1c5c23ff32c Mon Sep 17 00:00:00 2001 Message-Id: <1d33eef34159fefbafbade2c09ead1c5c23ff32c.1730415262.git.mdw@distorted.org.uk> From: Mark Wooding Date: Sun, 9 Apr 2017 23:43:56 +0100 Subject: [PATCH] packaging fixes Organization: Straylight/Edgeware From: Ian Jackson Signed-off-by: Ian Jackson --- debian/hippotat.hippotatd.init | 8 ++++---- debian/rules | 7 +++++++ hippotat | 2 +- hippotatd | 3 +-- 4 files changed, 13 insertions(+), 7 deletions(-) diff --git a/debian/hippotat.hippotatd.init b/debian/hippotat.hippotatd.init index ac91e3a..fbee31f 100644 --- a/debian/hippotat.hippotatd.init +++ b/debian/hippotat.hippotatd.init @@ -10,7 +10,7 @@ # Description: Asinine IP over HTTP server ### END INIT INFO -DAEMON=/usr/sbin/hippotat +DAEMON=/usr/sbin/hippotatd MASTER_CONFIG=/etc/hippotat/master.cfg USER=Debian-hippotat PIDFILE=/var/run/hippotat/hippotatd.pid @@ -40,7 +40,7 @@ as_user_userv () { ssd () { set +e - start-stop-daemon --start --quiet --user $USER --pidfile=$PIDFILE "$@" + start-stop-daemon --quiet --user $USER --pidfile=$PIDFILE "$@" rc=$? set -e } @@ -71,12 +71,12 @@ check_firewall () { do_start () { check_firewall ensure_dirs - ssd --chuid $USER --startas \ + ssd --chuid $USER --start --startas \ $AUTHBIND $DAEMON --daemon --pidfile=$PIDFILE \ --syslog-facility=$LOGFACILITY $HIPPOTATD_ARGS } do_stop () { - ssd --stop --retry 5 + ssd --stop --oknodo --retry 5 } case "$1" in diff --git a/debian/rules b/debian/rules index 375d057..945367f 100755 --- a/debian/rules +++ b/debian/rules @@ -12,6 +12,13 @@ i=debian/hippotat debian/copyright: COPYING AGPLv3+CAFv2 cat $^ >$@.tmp && mv -f $@.tmp $@ +override_dh_python3: + dh_python3 -O--buildsystem=pybuild + dh_installdirs /usr/sbin + mv $i/usr/{bin,sbin}/hippotatd + +#install -m755 -o0 -g0 -d $i//usr/sbin + override_dh_installinit: dh_installinit --name=hippotatd diff --git a/hippotat b/hippotat index 43faf28..96a3f21 100755 --- a/hippotat +++ b/hippotat @@ -21,7 +21,7 @@ # along with this program, in the file GPLv3. If not, # see . -#@ sys.path.append('@PYBUILD_INSTALL_DIR@') +#@ import sys; sys.path.append('@PYBUILD_INSTALL_DIR@') from hippotatlib import * import twisted.web diff --git a/hippotatd b/hippotatd index 1865dad..bc55650 100755 --- a/hippotatd +++ b/hippotatd @@ -25,7 +25,7 @@ # the file AGPLv3+CAFv2. If not, email Ian Jackson # . -#@ sys.path.append(@PYBUILD_INSTALL_DIR@) +#@ import sys; sys.path.append('@PYBUILD_INSTALL_DIR@') from hippotatlib import * import os @@ -38,7 +38,6 @@ import twisted.internet from twisted.web.server import NOT_DONE_YET import twisted.web.static -import twisted.python.syslog import hippotatlib.ownsource from hippotatlib.ownsource import SourceShipmentPreparer -- [mdw]