]> git.pld-linux.org Git - packages/xtables-addons.git/blob - xtables-addons.spec
- up to 1.5.4.1, now builds with iptables-1.4.1
[packages/xtables-addons.git] / xtables-addons.spec
1 #
2 # TODO
3 # - kernel modules package (or not, 2 packages with mutual R?)
4 # - descriptions
5 #
6 # Conditional build:
7 %bcond_without  dist_kernel     # without distribution kernel
8 %bcond_without  kernel
9 %bcond_without  userspace
10 #
11 %define         rel 0.1
12 Summary:        Extensible packet filtering system && extensible NAT system
13 Summary(pl.UTF-8):      System filtrowania pakietów oraz system translacji adresów (NAT)
14 Summary(pt_BR.UTF-8):   Ferramenta para controlar a filtragem de pacotes no kernel-2.6.x
15 Summary(ru.UTF-8):      Утилиты для управления пакетными фильтрами ядра Linux
16 Summary(uk.UTF-8):      Утиліти для керування пакетними фільтрами ядра Linux
17 Summary(zh_CN.UTF-8):   Linux内核包过滤管理工具
18 Name:           xtables-addons
19 Version:        1.5.4.1
20 Release:        %{rel}@%{_kernel_ver_str}
21 License:        GPL
22 Group:          Networking/Daemons
23 Source0:        http://dev.computergmbh.de/files/xtables/%{name}-%{version}.tar.bz2
24 # Source0-md5:  f78352e9021986347cd347edc82c40c2
25 Patch0:         %{name}-libs.patch
26 #BuildRequires: xtables-devel >= 1.5.2
27 BuildRequires:  iptables-devel >= 1.4.1
28 %{?with_dist_kernel:BuildRequires:      kernel%{_alt_kernel}-module-build >= 3:2.6.25}
29 BuildRequires:  rpmbuild(macros) >= 1.379
30 %{?with_dist_kernel:%requires_releq_kernel}
31 Requires(post,postun):  /sbin/depmod
32 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
33
34 %description
35 An extensible NAT system, and an extensible packet filtering system.
36 Replacement of ipchains in 2.6 and higher kernels.
37
38 %description -l pl.UTF-8
39 Wydajny system translacji adresów (NAT) oraz system filtrowania
40 pakietów. Zamiennik ipchains w jądrach 2.6 i nowszych.
41
42 %description -l pt_BR.UTF-8
43 Esta é a ferramenta que controla o código de filtragem de pacotes do
44 kernel 2.6, obsoletando ipchains. Com esta ferramenta você pode
45 configurar filtros de pacotes, NAT, mascaramento (masquerading),
46 regras dinâmicas (stateful inspection), etc.
47
48 %description -l ru.UTF-8
49 xtables-addons управляют кодом фильтрации сетевых пакетов в ядре
50 Linux. Они позволяют вам устанавливать межсетевые экраны (firewalls) и
51 IP маскарадинг, и т.п.
52
53 %description -l uk.UTF-8
54 xtables-addons управляють кодом фільтрації пакетів мережі в ядрі
55 Linux. Вони дозволяють вам встановлювати міжмережеві екрани
56 (firewalls) та IP маскарадинг, тощо.
57
58 %prep
59 %setup -q
60 %patch0 -p1
61
62 %build
63 %configure \
64         --with-kbuild=%{_kernelsrcdir} \
65         --with-ksource=%{_kernelsrcdir}
66 export XA_TOPSRCDIR=$PWD
67
68 %if %{with kernel}
69 %build_kernel_modules -C extensions -m compat_xtables
70 %endif
71
72 %if %{with userspace}
73 %{__make} -C extensions libs
74 %endif
75
76 %install
77 rm -rf $RPM_BUILD_ROOT
78
79 %if %{with kernel}
80 %install_kernel_modules -m extensions/compat_xtables -d kernel/net/netfilter
81 install extensions/xt_*ko $RPM_BUILD_ROOT/lib/modules/%{_kernel_ver}/kernel/net/netfilter
82 %endif
83 %if %{with userspace}
84 %{__make} -C extensions libs_install \
85         DESTDIR=$RPM_BUILD_ROOT
86 %endif
87
88 %clean
89 rm -rf $RPM_BUILD_ROOT
90
91 %post
92 %depmod %{_kernel_ver}
93
94 %postun
95 %depmod %{_kernel_ver}
96
97 %files
98 %defattr(644,root,root,755)
99 %if %{with userspace}
100 %attr(755,root,root) %{_libdir}/xtables/libxt_CHAOS.so
101 %attr(755,root,root) %{_libdir}/xtables/libxt_DELUDE.so
102 %attr(755,root,root) %{_libdir}/xtables/libxt_IPMARK.so
103 %attr(755,root,root) %{_libdir}/xtables/libxt_LOGMARK.so
104 %attr(755,root,root) %{_libdir}/xtables/libxt_TARPIT.so
105 %attr(755,root,root) %{_libdir}/xtables/libxt_TEE.so
106 %attr(755,root,root) %{_libdir}/xtables/libxt_condition.so
107 %attr(755,root,root) %{_libdir}/xtables/libxt_geoip.so
108 %attr(755,root,root) %{_libdir}/xtables/libxt_ipp2p.so
109 %attr(755,root,root) %{_libdir}/xtables/libxt_portscan.so
110 %endif
111 %if %{with kernel}
112 /lib/modules/%{_kernel_ver}/kernel/net/netfilter/*
113 %endif
This page took 0.057955 seconds and 3 git commands to generate.