summaryrefslogtreecommitdiff
blob: 84ce5c22c09c568865bbc683df3d3b9fca812067 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
# Copyright 1999-2012 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: $

DESCRIPTION="Virtual web logfile rotater/parser, similar to cronolog and httplog"
HOMEPAGE="http://n0rp.chemlab.org/vlogger/"
SRC_URI="http://n0rp.chemlab.org/${PN}/${P}.tar.gz"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="dbi"

DEPEND=""
RDEPEND="dev-perl/TimeDate
	dbi? ( dev-perl/DBI )"

src_unpack() {
	unpack ${A}
	cd "${S}"
	sed -e 's:/usr/local/sbin/vlogger:/usr/sbin/vlogger:' -i vlogger vlogger.1
}

src_install() {
	doman vlogger.1
	dodoc README
	insinto /etc/vlogger
	dosbin vlogger
	if use dbi ; then
		doins vlogger-dbi.conf
		dodoc mysql_create.sql
	fi
}

pkg_postinst() {
	if use dbi ; then
		elog "If you wish to use vlogger with DBI please see /etc/vlogger/vlogger-dbi.conf"
		elog "The SQL to create the tables for DBI can be found in /usr/share/doc/${P}"
	fi
}