]> git.pld-linux.org Git - packages/xtables-addons.git/blame - xtables-addons.spec
- geoipt problem solved with suggests line; rel 2
[packages/xtables-addons.git] / xtables-addons.spec
CommitLineData
8bb72a08 1# TODO
0330c995 2# - descriptions
8bb72a08 3#
2741a7bf
AM
4# Conditional build:
5%bcond_without dist_kernel # without distribution kernel
64731849
TP
6%bcond_without kernel # don't build kernel modules
7%bcond_without userspace # # don't build userspace tools
8%bcond_with verbose # verbose build (V=1)
9
10%if %{without kernel}
11%undefine with_dist_kernel
12%endif
13%if "%{_alt_kernel}" != "%{nil}"
14%undefine with_userspace
15%endif
16%if %{without userspace}
17# nothing to be placed to debuginfo package
18%define _enable_debug_packages 0
19%endif
20
bb939eb4 21%define rel 2
2741a7bf
AM
22Summary: Extensible packet filtering system && extensible NAT system
23Summary(pl.UTF-8): System filtrowania pakietów oraz system translacji adresów (NAT)
24Summary(pt_BR.UTF-8): Ferramenta para controlar a filtragem de pacotes no kernel-2.6.x
25Summary(ru.UTF-8): Утилиты для управления пакетными фильтрами ядра Linux
26Summary(uk.UTF-8): Утиліти для керування пакетними фільтрами ядра Linux
27Summary(zh_CN.UTF-8): Linux内核包过滤管理工具
28Name: xtables-addons
8f462252 29Version: 1.27
64731849 30Release: %{rel}
2741a7bf 31License: GPL
64731849 32Group: Networking/Admin
8f462252
AM
33Source0: http://downloads.sourceforge.net/xtables-addons/%{name}-%{version}.tar.xz
34# Source0-md5: f4f65ce5361d7f8c0908ca3db37fa8ee
564b72e7 35URL: http://xtables-addons.sourceforge.net/
8af0bca6 36Patch0: kernelrelease.patch
011c75bf
KK
37BuildRequires: autoconf
38BuildRequires: automake
3e68c602 39BuildRequires: iptables-devel >= 1.4.3
0330c995 40%{?with_dist_kernel:BuildRequires: kernel%{_alt_kernel}-module-build >= 3:2.6.25}
011c75bf 41BuildRequires: libtool
62f40bbf 42BuildRequires: pkgconfig
0330c995 43BuildRequires: rpmbuild(macros) >= 1.379
3e68c602 44Requires: iptables >= 1.4.3
2741a7bf
AM
45BuildRoot: %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
46
bcb7e0a4
ER
47# use macro, so adapter won't try to wrap
48%define kpackage kernel%{_alt_kernel}-net-xtables-addons = %{rel}@%{_kernel_ver_str}
49
2741a7bf
AM
50%description
51An extensible NAT system, and an extensible packet filtering system.
52Replacement of ipchains in 2.6 and higher kernels.
53
bcb7e0a4
ER
54You need %{kpackage} installed for the tools to work.
55
2741a7bf
AM
56%description -l pl.UTF-8
57Wydajny system translacji adresów (NAT) oraz system filtrowania
58pakietów. Zamiennik ipchains w jądrach 2.6 i nowszych.
59
60%description -l pt_BR.UTF-8
61Esta é a ferramenta que controla o código de filtragem de pacotes do
62kernel 2.6, obsoletando ipchains. Com esta ferramenta você pode
63configurar filtros de pacotes, NAT, mascaramento (masquerading),
64regras dinâmicas (stateful inspection), etc.
65
66%description -l ru.UTF-8
67xtables-addons управляют кодом фильтрации сетевых пакетов в ядре
68Linux. Они позволяют вам устанавливать межсетевые экраны (firewalls) и
69IP маскарадинг, и т.п.
70
71%description -l uk.UTF-8
72xtables-addons управляють кодом фільтрації пакетів мережі в ядрі
73Linux. Вони дозволяють вам встановлювати міжмережеві екрани
74(firewalls) та IP маскарадинг, тощо.
75
64731849 76%package -n kernel%{_alt_kernel}-net-xtables-addons
bcb7e0a4 77Summary: Kernel modules for xtables addons
e3c9233c 78Summary(pl.UTF-8): Moudły jądra dla xtables addons
bcb7e0a4 79Release: %{rel}@%{_kernel_ver_str}
64731849 80Group: Base/Kernel
a3a7bc9c
ER
81# VERSION only dependency is intentional, for allowing multiple kernel pkgs and
82# single userspace package installs.
83Requires: %{name} = %{version}
bb939eb4
ER
84Suggests: xtables-geoip
85Conflicts: xtables-geoip < 20090901-2
64731849
TP
86%{?with_dist_kernel:%requires_releq_kernel}
87Requires(post,postun): /sbin/depmod
88
89%description -n kernel%{_alt_kernel}-net-xtables-addons
bcb7e0a4 90Kernel modules for xtables addons.
64731849 91
e3c9233c 92%description -n kernel%{_alt_kernel}-net-xtables-addons -l pl.UTF-8
93Moduły jądra dla xtables addons.
94
2741a7bf
AM
95%prep
96%setup -q
7ad03426 97%patch0 -p1
2741a7bf 98
564b72e7 99%{__sed} -i -e 's#build_ipset=m#build_ipset=n#' mconfig
100
2741a7bf 101%build
011c75bf
KK
102%{__libtoolize}
103%{__aclocal}
104%{__autoconf}
105%{__automake}
2741a7bf 106%configure \
8af0bca6 107 --with-kbuild=no
7ad03426 108
109%if %{with kernel}
8af0bca6 110srcdir=${PWD:-$(pwd)}
8f462252 111%build_kernel_modules V=1 XA_ABSTOPSRCDIR=$srcdir -C extensions -m compat_xtables
7ad03426 112%endif
113
114%if %{with userspace}
8af0bca6 115%{__make}
7ad03426 116%endif
2741a7bf
AM
117
118%install
119rm -rf $RPM_BUILD_ROOT
f0af06f8 120install -d $RPM_BUILD_ROOT{/etc/rc.d/init.d,/lib/modules/%{_kernel_ver}/kernel/net/ipv4/netfilter,%{_mandir}/man8}
2741a7bf 121
7ad03426 122%if %{with kernel}
84556dc6
PS
123cd extensions
124%install_kernel_modules -m compat_xtables -d kernel/net/netfilter
bcb7e0a4 125install -p xt_*ko $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/kernel/net/netfilter
84556dc6 126cd ..
7ad03426 127%endif
84556dc6 128
7ad03426 129%if %{with userspace}
84556dc6
PS
130%{__make} -C extensions install \
131 DESTDIR=$RPM_BUILD_ROOT
84556dc6 132
8af0bca6
ER
133install -d $RPM_BUILD_ROOT%{_mandir}/man8
134cp -a xtables-addons.8 $RPM_BUILD_ROOT%{_mandir}/man8
7ad03426 135%endif
2741a7bf
AM
136
137%clean
138rm -rf $RPM_BUILD_ROOT
139
8f462252
AM
140%post -p /sbin/ldconfig
141%postun -p /sbin/ldconfig
142
64731849 143%post -n kernel%{_alt_kernel}-net-xtables-addons
0330c995 144%depmod %{_kernel_ver}
145
64731849 146%postun -n kernel%{_alt_kernel}-net-xtables-addons
0330c995 147%depmod %{_kernel_ver}
148
64731849 149%if %{with userspace}
2741a7bf
AM
150%files
151%defattr(644,root,root,755)
8f462252 152%attr(755,root,root) %{_sbindir}/iptaccount
edb92c36 153%attr(755,root,root) %{_libdir}/xtables/libxt_*.so
8f462252 154%attr(755,root,root) %{_libdir}/libxt_ACCOUNT_cl.so.*
8af0bca6 155%{_mandir}/man8/xtables-addons.8*
7ad03426 156%endif
64731849 157
7ad03426 158%if %{with kernel}
64731849
TP
159%files -n kernel%{_alt_kernel}-net-xtables-addons
160%defattr(644,root,root,755)
84556dc6 161/lib/modules/%{_kernel_ver}/kernel/net/netfilter/compat_xtables.ko.gz
edb92c36 162/lib/modules/%{_kernel_ver}/kernel/net/netfilter/xt_*.ko.gz
7ad03426 163%endif
This page took 0.126637 seconds and 4 git commands to generate.