From 4ebcb288b9558817edc3f33b545ad32f584b2f6d Mon Sep 17 00:00:00 2001 From: jow Date: Sun, 5 Feb 2012 16:15:21 +0000 Subject: [PATCH] [packages_10.03.2] subversion: merge r28765, r29067 git-svn-id: svn://svn.openwrt.org/openwrt/branches/packages_10.03.2@30266 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- net/subversion/Makefile | 2 +- net/subversion/files/subversion.init | 22 ++++++++++++---------- 2 files changed, 13 insertions(+), 11 deletions(-) diff --git a/net/subversion/Makefile b/net/subversion/Makefile index 690f10d..c458b9c 100644 --- a/net/subversion/Makefile +++ b/net/subversion/Makefile @@ -9,7 +9,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=subversion PKG_VERSION:=1.6.17 -PKG_RELEASE:=2 +PKG_RELEASE:=3 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.bz2 PKG_SOURCE_URL:=http://subversion.tigris.org/downloads diff --git a/net/subversion/files/subversion.init b/net/subversion/files/subversion.init index 6b24f58..c2bcc07 100644 --- a/net/subversion/files/subversion.init +++ b/net/subversion/files/subversion.init @@ -1,11 +1,12 @@ #!/bin/sh /etc/rc.common -# Copyright (C) 2006 OpenWrt.org +# Copyright (C) 2006-2011 OpenWrt.org + START=50 -start_service () { +start_instance () { local section="$1" - config_get path "$section" path - config_get port "$section" port + config_get path "$section" 'path' + config_get port "$section" 'port' if [ ! -d "$path" ]; then echo "The subversion repository (${path}) does not exist." @@ -16,20 +17,21 @@ start_service () { echo " svnadmin create --fs-type fsfs /srv/svn" echo echo "Changing the path using UCI (default path is: /var/local/svn):" - echo " uci set subversion.cfg1.path="/srv/svn"" + echo " uci set subversion.@[0].path="/srv/svn"" echo " uci commit" echo " /etc/init.d/subversion restart" - exit 1 + return 1 fi - svnserve -d --listen-port ${port} -r ${path} + service_start /usr/bin/svnserve -d --listen-port ${port} -r ${path} } start() { - config_load "subversion" - config_foreach start_service subversion + config_load 'subversion' + config_foreach start_instance 'subversion' } stop() { - killall -9 svnserve + SERVICE_SIG_STOP="INT" \ + service_stop /usr/bin/svnserve } -- 2.11.0