Gentoo Archives: gentoo-commits

From: Slawek Lis <slis@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] repo/gentoo:master commit in: net-analyzer/suricata/
Date: Mon, 28 Dec 2015 05:53:53
Message-Id: 1451282206.34a58b272507e98993da25151adfb88b0a9e18d0.slis@gentoo
1 commit: 34a58b272507e98993da25151adfb88b0a9e18d0
2 Author: Slawomir Lis <slis <AT> gentoo <DOT> org>
3 AuthorDate: Mon Dec 28 05:56:46 2015 +0000
4 Commit: Slawek Lis <slis <AT> gentoo <DOT> org>
5 CommitDate: Mon Dec 28 05:56:46 2015 +0000
6 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=34a58b27
7
8 version bump
9
10 Package-Manager: portage-2.2.26
11
12 net-analyzer/suricata/Manifest | 1 +
13 net-analyzer/suricata/suricata-2.0.11.ebuild | 120 +++++++++++++++++++++++++++
14 2 files changed, 121 insertions(+)
15
16 diff --git a/net-analyzer/suricata/Manifest b/net-analyzer/suricata/Manifest
17 index 77f17d0..e35b5b9 100644
18 --- a/net-analyzer/suricata/Manifest
19 +++ b/net-analyzer/suricata/Manifest
20 @@ -1 +1,2 @@
21 DIST suricata-2.0.10.tar.gz 3090730 SHA256 c8d1d3b6ce3d2a56577fca224424071afd921739d3859efc8a62229556d4beef SHA512 fa3683a93d85b26166b0f67a85f1a498941aadf4372ef98bd7fe62fcdef150af46b65456e3a764e054c385abbf44138ae6f70882c68ba320508eade6e181f2c6 WHIRLPOOL b867003e76df2b0b1b56c89415ed96acbf9d8966739d77aa303055d29ae5cdad8ad0b58e969336f0c1fc2e5d9990941622c19c062828dae58bf062f5662225f3
22 +DIST suricata-2.0.11.tar.gz 3091124 SHA256 c607f1e18e5636830f42a83f7c67e1466f07db82853f3a9dba4ab8c6c3bc656e SHA512 659e893fef3cdcca8440f2af7596d5cc58b142d3350b9ea5ba57d855c6759a00adafeb15a1dfe91dd55eca1437487eb4e842b4e2913d12417f0b906ca3d54ec9 WHIRLPOOL 5cfa55abd90284a0a3441853af9db18075a23fa5661d89448b409b8fdd1031ad348d76d455b7dfe7b2688e69633f5bbb65dc060cc2426af017ab1bcb824c9ac5
23
24 diff --git a/net-analyzer/suricata/suricata-2.0.11.ebuild b/net-analyzer/suricata/suricata-2.0.11.ebuild
25 new file mode 100644
26 index 0000000..3c69998
27 --- /dev/null
28 +++ b/net-analyzer/suricata/suricata-2.0.11.ebuild
29 @@ -0,0 +1,120 @@
30 +# Copyright 1999-2015 Gentoo Foundation
31 +# Distributed under the terms of the GNU General Public License v2
32 +# $Id$
33 +
34 +EAPI=5
35 +
36 +inherit autotools eutils user
37 +
38 +DESCRIPTION="High performance Network IDS, IPS and Network Security Monitoring engine"
39 +HOMEPAGE="http://suricata-ids.org/"
40 +SRC_URI="http://www.openinfosecfoundation.org/download/${P}.tar.gz"
41 +
42 +LICENSE="GPL-2"
43 +SLOT="0"
44 +KEYWORDS="~amd64 ~x86"
45 +IUSE="+af-packet control-socket cuda debug geoip hardened lua luajit nflog +nfqueue +rules test"
46 +
47 +DEPEND="
48 + >=dev-libs/jansson-2.2
49 + dev-libs/libpcre
50 + dev-libs/libyaml
51 + net-libs/libnet:*
52 + net-libs/libnfnetlink
53 + dev-libs/nspr
54 + dev-libs/nss
55 + net-libs/libpcap
56 + sys-apps/file
57 + cuda? ( dev-util/nvidia-cuda-toolkit )
58 + geoip? ( dev-libs/geoip )
59 + lua? ( dev-lang/lua:* )
60 + luajit? ( dev-lang/luajit:* )
61 + nflog? ( net-libs/libnetfilter_log )
62 + nfqueue? ( net-libs/libnetfilter_queue )
63 +"
64 +# #446814
65 +# prelude? ( dev-libs/libprelude )
66 +# pfring? ( sys-process/numactl net-libs/pf_ring)
67 +# system-htp? ( >=net-analyzer/htp-0.5.5 )
68 +RDEPEND="${DEPEND}"
69 +
70 +pkg_setup() {
71 + enewgroup ${PN}
72 + enewuser ${PN} -1 -1 /var/lib/${PN} "${PN}"
73 +}
74 +
75 +src_prepare() {
76 + epatch "${FILESDIR}/fortify_source-numeric.patch"
77 + epatch "${FILESDIR}/magic-location.patch"
78 + epatch "${FILESDIR}/json.patch"
79 +
80 + eautoreconf
81 +}
82 +
83 +src_configure() {
84 + local myeconfargs=(
85 + "--localstatedir=/var/" \
86 + "--disable-detection" \
87 + $(use_enable af-packet) \
88 + $(use_enable nfqueue) \
89 + $(use_enable test coccinelle) \
90 + $(use_enable test unittests) \
91 + $(use_enable control-socket unix-socket)
92 + )
93 +
94 + if use cuda ; then
95 + myeconfargs+=( $(use_enable cuda) )
96 + fi
97 + if use debug ; then
98 + myeconfargs+=( $(use_enable debug) )
99 + fi
100 + if use geoip ; then
101 + myeconfargs+=( $(use_enable geoip) )
102 + fi
103 + if use hardened ; then
104 + myeconfargs+=( $(use_enable hardened gccprotect) )
105 + fi
106 + if use nflog ; then
107 + myeconfargs+=( $(use_enable nflog) )
108 + fi
109 + # not supported yet (no pfring in portage)
110 +# if use pfring ; then
111 +# myeconfargs+=( $(use_enable pfring) )
112 +# fi
113 + # no libprelude in portage
114 +# if use prelude ; then
115 +# myeconfargs+=( $(use_enable prelude) )
116 +# fi
117 + # htp not added into portage yet
118 +# if use system-htp ; then
119 +# myeconfargs+=( $(use_enable system-htp non-bundled-htp) )
120 +# fi
121 + if use lua ; then
122 + myeconfargs+=( $(use_enable lua) )
123 + fi
124 + if use luajit ; then
125 + myeconfargs+=( $(use_enable luajit) )
126 + fi
127 +
128 +# this should be used when pf_ring use flag support will be added
129 +# LIBS+="-lrt -lnuma"
130 +
131 + econf LIBS="${LIBS}" ${myeconfargs[@]}
132 +}
133 +
134 +src_install() {
135 + emake DESTDIR="${D}" install
136 +
137 + insinto "/etc/${PN}"
138 + doins {classification,reference,threshold}.config suricata.yaml
139 +
140 + if use rules ; then
141 + insinto "/etc/${PN}/rules"
142 + doins rules/*.rules
143 + fi
144 +
145 + dodir "/var/lib/${PN}"
146 + dodir "/var/log/${PN}"
147 + fowners -R ${PN}: "/var/lib/${PN}" "/var/log/${PN}" "/etc/${PN}"
148 + fperms 750 "/var/lib/${PN}" "/var/log/${PN}" "/etc/${PN}"
149 +}
150 \ No newline at end of file