/[gentoo-x86]/app-admin/ulogd/ulogd-2.0.0_beta4.ebuild
Gentoo

Contents of /app-admin/ulogd/ulogd-2.0.0_beta4.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Thu May 31 03:00:39 2012 UTC (2 years, 3 months ago) by zmedico
Branch: MAIN
Changes since 1.1: +3 -3 lines
inherit user for enewgroup and enewuser

(Portage version: 2.2.0_alpha108_p8/cvs/Linux i686)

1 # Copyright 1999-2012 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/app-admin/ulogd/ulogd-2.0.0_beta4.ebuild,v 1.1 2010/10/07 05:31:53 wormo Exp $
4
5 EAPI="1"
6
7 inherit eutils user
8
9 MY_P=${P/_/}
10 S="${WORKDIR}/${MY_P}"
11
12 DESCRIPTION="A userspace logging daemon for netfilter/iptables related logging"
13 HOMEPAGE="http://netfilter.org/projects/ulogd/index.html"
14 SRC_URI="http://ftp.netfilter.org/pub/${PN}/${MY_P}.tar.bz2"
15
16 LICENSE="GPL-2"
17 SLOT="0"
18 KEYWORDS="~amd64 ~ia64 ~ppc -sparc ~x86"
19 # sqlite not supported in ulogd-2 yet
20 IUSE="doc mysql postgres pcap" # sqlite
21
22 RDEPEND="net-firewall/iptables
23 >=net-libs/libnfnetlink-0.0.39
24 >=net-libs/libnetfilter_conntrack-0.0.95
25 >=net-libs/libnetfilter_log-1.0
26 mysql? ( virtual/mysql )
27 postgres? ( dev-db/postgresql-base )
28 pcap? ( net-libs/libpcap )"
29 #sqlite? ( dev-db/sqlite:3 )
30
31 DEPEND="${RDEPEND}
32 sys-devel/autoconf:2.5
33 doc? (
34 app-text/linuxdoc-tools
35 app-text/texlive-core
36 )"
37
38 pkg_setup() {
39 enewgroup ulogd
40 enewuser ulogd -1 -1 /var/log/ulogd ulogd
41 }
42
43 src_compile() {
44 econf \
45 $(use_with mysql) \
46 $(use_with postgres pgsql) \
47 $(use_with pcap pcap /usr) \
48 --without-sqlite3 #$(use_with sqlite sqlite3)
49
50 emake || die "emake failed"
51
52 if use doc ; then
53 # build extra documentation files (.ps, .txt, .html, .dvi)
54
55 # prevent access violations from generation of bitmap font files
56 export VARTEXFONTS="${T}"
57 emake -C doc || die "emake for docs failed"
58 fi
59 }
60
61 src_install() {
62 emake install DESTDIR="${D}" || die "emake install failed"
63
64 doinitd "${FILESDIR}"/ulogd || die "doinitd failed"
65
66 insinto /etc
67 doins ulogd.conf || die "ulogd.conf installation failed"
68
69 dodoc AUTHORS README
70
71 if use doc ; then
72 dohtml doc/ulogd.html
73 dodoc doc/ulogd.dvi
74 dodoc doc/ulogd.txt
75 dodoc doc/ulogd.ps
76 fi
77
78 use mysql && dodoc doc/mysql-ulogd2.sql
79 use postgres && dodoc doc/pgsql-ulogd2.sql
80 #use sqlite && dodoc doc/sqlite3.table
81
82 # install logrotate config
83 insinto /etc/logrotate.d
84 newins ulogd.logrotate ulogd || die "logrotate config failed"
85
86 doman ulogd.8 || die
87 }
88
89 pkg_postinst() {
90 chown root:ulogd "${ROOT}"/etc/ulogd.conf
91 chmod 640 "${ROOT}"/etc/ulogd.conf
92 }

  ViewVC Help
Powered by ViewVC 1.1.20