From: Jo-Philipp Wich Date: Sun, 5 Feb 2012 15:05:59 +0000 (+0000) Subject: btpd: merge r29055 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=f83c01c777df27120fc5065238385794489d506e;p=openwrt%2Fsvn-archive%2Fpackages.git btpd: merge r29055 SVN-Revision: 30198 --- diff --git a/net/btpd/Makefile b/net/btpd/Makefile index 14830d65b..b98e1480c 100644 --- a/net/btpd/Makefile +++ b/net/btpd/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=btpd PKG_VERSION:=0.16 -PKG_RELEASE:=1 +PKG_RELEASE:=2 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://github.com/downloads/btpd/btpd diff --git a/net/btpd/files/btpd.init b/net/btpd/files/btpd.init index 8f266c62b..867b5538d 100644 --- a/net/btpd/files/btpd.init +++ b/net/btpd/files/btpd.init @@ -1,5 +1,6 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2006-2010 OpenWrt.org +# Copyright (C) 2006-2011 OpenWrt.org + START=99 append_bool() { @@ -21,10 +22,11 @@ append_parm() { append args "$switch $_loctmp" } -directory="" btpd() { local cfg="$1" + args="" + directory="" append_bool "$cfg" useipv4 "-4" append_bool "$cfg" useipv6 "-6" append_bool "$cfg" emptystart "--empty-start" @@ -38,30 +40,22 @@ btpd() { } start() { - include /lib/network config_load btpd - args="" config_foreach btpd btpd - /usr/bin/btpd $args + + service_start /usr/bin/btpd $args } stop() { - include /lib/network config_load btpd - args="" config_foreach btpd btpd - + [ -d $directory ] && args="-d $directory " - echo -n "stop btpd " - + while btcli $args kill ; do - echo -n . sleep 3 done 2>/dev/null - - killall /usr/bin/btpd > /dev/null 2>&1 - - echo " done" - return 0 + + service_stop /usr/bin/btpd }