summaryrefslogtreecommitdiff
blob: 84f4c66c3176764933e2912ac3136cbaa2194b9f (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
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
# Copyright 1999-2005 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
# $Header: /var/cvsroot/gentoo-x86/app-admin/sdsc-syslog/sdsc-syslog-1.0.2.ebuild,v 1.6 2005/01/01 11:24:48 eradicator Exp $

DESCRIPTION="SDSC Secure Syslog provides RFC3080 and RFC3081 logging services"
HOMEPAGE="http://security.sdsc.edu/software/sdsc-syslog/"
SRC_URI="mirror://sourceforge/sdscsyslog/sdscsyslogd-${PV}-src.tgz"

LICENSE="BSD"
SLOT="0"
KEYWORDS="x86"
# beep		= support BEEP (through RoadRunner)
# debug		= include debug info
# doc		= include documentation
# static    = link with RoadRunner statically
IUSE="beep debug doc static"

RDEPEND="beep? ( >=net-libs/roadrunner-0.9.1 )
	virtual/libc
	dev-libs/libxml2
	sys-libs/zlib
	>=dev-libs/glib-2"
DEPEND="${RDEPEND}
	>=dev-util/pkgconfig-0.15.0
	doc? ( >=app-doc/doxygen-1.3.2 )
	sys-apps/gawk
	sys-devel/flex
	sys-devel/bison
	>=sys-devel/automake-1.5
	>=sys-devel/autoconf-2.52"
PROVIDE="virtual/logger"

S=${WORKDIR}/sdscsyslogd-${PV}

src_compile() {
	local myconf
	if use beep ; then
		use static \
			&& myconf=`use_enable beep static-rr` \
			|| myconf=`use_with beep librr`
	fi

	econf \
		${myconf} \
		`use_enable debug debug` \
		`use_enable debug testing` \
		`use_with doc doxygen` \
		|| die "configure failed"

	# Build the logger itself ...
	emake all || die "emake failed"

	# ... and optionally generate HTML documentation
	if use doc ; then
		emake docs || die "emake failed"
	fi
}

src_install() {
	# Makefiles seem to be OK
	emake DESTDIR=${D} install || die

	# Gzip potential man pages
	prepallman

	# Include normal documentation
	dodoc AUTHORS docs/TODO

	# move a few /usr/share/SDSCSyslogd files
	dodir /etc
	mv ${D}/usr/share/SDSCSyslogd/syslogd.conf* ${D}/etc
	mv ${D}/usr/share/SDSCSyslogd/* ${D}/usr/share/doc/${PF}
	rmdir ${D}/usr/share/SDSCSyslogd

	# ... and optionally doxygen-generated one
	use doc && dohtml docs/html/*
}


pkg_postinst() {
	einfo "See /etc/syslogd.conf.sample for client configuration and"
	einfo "/etc/syslogd.conf.sample-loghost for server configuration"
}