packages/privoxy: use new service functions
authorNicolas Thill <nico@openwrt.org>
Tue, 15 Nov 2011 03:40:56 +0000 (03:40 +0000)
committerNicolas Thill <nico@openwrt.org>
Tue, 15 Nov 2011 03:40:56 +0000 (03:40 +0000)
Signed-off-by: Peter Wagner <tripolar@gmx.at>
SVN-Revision: 29151

net/privoxy/Makefile
net/privoxy/files/privoxy.init

index 2cc6bff646f499a8320fd7bcb3834e9e6f6cbf58..a70deaca81bc89f3552acc042f6d8b30bb638cce 100644 (file)
@@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk
 
 PKG_NAME:=privoxy
 PKG_VERSION:=3.0.17
-PKG_RELEASE:=2
+PKG_RELEASE:=3
 
 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION)-stable-src.tar.gz
 PKG_SOURCE_URL:=@SF/ijbswa
index 85479b33829e088df346b72adce3d7c4b46da76e..0afe4c49025518d4ef54b93c90a2713c1bb58e4b 100644 (file)
@@ -1,16 +1,16 @@
 #!/bin/sh /etc/rc.common
-# Copyright (C) 2006 OpenWrt.org
+# Copyright (C) 2006-2011 OpenWrt.org
+
 START=50
+STOP=50
 
-CFG_F=/etc/privoxy/config
-RUN_D=/var/run
-PID_F=$RUN_D/privoxy.pid
+SERVICE_USE_PID=1
 
 start() {
-       mkdir -p $RUN_D
-       /usr/sbin/privoxy --pidfile $PID_F $CFG_F
+       service_start /usr/sbin/privoxy --pidfile /var/run/privoxy.pid \
+                                       /etc/privoxy/config
 }
 
 stop() {
-       [ -f $PID_F ] && kill $(cat $PID_F)
+       service_stop /usr/sbin/privoxy
 }