Gentoo Archives: gentoo-commits

From: "Robin H. Johnson (robbat2)" <robbat2@g.o>
To: gentoo-commits@l.g.o
Subject: [gentoo-commits] gentoo-x86 commit in net-firewall/ipset: ipset-6.20.1.ebuild ChangeLog
Date: Sun, 01 Dec 2013 19:16:19
Message-Id: 20131201191616.3EC202004E@flycatcher.gentoo.org
1 robbat2 13/12/01 19:16:16
2
3 Modified: ChangeLog
4 Added: ipset-6.20.1.ebuild
5 Log:
6 Bump per bug #486836, adds new modules and future warning about NET_NS. Make USE=-modules not introduce kernel-sources via MODULES_OPTIONAL_USE. Bug #433411: Drop use
7
8 (Portage version: 2.2.7/cvs/Linux x86_64, unsigned Manifest commit)
9
10 Revision Changes Path
11 1.74 net-firewall/ipset/ChangeLog
12
13 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/ipset/ChangeLog?rev=1.74&view=markup
14 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/ipset/ChangeLog?rev=1.74&content-type=text/plain
15 diff : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/ipset/ChangeLog?r1=1.73&r2=1.74
16
17 Index: ChangeLog
18 ===================================================================
19 RCS file: /var/cvsroot/gentoo-x86/net-firewall/ipset/ChangeLog,v
20 retrieving revision 1.73
21 retrieving revision 1.74
22 diff -p -w -b -B -u -u -r1.73 -r1.74
23 --- ChangeLog 4 Jul 2013 12:18:34 -0000 1.73
24 +++ ChangeLog 1 Dec 2013 19:16:16 -0000 1.74
25 @@ -1,6 +1,14 @@
26 # ChangeLog for net-firewall/ipset
27 # Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
28 -# $Header: /var/cvsroot/gentoo-x86/net-firewall/ipset/ChangeLog,v 1.73 2013/07/04 12:18:34 ago Exp $
29 +# $Header: /var/cvsroot/gentoo-x86/net-firewall/ipset/ChangeLog,v 1.74 2013/12/01 19:16:16 robbat2 Exp $
30 +
31 +*ipset-6.20.1 (01 Dec 2013)
32 +
33 + 01 Dec 2013; Robin H. Johnson <robbat2@g.o> +files/ipset.initd-r3,
34 + +ipset-6.20.1.ebuild, files/ipset.confd, files/ipset.initd-r2:
35 + Bump per bug #486836, adds new modules and future warning about NET_NS. Make
36 + USE=-modules not introduce kernel-sources via MODULES_OPTIONAL_USE. Bug
37 + #433411: Drop use
38
39 04 Jul 2013; Agostino Sarubbo <ago@g.o> ipset-6.17.ebuild:
40 Stable for x86, wrt bug #461978
41
42
43
44 1.1 net-firewall/ipset/ipset-6.20.1.ebuild
45
46 file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/ipset/ipset-6.20.1.ebuild?rev=1.1&view=markup
47 plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/net-firewall/ipset/ipset-6.20.1.ebuild?rev=1.1&content-type=text/plain
48
49 Index: ipset-6.20.1.ebuild
50 ===================================================================
51 # Copyright 1999-2013 Gentoo Foundation
52 # Distributed under the terms of the GNU General Public License v2
53 # $Header: /var/cvsroot/gentoo-x86/net-firewall/ipset/ipset-6.20.1.ebuild,v 1.1 2013/12/01 19:16:16 robbat2 Exp $
54
55 EAPI="5"
56 MODULES_OPTIONAL_USE=modules
57 inherit autotools linux-info linux-mod
58
59 DESCRIPTION="IPset tool for iptables, successor to ippool."
60 HOMEPAGE="http://ipset.netfilter.org/"
61 SRC_URI="http://ipset.netfilter.org/${P}.tar.bz2"
62
63 LICENSE="GPL-2"
64 SLOT="0"
65 KEYWORDS="~amd64 ~ppc ~x86"
66
67 RDEPEND=">=net-firewall/iptables-1.4.7
68 net-libs/libmnl"
69 DEPEND="${RDEPEND}"
70
71 DOCS=( ChangeLog INSTALL README UPGRADE )
72
73 # configurable from outside, e.g. /etc/make.conf
74 IP_NF_SET_MAX=${IP_NF_SET_MAX:-256}
75
76 BUILD_TARGETS="modules"
77 MODULE_NAMES_ARG="kernel/net/netfilter/ipset/:${S}/kernel/net/netfilter/ipset"
78 MODULE_NAMES="xt_set(kernel/net/netfilter/ipset/:${S}/kernel/net/netfilter/)"
79 for i in ip_set{,_bitmap_{ip{,mac},port},_hash_{ip{,port{,ip,net}},net{,port{,net},iface,net}},_list_set}; do
80 MODULE_NAMES+=" ${i}(${MODULE_NAMES_ARG})"
81 done
82
83 check_header_patch() {
84 if ! $(grep -q NFNL_SUBSYS_IPSET "${KV_DIR}/include/linux/netfilter/nfnetlink.h"); then
85 eerror "Sorry, but you have to patch kernel sources with the following patch:"
86 eerror " # cd ${KV_DIR}"
87 eerror " # patch -i ${S}/netlink.patch -p1"
88 eerror "You should recompile and run new kernel to avoid runtime errors."
89 die "Unpatched kernel"
90 fi
91 }
92
93 pkg_setup() {
94 get_version
95 CONFIG_CHECK="NETFILTER"
96 ERROR_NETFILTER="ipset requires NETFILTER support in your kernel."
97 # It does still build without NET_NS, but it may be needed in future.
98 #CONFIG_CHECK="${CONFIG_CHECK} NET_NS"
99 #ERROR_NET_NS="ipset requires NET_NS (network namespace) support in your kernel."
100
101 build_modules=0
102 if use modules; then
103 kernel_is -lt 2 6 35 && die "${PN} requires kernel greater then 2.6.35."
104 if linux_config_src_exists && linux_chkconfig_builtin "MODULES" ; then
105 if linux_chkconfig_present "IP_NF_SET" || \
106 linux_chkconfig_present "IP_SET"; then #274577
107 eerror "There is IP{,_NF}_SET or NETFILTER_XT_SET support in your kernel."
108 eerror "Please either build ipset with modules USE flag disabled"
109 eerror "or rebuild kernel without IP_SET support and make sure"
110 eerror "there is NO kernel ip_set* modules in /lib/modules/<your_kernel>/... ."
111 die "USE=modules and in-kernel ipset support detected."
112 else
113 einfo "Modular kernel detected. Gonna build kernel modules..."
114 build_modules=1
115 fi
116 else
117 eerror "Nonmodular kernel detected, but USE=modules. Either build"
118 eerror "modular kernel (without IP_SET) or disable USE=modules"
119 die "Nonmodular kernel detected, will not build kernel modules"
120 fi
121 fi
122 [[ ${build_modules} -eq 1 ]] && linux-mod_pkg_setup
123 }
124
125 src_prepare() {
126 [[ ${build_modules} -eq 1 ]] && check_header_patch
127 eautoreconf
128 }
129
130 src_configure() {
131 econf \
132 $(use_with modules kmod) \
133 --disable-static \
134 --with-maxsets=${IP_NF_SET_MAX} \
135 --libdir="${EPREFIX}/$(get_libdir)" \
136 --with-ksource="${KV_DIR}" \
137 --with-kbuild="${KV_OUT_DIR}"
138 }
139
140 src_compile() {
141 einfo "Building userspace"
142 emake
143
144 if [[ ${build_modules} -eq 1 ]]; then
145 einfo "Building kernel modules"
146 set_arch_to_kernel
147 emake modules
148 fi
149 }
150
151 src_install() {
152 einfo "Installing userspace"
153 default
154 prune_libtool_files
155
156 newinitd "${FILESDIR}"/ipset.initd-r3 ${PN}
157 newconfd "${FILESDIR}"/ipset.confd ${PN}
158 keepdir /var/lib/ipset
159
160 if [[ ${build_modules} -eq 1 ]]; then
161 einfo "Installing kernel modules"
162 linux-mod_src_install
163 fi
164 }