diff options
-rw-r--r-- | package/tvheadend/Makefile | 2 | ||||
-rw-r--r-- | package/tvheadend/files/tvheadend.init | 29 | ||||
-rw-r--r-- | package/tvheadend/files/tvheadend.postinst | 3 |
3 files changed, 33 insertions, 1 deletions
diff --git a/package/tvheadend/Makefile b/package/tvheadend/Makefile index 42816fad8..d3a357755 100644 --- a/package/tvheadend/Makefile +++ b/package/tvheadend/Makefile @@ -5,7 +5,7 @@ include $(ADK_TOPDIR)/rules.mk PKG_NAME:= tvheadend PKG_VERSION:= 679b7797128b8979145dc2a0a3c54ea513a0466b -PKG_RELEASE:= 1 +PKG_RELEASE:= 2 PKG_DESCR:= tv streaming server PKG_SECTION:= mm/video PKG_BUILDDEP:= openssl diff --git a/package/tvheadend/files/tvheadend.init b/package/tvheadend/files/tvheadend.init new file mode 100644 index 000000000..f3e3e396f --- /dev/null +++ b/package/tvheadend/files/tvheadend.init @@ -0,0 +1,29 @@ +#!/bin/sh +#PKG tvheadend +#INIT 90 + +. /etc/rc.conf + +case $1 in +autostop) ;; +autostart) + test x"${tvheadend:-NO}" = x"NO" && exit 0 + test x"$tvheadend" = x"DAEMON" && test -x /bin/mksh && exec mksh -T- $0 start + exec sh $0 start + ;; +start) + tvheadend & + ;; +stop) + kill $(pgrep -f /usr/bin/tvheadend) + ;; +restart) + sh $0 stop + sh $0 start + ;; +*) + echo "Usage: $0 {start | stop | restart}" + exit 1 + ;; +esac +exit $? diff --git a/package/tvheadend/files/tvheadend.postinst b/package/tvheadend/files/tvheadend.postinst new file mode 100644 index 000000000..66d1cdff0 --- /dev/null +++ b/package/tvheadend/files/tvheadend.postinst @@ -0,0 +1,3 @@ +#!/bin/sh +. $IPKG_INSTROOT/etc/functions.sh +add_rcconf tvheadend NO |