summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'app-admin')
-rw-r--r--app-admin/metalog/files/metalog.confd4
-rw-r--r--app-admin/metalog/files/metalog.rc629
-rw-r--r--app-admin/metalog/metalog-0.6-r8.ebuild23
3 files changed, 22 insertions, 34 deletions
diff --git a/app-admin/metalog/files/metalog.confd b/app-admin/metalog/files/metalog.confd
new file mode 100644
index 000000000000..14b0fe61424e
--- /dev/null
+++ b/app-admin/metalog/files/metalog.confd
@@ -0,0 +1,4 @@
+# Config file for /etc/init.d/metalog
+
+# Add '-s' if you dont want buffering. (See things realtime)
+METALOG_OPTS="-B"
diff --git a/app-admin/metalog/files/metalog.rc6 b/app-admin/metalog/files/metalog.rc6
index 9fa030dd6620..48fd89919f02 100644
--- a/app-admin/metalog/files/metalog.rc6
+++ b/app-admin/metalog/files/metalog.rc6
@@ -1,32 +1,21 @@
#!/sbin/runscript
# Copyright 1999-2002 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
-# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/files/metalog.rc6,v 1.4 2002/01/26 15:22:56 aeoo Exp $
-
-METALOG_PID="/var/run/metalog.pid"
+# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/files/metalog.rc6,v 1.5 2002/01/26 22:43:51 woodchip Exp $
depend() {
- need clock
-}
-
-checkconfig() {
- if [ ! -e /etc/metalog/metalog.conf ] ; then
- eerror "You need an /etc/metalog/metalog.conf file to run metalog"
- eerror "There is a sample config file in /usr/share/docs/metalog"
- return 1
- fi
+ need clock
}
start() {
- checkconfig || return 1
- ebegin "Starting metalog"
- start-stop-daemon --start --quiet --exec /usr/sbin/metalog -- -B \
- -p ${METALOG_PID}
- eend $?
+ ebegin "Starting metalog"
+ start-stop-daemon --start --quiet --exec /usr/sbin/metalog \
+ -- -p /var/run/metalog.pid ${METALOG_OPTS}
+ eend $?
}
stop() {
- ebegin "Stopping metalog"
- start-stop-daemon --stop --quiet --pidfile ${METALOG_PID}
- eend $?
+ ebegin "Stopping metalog"
+ start-stop-daemon --stop --quiet --pidfile /var/run/metalog.pid
+ eend $?
}
diff --git a/app-admin/metalog/metalog-0.6-r8.ebuild b/app-admin/metalog/metalog-0.6-r8.ebuild
index 16eb69f161fb..e5416105c5c9 100644
--- a/app-admin/metalog/metalog-0.6-r8.ebuild
+++ b/app-admin/metalog/metalog-0.6-r8.ebuild
@@ -1,22 +1,19 @@
# Copyright 1999-2001 Gentoo Technologies, Inc.
# Distributed under the terms of the GNU General Public License, v2 or later
# Author Jerry A! <jerry@gentoo.org>
-# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/metalog-0.6-r8.ebuild,v 1.1 2002/01/26 15:23:31 aeoo Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/metalog/metalog-0.6-r8.ebuild,v 1.2 2002/01/26 22:43:51 woodchip Exp $
-GFILESDIR=${PORTDIR}/app-admin/metalog/files
S=${WORKDIR}/${P}
DESCRIPTION="A highly configurable replacement for syslogd/klogd"
SRC_URI="http://prdownloads.sourceforge.net/metalog/${P}.tar.gz"
HOMEPAGE="http://metalog.sourceforge.net/"
-DEPEND="virtual/glibc
- >=dev-libs/libpcre-3.4"
-
+DEPEND="virtual/glibc >=dev-libs/libpcre-3.4"
src_unpack() {
- unpack ${A}
- cd ${WORKDIR}
- cat ${GFILESDIR}/metalog-0.6-gentoo.patch | patch -p0 || die
+ unpack ${A} ; cd ${S}
+ # adds a pidfile option. NiCE aeoo! :)
+ patch -p1 < ${FILESDIR}/metalog-0.6-gentoo.patch || die
cd ${S}/src
mv metalog.h metalog.h.orig
sed -e "s:/etc/metalog.conf:/etc/metalog/metalog.conf:g" \
@@ -32,12 +29,10 @@ src_compile() {
src_install () {
make DESTDIR=${D} install || die
- insinto /etc/metalog
- doins metalog.conf
-
- exeinto /etc/init.d
- newexe ${FILESDIR}/metalog.rc6 metalog
-
dodoc AUTHORS COPYING ChangeLog README
newdoc metalog.conf metalog.conf.sample
+
+ insinto /etc/metalog ; doins metalog.conf
+ exeinto /etc/init.d ; newexe ${FILESDIR}/metalog.rc6 metalog
+ insinto /etc/conf.d ; newins ${FILESDIR}/metalog.confd metalog
}