metalog version bump, also install initscript

This commit is contained in:
Daniel Mierswa 2009-08-31 05:41:00 +02:00
parent c5bb06c9aa
commit a52359eaa0
4 changed files with 71 additions and 1 deletions

View file

@ -0,0 +1,19 @@
# /etc/conf.d/metalog
# $Header: /var/www/viewcvs.gentoo.org/raw_cvs/gentoo-x86/app-admin/metalog/files/metalog.confd,v 1.7 2006/02/08 01:04:02 vapier Exp $
# Some useful options:
# -a Log with buffering
# -s Log without buffering
# See `metalog --help` for more
METALOG_OPTS=""
# Options used by /usr/sbin/consolelog.sh
# Space delimited list of devices to write "console" messages to
#CONSOLE="/dev/console /dev/tty10"
CONSOLE="/dev/tty10"
# Format of logging (make sure you use single quotes)
FORMAT='$1 [$2] $3'

View file

@ -0,0 +1,44 @@
#!/sbin/runscript
# Copyright 1999-2008 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/www/viewcvs.gentoo.org/raw_cvs/gentoo-x86/app-admin/metalog/files/metalog.initd,v 1.4 2009/01/02 07:56:34 vapier Exp $
opts="buffer unbuffer"
PIDFILE=/var/run/metalog.pid
depend() {
need localmount
use clock hostname
after bootmisc
provide logger
}
start() {
ebegin "Starting metalog"
start-stop-daemon --start --exec /usr/sbin/metalog \
--pidfile "${PIDFILE}" \
-- --daemonize --pidfile="${PIDFILE}" ${METALOG_OPTS}
eend $?
}
stop() {
ebegin "Stopping metalog"
start-stop-daemon --stop --exec /usr/sbin/metalog \
--pidfile "${PIDFILE}"
eend $?
}
buffer() {
ebegin "Enabling log buffering"
start-stop-daemon --stop --oknodo --signal USR2 \
--exec /usr/sbin/metalog --pidfile "${PIDFILE}"
eend $?
}
unbuffer() {
ebegin "Disabling log buffering"
start-stop-daemon --stop --oknodo --signal USR1 \
--exec /usr/sbin/metalog --pidfile "${PIDFILE}"
eend $?
}

View file

@ -4,5 +4,5 @@
require metalog
SLOT="0"
PLATFORMS="~amd64"
PLATFORMS="~amd64 ~x86"

View file

@ -24,3 +24,10 @@ REMOTE_IDS="freshmeat:${PN} sourceforge:${PN}"
UPSTREAM_DOCUMENTATION="${HOMEPAGE}/README"
src_install() {
default
newinitd "${FILES}/metalog.initd" metalog
newconfd "${FILES}/metalog.confd" metalog
}