1 |
pva 11/10/02 08:31:22 |
2 |
|
3 |
Modified: ChangeLog |
4 |
Added: xtables-addons-1.39.ebuild |
5 |
Log: |
6 |
Version bump. |
7 |
|
8 |
(Portage version: 2.1.10.19/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.27 net-firewall/xtables-addons/ChangeLog |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/xtables-addons/ChangeLog?rev=1.27&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/xtables-addons/ChangeLog?rev=1.27&content-type=text/plain |
15 |
diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/xtables-addons/ChangeLog?r1=1.26&r2=1.27 |
16 |
|
17 |
Index: ChangeLog |
18 |
=================================================================== |
19 |
RCS file: /var/cvsroot/gentoo-x86/net-firewall/xtables-addons/ChangeLog,v |
20 |
retrieving revision 1.26 |
21 |
retrieving revision 1.27 |
22 |
diff -u -r1.26 -r1.27 |
23 |
--- ChangeLog 25 Sep 2011 15:49:11 -0000 1.26 |
24 |
+++ ChangeLog 2 Oct 2011 08:31:21 -0000 1.27 |
25 |
@@ -1,6 +1,11 @@ |
26 |
# ChangeLog for net-firewall/xtables-addons |
27 |
# Copyright 1999-2011 Gentoo Foundation; Distributed under the GPL v2 |
28 |
-# $Header: /var/cvsroot/gentoo-x86/net-firewall/xtables-addons/ChangeLog,v 1.26 2011/09/25 15:49:11 swegener Exp $ |
29 |
+# $Header: /var/cvsroot/gentoo-x86/net-firewall/xtables-addons/ChangeLog,v 1.27 2011/10/02 08:31:21 pva Exp $ |
30 |
+ |
31 |
+*xtables-addons-1.39 (02 Oct 2011) |
32 |
+ |
33 |
+ 02 Oct 2011; Peter Volkov <pva@g.o> +xtables-addons-1.39.ebuild: |
34 |
+ Version bump. |
35 |
|
36 |
25 Sep 2011; Sven Wegener <swegener@g.o> xtables-addons-1.37.ebuild, |
37 |
xtables-addons-1.38.ebuild: |
38 |
|
39 |
|
40 |
|
41 |
1.1 net-firewall/xtables-addons/xtables-addons-1.39.ebuild |
42 |
|
43 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/xtables-addons/xtables-addons-1.39.ebuild?rev=1.1&view=markup |
44 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/xtables-addons/xtables-addons-1.39.ebuild?rev=1.1&content-type=text/plain |
45 |
|
46 |
Index: xtables-addons-1.39.ebuild |
47 |
=================================================================== |
48 |
# Copyright 1999-2011 Gentoo Foundation |
49 |
# Distributed under the terms of the GNU General Public License v2 |
50 |
# $Header: /var/cvsroot/gentoo-x86/net-firewall/xtables-addons/xtables-addons-1.39.ebuild,v 1.1 2011/10/02 08:31:22 pva Exp $ |
51 |
|
52 |
EAPI="4" |
53 |
inherit eutils linux-info linux-mod multilib |
54 |
|
55 |
DESCRIPTION="extensions not yet accepted in the main kernel/iptables (patch-o-matic(-ng) successor)" |
56 |
HOMEPAGE="http://xtables-addons.sourceforge.net/" |
57 |
SRC_URI="mirror://sourceforge/xtables-addons/${P}.tar.xz" |
58 |
|
59 |
LICENSE="GPL-2" |
60 |
SLOT="0" |
61 |
KEYWORDS="~amd64 ~x86" |
62 |
IUSE="modules" |
63 |
|
64 |
MODULES="quota2 psd pknock lscan length2 ipv4options ipset6 ipp2p iface gradm geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark echo dnetmap dhcpmac delude checksum chaos account" |
65 |
|
66 |
for mod in ${MODULES}; do |
67 |
IUSE="${IUSE} xtables_addons_${mod}" |
68 |
done |
69 |
|
70 |
DEPEND=">=net-firewall/iptables-1.4.3" |
71 |
|
72 |
RDEPEND="${DEPEND} |
73 |
xtables_addons_ipset6? ( |
74 |
!net-firewall/ipset |
75 |
net-libs/libmnl ) |
76 |
xtables_addons_geoip? ( virtual/perl-Getopt-Long |
77 |
dev-perl/Text-CSV_XS )" |
78 |
|
79 |
DEPEND="${DEPEND} |
80 |
virtual/linux-sources" |
81 |
|
82 |
SKIP_MODULES="" |
83 |
|
84 |
# XA_kernel_check tee "2 6 26" |
85 |
XA_check4internal_module() { |
86 |
local mod=${1} |
87 |
local version=${2} |
88 |
local kconfigname=${3} |
89 |
|
90 |
if use xtables_addons_${mod} && kernel_is -gt ${version}; then |
91 |
ewarn "${kconfigname} should be provided by the kernel. Skipping its build..." |
92 |
if ! linux_chkconfig_present ${kconfigname}; then |
93 |
ewarn "Please enable ${kconfigname} target in your kernel |
94 |
configuration or disable checksum module in ${PN}." |
95 |
fi |
96 |
# SKIP_MODULES in case we need to disable building of everything |
97 |
# like having this USE disabled |
98 |
SKIP_MODULES+=" ${mod}" |
99 |
fi |
100 |
} |
101 |
|
102 |
pkg_setup() { |
103 |
if use modules; then |
104 |
get_version |
105 |
check_modules_supported |
106 |
CONFIG_CHECK="NF_CONNTRACK NF_CONNTRACK_MARK ~CONNECTOR" |
107 |
ERROR_CONNECTOR="Please, enable CONFIG_CONNECTOR if you wish to receive userspace notifications from pknock through netlink/connector" |
108 |
linux-mod_pkg_setup |
109 |
|
110 |
if ! linux_chkconfig_present IPV6; then |
111 |
SKIP_IPV6_MODULES="ip6table_rawpost ipset6" |
112 |
ewarn "No IPV6 support in kernel. Disabling: ${SKIP_IPV6_MODULES}" |
113 |
fi |
114 |
if use xtables_addons_ipset6 && kernel_is -lt 2 6 35; then |
115 |
die "${PN} with ipset requires kernel version >= 2.6.35" |
116 |
fi |
117 |
kernel_is -lt 2 6 29 && die "${PN} requires kernel version >= 2.6.29" |
118 |
XA_check4internal_module tee "2 6 35" NETFILTER_XT_TARGET_TEE |
119 |
XA_check4internal_module checksum "2 6 36" NETFILTER_XT_TARGET_CHECKSUM |
120 |
fi |
121 |
} |
122 |
|
123 |
# Helper for maintainer: cheks if all possible MODULES are listed. |
124 |
XA_qa_check() { |
125 |
local all_modules |
126 |
all_modules=$(sed -n '/^build_/{s/build_\(.*\)=.*/\L\1/;G;s/\n/ /;s/ $//;h}; ${x;p}' "${S}/mconfig") |
127 |
if [[ ${all_modules} != ${MODULES} ]]; then |
128 |
ewarn "QA: Modules in mconfig differ from \$MODULES in ebuild." |
129 |
ewarn "Please, update MODULES in ebuild." |
130 |
ewarn "'${all_modules}'" |
131 |
fi |
132 |
} |
133 |
|
134 |
# Is there any use flag set? |
135 |
XA_has_something_to_build() { |
136 |
local mod |
137 |
for mod in ${MODULES}; do |
138 |
use xtables_addons_${mod} && return |
139 |
done |
140 |
|
141 |
eerror "All modules are disabled. What do you want me to build?" |
142 |
eerror "Please, set XTABLES_ADDONS to any combination of" |
143 |
eerror "${MODULES}" |
144 |
die "All modules are disabled." |
145 |
} |
146 |
|
147 |
# Parse Kbuid files and generates list of sources |
148 |
XA_get_module_name() { |
149 |
[[ $# != 1 ]] && die "XA_get_sources_for_mod: needs exactly one argument." |
150 |
local mod objdir build_mod sources_list |
151 |
mod=${1} |
152 |
objdir=${S}/extensions |
153 |
# Take modules name from mconfig |
154 |
build_mod=$(sed -n "s/\(build_${mod}\)=.*/\1/Ip" "${S}/mconfig") |
155 |
# strip .o, = and everything before = and print |
156 |
sources_list=$(sed -n "/^obj-[$][{]${build_mod}[}]/\ |
157 |
{s:obj-[^+]\+ [+]=[[:space:]]*::;s:[.]o::g;p}" \ |
158 |
"${objdir}/Kbuild") |
159 |
|
160 |
if [[ -d ${S}/extensions/${sources_list} ]]; then |
161 |
objdir=${S}/extensions/${sources_list} |
162 |
sources_list=$(sed -n "/^obj-m/\ |
163 |
{s:obj-[^+]\+ [+]=[[:space:]]*::;s:[.]o::g;p}" \ |
164 |
"${objdir}/Kbuild") |
165 |
fi |
166 |
for mod_src in ${sources_list}; do |
167 |
has ${mod_src} ${SKIP_IPV6_MODULES} || \ |
168 |
echo " ${mod_src}(xtables_addons:${S}/extensions:${objdir})" |
169 |
done |
170 |
} |
171 |
|
172 |
src_prepare() { |
173 |
XA_qa_check |
174 |
XA_has_something_to_build |
175 |
|
176 |
local mod module_name |
177 |
if use modules; then |
178 |
MODULE_NAMES="compat_xtables(xtables_addons:${S}/extensions:)" |
179 |
fi |
180 |
for mod in ${MODULES}; do |
181 |
if ! has ${mod} ${SKIP_MODULES} && use xtables_addons_${mod}; then |
182 |
sed "s/\(build_${mod}=\).*/\1m/I" -i mconfig || die |
183 |
if use modules; then |
184 |
for module_name in $(XA_get_module_name ${mod}); do |
185 |
MODULE_NAMES+=" ${module_name}" |
186 |
done |
187 |
fi |
188 |
else |
189 |
sed "s/\(build_${mod}=\).*/\1n/I" -i mconfig || die |
190 |
fi |
191 |
done |
192 |
einfo "${MODULE_NAMES}" # for debugging |
193 |
|
194 |
sed -e 's/depmod -a/true/' -i Makefile.in || die |
195 |
sed -e '/^all-local:/{s: modules::}' \ |
196 |
-e '/^install-exec-local:/{s: modules_install::}' \ |
197 |
-i extensions/Makefile.in || die |
198 |
|
199 |
use xtables_addons_geoip || sed -e '/^SUBDIRS/{s/geoip//}' -i Makefile.in |
200 |
} |
201 |
|
202 |
src_configure() { |
203 |
set_arch_to_kernel # .. or it'll look for /arch/amd64/Makefile |
204 |
econf --prefix="${EPREFIX}/" \ |
205 |
--libexecdir="${EPREFIX}/$(get_libdir)/" \ |
206 |
--with-kbuild="${KV_DIR}" |
207 |
} |
208 |
|
209 |
src_compile() { |
210 |
emake CFLAGS="${CFLAGS}" CC="$(tc-getCC)" V=1 |
211 |
use modules && BUILD_TARGETS="modules" linux-mod_src_compile |
212 |
} |
213 |
|
214 |
src_install() { |
215 |
emake DESTDIR="${D}" install |
216 |
use modules && linux-mod_src_install |
217 |
dodoc -r README doc/* |
218 |
find "${ED}" -type f -name '*.la' -exec rm -rf '{}' '+' |
219 |
} |