From f519bb994d0a9a4f47018f2f7ab21e4ab56c5b8c1804abc0183a60329a99da3d Mon Sep 17 00:00:00 2001 From: OBS User unknown Date: Mon, 6 Oct 2008 15:51:20 +0000 Subject: [PATCH] OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/git?expand=0&rev=19 --- git-daemon.init | 21 +++++++++++++++++---- git.changes | 5 +++++ git.spec | 5 +++-- 3 files changed, 25 insertions(+), 6 deletions(-) diff --git a/git-daemon.init b/git-daemon.init index 4ea39cc..6add7b6 100644 --- a/git-daemon.init +++ b/git-daemon.init @@ -32,11 +32,24 @@ # Description: server for git repositories ### END INIT INFO -git_daemon=/usr/bin/git-daemon -test -x $git_daemon || { echo "$git_daemon not installed"; +git=/usr/bin/git +test -x $git|| { echo "GIT not installed"; if [ "$1" = "stop" ]; then exit 0; else exit 5; fi; } +if test -x /usr/lib64/git/git-daemon; then + git_daemon=/usr/lib64/git/git-daemon +elif test -x /usr/lib/git/git-daemon; then + git_daemon=/usr/lib/git/git-daemon +else + echo "git-daemon not installed" + if [ "$1" = "stop" ]; then + exit 0 + else + exit 5 + fi +fi + # Check for existence of needed config file and read it git_daemon_config=/etc/sysconfig/git-daemon test -r $git_daemon_config || { echo "$git_daemon_config not existing"; @@ -56,7 +69,7 @@ rc_reset case "$1" in start) echo -n "Starting git-daemon " - /sbin/start_daemon "$git_daemon" \ + /sbin/start_daemon $git daemon \ --syslog \ --detach \ --reuseaddr \ @@ -70,7 +83,7 @@ case "$1" in ;; stop) echo -n "Shutting down git-daemon " - /sbin/killproc -TERM $git_daemon + /sbin/killproc -p /var/run/git-daemon.pid $git_daemon -TERM rc_status -v ;; try-restart|condrestart) diff --git a/git.changes b/git.changes index 1ff05ec..b909118 100644 --- a/git.changes +++ b/git.changes @@ -1,3 +1,8 @@ +------------------------------------------------------------------- +Mon Oct 6 15:53:47 CEST 2008 - tiwai@suse.de + +- fix git-daemon init script to start (bnc#432610) + ------------------------------------------------------------------- Fri Sep 26 17:17:12 CEST 2008 - schwab@suse.de diff --git a/git.spec b/git.spec index c165501..439c16c 100644 --- a/git.spec +++ b/git.spec @@ -20,7 +20,7 @@ Name: git BuildRequires: asciidoc curl-devel fdupes libopenssl-devel sgml-skel xmlto Version: 1.6.0.2 -Release: 2 +Release: 3 Summary: Fast, scalable, distributed revision control system License: GPL v2 or later Group: Development/Tools/Version Control @@ -146,7 +146,6 @@ License: GPL v2 or later Summary: Simple Server for Git Repositories Group: Development/Tools/Version Control Requires: git-core = %{version} -Provides: git-core:/usr/bin/git-daemon PreReq: /usr/sbin/useradd %fillup_prereq %insserv_prereq %description daemon @@ -377,6 +376,8 @@ fi /etc/bash_completion.d/git.sh %changelog +* Mon Oct 06 2008 tiwai@suse.de +- fix git-daemon init script to start (bnc#432610) * Fri Sep 26 2008 schwab@suse.de - Fix manual pages. * Thu Sep 25 2008 tiwai@suse.de