Gentoo Archives: gentoo-commits

From: "Diego Petteno (flameeyes)" <flameeyes@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in dev-libs/openct/files: openct.rc.2
Date: Tue, 19 Jun 2012 13:57:13
Message-Id: 20120619135654.79AEB2004C@flycatcher.gentoo.org
flameeyes    12/06/19 13:56:54

  Added:                openct.rc.2
  Log:
  Update init script to use checkpath instead of using keepdir in the ebuild; add an udev USE flag to not install the rules; use EAPI=4; use append-cppflags for -DDEBUG_IFDH.
  
  (Portage version: 2.2.0_alpha110/cvs/Linux x86_64)

Revision  Changes    Path
1.1                  dev-libs/openct/files/openct.rc.2

file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/openct/files/openct.rc.2?rev=1.1&view=markup
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/dev-libs/openct/files/openct.rc.2?rev=1.1&content-type=text/plain

Index: openct.rc.2
===================================================================
#!/sbin/runscript
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/dev-libs/openct/files/openct.rc.2,v 1.1 2012/06/19 13:56:54 flameeyes Exp $

depend() {
	need localmount
}

checkconfig() {
	if [ ! -e /etc/openct.conf ] ; then
		eerror "You need an /etc/openct.conf file to run OpenCT"
		return 1
	fi
	return 0
}

start() {
	checkconfig || return 1

	checkpath -d -m 0750 -o openctd:openct /var/run/openct

	ebegin "Starting OpenCT"
	/usr/sbin/openct-control init
	eend $?
}

stop() {
	ebegin "Stopping OpenCT"
	/usr/sbin/openct-control shutdown
	eend $?
}