iptables-vl.spec 9.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304
  1. Summary: Packet filtering tool
  2. Summary(ja): パケットフィルタリングツール
  3. Name: iptables
  4. Version: 1.4.21
  5. Release: 1%{?_dist_release}
  6. License: GPL
  7. Group: System Environment/Base
  8. URL: http://www.netfilter.org/
  9. Source0: ftp://ftp.netfilter.org/pub/iptables/%{name}-%{version}.tar.bz2
  10. Source1: iptables.init
  11. Source2: iptables-config
  12. # Patch5: iptables-1.4.3.1-cloexec.patch
  13. BuildRoot: %{_tmppath}/%{name}-%{version}-root
  14. BuildRequires: perl
  15. BuildRequires: kernel-headers >= 2.4.0
  16. Conflicts : kernel < 2.4.20
  17. Requires(post): chkconfig
  18. Requires(preun): chkconfig
  19. Vendor: Project Vine
  20. Distribution: Vine Linux
  21. Packager: daisuke
  22. %description
  23. The iptables utility controls the network packet filtering code in the
  24. Linux kernel. If you need to set up firewalls and/or IP masquerading,
  25. you should install this package.
  26. %description -l ja
  27. iptables は Linux kernel のネットワークパケットフィルタを制御するための
  28. ユーティリティです。これを用いることで、ファイアウオールや IP マスカレー
  29. ディング, NAT などを設定することができます。
  30. %package devel
  31. Summary: Libraries, includes, etc. to develop iptables
  32. Summary(ja): iptables 開発用ライブラリ、ヘッダファイル
  33. Group: Development/Libraries
  34. Requires: iptables = %{version}-%{release}
  35. %description devel
  36. Libraries, include files, etc you can use to develop iptables.
  37. %description devel -l ja
  38. iptables を用いた開発に使用するライブラリやヘッダファイルです。
  39. %package ipv6
  40. Summary: IPv6 Packet filtering tool
  41. Summary(ja): IPv6 用パケットフィルタリングツール
  42. Group: System Environment/Base
  43. Requires: %{name} = %{version}-%{release}
  44. Requires(post): chkconfig
  45. Requires(preun): chkconfig
  46. %description ipv6
  47. The iptables package contains IPv6 (the next version of the IP
  48. protocol) support for iptables. Iptables controls the Linux kernel
  49. network packet filtering code, allowing you to set up firewalls and IP
  50. masquerading.
  51. %description ipv6 -l ja
  52. iptables-ipv6 は iptables で IPv6 をサポートするためのパッケージです。
  53. これを用いることで、IPv6 環境におけるファイアウオールや IP マスカレー
  54. ディング, NAT などを設定することができます。
  55. %prep
  56. %setup -q
  57. # %patch5 -p1 -b .cloexec
  58. %build
  59. CFLAGS="$RPM_OPT_FLAGS -fno-strict-aliasing" \
  60. ./configure --enable-devel \
  61. --enable-libipq \
  62. --bindir=/bin \
  63. --sbindir=/sbin \
  64. --sysconfdir=/etc \
  65. --libdir=%{_libdir} \
  66. --libexecdir=/%{_lib} \
  67. --with-xtlibdir=/%{_lib}/xtables \
  68. --mandir=%{_mandir} \
  69. --includedir=%{_includedir} \
  70. --with-kernel=/usr \
  71. --with-kbuild=/usr \
  72. --with-ksource=/usr
  73. # do not use rpath
  74. sed -i 's|^hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' libtool
  75. sed -i 's|^runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' libtool
  76. make %{?_smp_mflags}
  77. %install
  78. rm -rf %{buildroot}
  79. make install DESTDIR=%{buildroot}
  80. # remove la file(s)
  81. rm -f %{buildroot}/%{_libdir}/*.la
  82. # install ip*tables.h header files
  83. install -m 644 include/ip*tables.h %{buildroot}%{_includedir}/
  84. # install ipulog header file
  85. install -d -m 755 %{buildroot}%{_includedir}/libipulog/
  86. install -m 644 include/libipulog/*.h %{buildroot}%{_includedir}/libipulog/
  87. # install init scripts and configuration files
  88. install -d -m 755 %{buildroot}/etc/rc.d/init.d
  89. install -c -m 755 %{SOURCE1} %{buildroot}/etc/rc.d/init.d/iptables
  90. sed -e 's;iptables;ip6tables;g' -e 's;IPTABLES;IP6TABLES;g' < %{SOURCE1} > ip6tables.init
  91. install -c -m 755 ip6tables.init %{buildroot}/etc/rc.d/init.d/ip6tables
  92. install -d -m 755 %{buildroot}/etc/sysconfig
  93. install -c -m 755 %{SOURCE2} %{buildroot}/etc/sysconfig/iptables-config
  94. sed -e 's;iptables;ip6tables;g' -e 's;IPTABLES;IP6TABLES;g' < %{SOURCE2} > ip6tables-config
  95. install -c -m 755 ip6tables-config %{buildroot}/etc/sysconfig/ip6tables-config
  96. %clean
  97. rm -rf %{buildroot}
  98. %post
  99. /sbin/ldconfig
  100. /sbin/chkconfig --add iptables
  101. %postun -p /sbin/ldconfig
  102. %preun
  103. if [ "$1" = 0 ]; then
  104. /sbin/chkconfig --del iptables
  105. fi
  106. %post ipv6
  107. /sbin/chkconfig --add ip6tables
  108. %preun ipv6
  109. if [ "$1" = 0 ]; then
  110. /sbin/chkconfig --del ip6tables
  111. fi
  112. %files
  113. %defattr(-,root,root)
  114. %doc COPYING INSTALL INCOMPATIBILITIES
  115. %attr(0755,root,root) /etc/rc.d/init.d/iptables
  116. %config(noreplace) %attr(0600,root,root) /etc/sysconfig/iptables-config
  117. /sbin/iptables*
  118. /sbin/xtables-multi
  119. %{_mandir}/man1/iptables-xml*
  120. %{_mandir}/man8/iptables*
  121. %dir /%{_lib}/xtables
  122. /%{_lib}/xtables/libipt*
  123. /%{_lib}/xtables/libxt*
  124. %{_libdir}/libip*tc.so.*
  125. %{_libdir}/libxtables.so.*
  126. %{_libdir}/libipq.so.*
  127. %files ipv6
  128. %defattr(-,root,root)
  129. %attr(0755,root,root) /etc/rc.d/init.d/ip6tables
  130. %config(noreplace) %attr(0600,root,root) /etc/sysconfig/ip6tables-config
  131. /sbin/ip6tables*
  132. /bin/iptables-xml
  133. %{_mandir}/man8/ip6tables*
  134. /%{_lib}/xtables/libip6t*
  135. %files devel
  136. %defattr(-,root,root)
  137. %{_includedir}/*.h
  138. %dir %{_includedir}/libiptc
  139. %{_includedir}/libiptc/*.h
  140. %dir %{_includedir}/libipulog
  141. %{_includedir}/libipulog/*.h
  142. %{_mandir}/man3/*
  143. %{_libdir}/libipq.so
  144. %{_libdir}/libip*tc.so
  145. %{_libdir}/libxtables.so
  146. %{_libdir}/pkgconfig/libiptc.pc
  147. %{_libdir}/pkgconfig/libip4tc.pc
  148. %{_libdir}/pkgconfig/libip6tc.pc
  149. %{_libdir}/pkgconfig/libipq.pc
  150. %{_libdir}/pkgconfig/xtables.pc
  151. %changelog
  152. * Tue Dec 10 2013 Tomohiro "Tomo-p" KATO <tomop@teamgedoh.net> 1.4.21
  153. - new upstream release.
  154. * Fri Oct 19 2012 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.4.16.3
  155. - new upstream release 1.4.16.2
  156. - update source1 url
  157. * Thu Oct 18 2012 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.4.16.2
  158. - new upstream release 1.4.16.2
  159. - fix ipv6 subpackage ja discription
  160. - drop old patch
  161. - add with-xtlibdir in configure section
  162. * Fri Apr 22 2011 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.10-1
  163. - update to 1.4.10
  164. * Thu Mar 04 2010 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.7-1
  165. - new upstream release
  166. * Wed Aug 12 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.4-2
  167. - don't fail initscript if config file is not found.
  168. * Wed Jun 17 2009 Satoshi IWAMOTO <satoshi.iwamoto@nifty.ne.jp> 1.4.4-1
  169. - new upstream release
  170. * Mon Apr 13 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.3.2-1
  171. - new upstream release
  172. * Mon Apr 13 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.3.1-1
  173. - new upstream release
  174. - libiptc is now shared
  175. - drop patch1
  176. - update patch2
  177. - fix typo in spec file
  178. * Fri Apr 03 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.2-2
  179. - rebuild to add sign..
  180. * Wed Apr 01 2009 Daisuke SUZUKI <daisuke@linux.or.jp> 1.4.2-1
  181. - new upstream release
  182. - spec in utf-8
  183. * Sat Jul 28 2007 Ryoichi INAGAKI <ryo1@bc.wakwak.com> 1.3.6-0vl2
  184. - changed devel package Group to Development/Libraries
  185. * Sat Nov 04 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.6-0vl1
  186. - new upstream release
  187. - remove libiptc.a from %%files
  188. - libiptc is not a public interface
  189. * Wed Sep 06 2006 Kazutaka HARADA <kazutaka@dc4.so-net.ne.jp> 1.3.5-0vl4
  190. - updates Summaries and Descriptions (<BTS:0101>)
  191. * Sun Aug 13 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.5-0vl3
  192. - updates Summaries (<BTS:0101>)
  193. * Thu Jul 06 2006 MATSUBAYASHI Kohji <shaolin@vinelinux.org> 1.3.5-0vl2
  194. - add Patch10 (to include libipt_recent.so)
  195. * Tue Jun 13 2006 Daisuke SUZUKI <daisuke@linux.or.jp> 1.3.5-0vl1
  196. - new upstream release
  197. * Tue Jun 22 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.2.11-0vl1
  198. - new upstream release
  199. * Thu Jun 17 2004 Daisuke SUZUKI <daisuke@linux.or.jp> 1.2.10-0vl1
  200. - new upstream release
  201. * Fri Nov 21 2003 Daisuke SUZUKI <daisuke@linux.or.jp> 1.2.9-0vl1
  202. - new upstream release
  203. * Thu Jul 24 2003 Takeru INOUE <takeru.inoue@gamma.ocn.ne.jp> 1.2.7a-0vl3
  204. - add ipv6 version
  205. * Sun Mar 23 2003 Takeru INOUE <takeru.inoue@gamma.ocn.ne.jp> 1.2.7a-0vl2
  206. - rebuild development version
  207. * Sun Sep 29 2002 Daisuke SUZUKI <daisuke@linux.or.jp> 1.2.7a-0vl1
  208. - new upstream release 1.2.7a
  209. * Mon Mar 25 2002 Seiya Nishizawa <seiya@kugi.kyoto-u.ac.jp> 1.2.6-0vl0
  210. - updated to 1.2.6
  211. * Thu Mar 07 2002 Toru Sagami <sagami@vinelinux.org> 1.2.5-0vl1
  212. - kernel24 -> kernel for Requires
  213. * Sat Mar 02 2002 Toru Sagami <sagami@vinelinux.org> 1.2.5-0vl0
  214. - updated to 1.2.5 and merged with RHL's spec
  215. - compatibilities: %%{_sbindir} -> /sbin, %%{_libdir} -> /lib
  216. * Mon Nov 19 2001 Daisuke SUZUKI <daisuke@linux.or.jp> 1.2.2-2vl1
  217. - build for Vine Linux based on conectiva iptables package.
  218. * Sun Jun 17 2001 Harald Welte <laforge@conectiva.com>
  219. + iptables-1.2.2-2cl
  220. - fixes iptables-save / -restore problems (Closes: #3673)
  221. - fixes REJECT save problem
  222. - fixes ipv6 compile problem
  223. - moved binaries to sbindir instead of bindir
  224. * Wed May 30 2001 Harald Welte <laforge@conectiva.com>
  225. + iptables-1.2.2-1cl
  226. - updated to 1.2.2 (Closes: #3376)
  227. * Wed May 30 2001 Wanderlei Antonio Cavassin <cavassin@conectiva.com>
  228. + iptables-1.2.1a-2cl
  229. - recompiled for kernel-2.4.4-2cl (Closes: #3354)
  230. - spec file changes provided by Vagner Farias <vfarias@conectiva.com>
  231. * Fri Apr 20 2001 Harald Welte <laforge@conectiva.com>
  232. + iptables-1.2.1a-1cl
  233. - updated to version 1.2.1a because of various bugfixes
  234. * Fri Mar 16 2001 Harald Welte <laforge@conectiva.com>
  235. + iptables-1.2.1-1cl
  236. - updated to version 1.2.1
  237. * Wed Jan 10 2001 Andreas Hasenack <andreas@conectiva.com>
  238. - updated to version 1.2
  239. - added requirement for kernel >= 2.4.0
  240. * Thu Dec 14 2000 Andreas Hasenack <andreas@conectiva.com>
  241. - first package for Conectiva Linux