681c1b6
%global ebminor 4
681c1b6
be11fba
Name:			ebtables
d85d9ec
Version:		2.0.10
158d794
Release:		25%{?dist}
be11fba
Summary:		Ethernet Bridge frame table administration tool
be11fba
License:		GPLv2+
be11fba
Group:			System Environment/Base
be11fba
URL:			http://ebtables.sourceforge.net/
681c1b6
Source0:		http://downloads.sourceforge.net/ebtables/ebtables-v%{version}-%{ebminor}.tar.gz
accea79
Source1:		ebtables-save
f7251e7
Source2:		ebtables.systemd
f7251e7
Source3:		ebtables.service
d85d9ec
Patch0:			ebtables-2.0.10-norootinst.patch
409c505
Patch3:			ebtables-2.0.9-lsb.patch
681c1b6
Patch4:			ebtables-2.0.10-linkfix.patch
8e0f4ac
Patch5:			ebtables-2.0.0-audit.patch
139410d
# Upstream commit 5e126db0f
139410d
Patch6:			0001-add-RARP-and-update-iana-url.patch
c3a2b8c
# Move lockfile to /run/ebtables.lock
c3a2b8c
Patch7:			ebtables-2.0.10-lockdirfix.patch
8e67d1c
Patch8:			ebtables-2.0.10-noflush.patch
f7251e7
BuildRequires:		systemd-units
f7251e7
Requires(post):		systemd
f7251e7
Requires(preun):	systemd
f7251e7
Requires(postun):	systemd
2dc06be
%if 0%{?fedora} > 24
9f6db44
Conflicts:              setup < 2.10.4-1
2dc06be
%endif
871a94d
871a94d
%description
1829901
Ethernet bridge tables is a firewalling tool to transparently filter network
871a94d
traffic passing a bridge. The filtering possibilities are limited to link
871a94d
layer filtering and some basic filtering on higher network layers.
871a94d
1829901
This tool is the userspace control for the bridge and ebtables kernel
8816379
components (built by default in Fedora kernels).
1829901
871a94d
The ebtables tool can be used together with the other Linux filtering tools,
871a94d
like iptables. There are no known incompatibility issues.
871a94d
871a94d
%prep
681c1b6
%setup -q -n ebtables-v%{version}-%{ebminor}
d85d9ec
%patch0 -p1 -b .norootinst
409c505
%patch3 -p1 -b .lsb
681c1b6
# extension modules need to link to libebtc.so for ebt_errormsg
681c1b6
%patch4 -p1 -b .linkfix
8e0f4ac
%patch5 -p1 -b .AUDIT
139410d
%patch6 -p1 -b .RARP
c3a2b8c
%patch7 -p1 -b .lockdirfix
8e67d1c
%patch8 -p1 -b .noflush
871a94d
be11fba
# Convert to UTF-8
be11fba
f=THANKS; iconv -f iso-8859-1 -t utf-8 $f -o $f.utf8 ; mv $f.utf8 $f
be11fba
871a94d
%build
81261f9
make %{?_smp_mflags} CFLAGS="${RPM_OPT_FLAGS}" LIBDIR="/%{_lib}/ebtables" BINDIR="/sbin" MANDIR="%{_mandir}" LDFLAGS="${RPM_LD_FLAGS} -Wl,-z,now"
871a94d
871a94d
%install
f7251e7
mkdir -p %{buildroot}%{_initrddir}
f7251e7
mkdir -p %{buildroot}%{_unitdir}
f7251e7
install -p %{SOURCE3} %{buildroot}%{_unitdir}/
139410d
chmod -x %{buildroot}%{_unitdir}/*.service
f7251e7
mkdir -p %{buildroot}%{_libexecdir}
f7251e7
install -m0755 %{SOURCE2} %{buildroot}%{_libexecdir}/ebtables
f7251e7
mkdir -p %{buildroot}%{_sysconfdir}/sysconfig
f7251e7
make DESTDIR="%{buildroot}" LIBDIR="/%{_lib}/ebtables" BINDIR="/sbin" MANDIR="%{_mandir}" install
f7251e7
touch %{buildroot}%{_sysconfdir}/sysconfig/ebtables.filter
f7251e7
touch %{buildroot}%{_sysconfdir}/sysconfig/ebtables.nat
f7251e7
touch %{buildroot}%{_sysconfdir}/sysconfig/ebtables.broute
f7251e7
f7251e7
# Do not need the sysvinit
f7251e7
rm -rf %{buildroot}%{_initrddir}
871a94d
accea79
# install ebtables-save bash script
f7251e7
rm -f %{buildroot}/sbin/ebtables-save
f7251e7
install %{SOURCE1} %{buildroot}/sbin/ebtables-save
accea79
681c1b6
# move libebtc.so into the ldpath
681c1b6
mv %{buildroot}/%{_lib}/ebtables/libebtc.so %{buildroot}/%{_lib}/
681c1b6
2dc06be
%if 0%{?fedora} > 24
9f6db44
# Remove /etc/ethertypes (now part of setup)
9f6db44
rm -f %{buildroot}%{_sysconfdir}/ethertypes
2dc06be
%endif
9f6db44
871a94d
%post
f7251e7
%systemd_post ebtables.service
a3b0731
/sbin/ldconfig
871a94d
871a94d
%preun
f7251e7
%systemd_preun ebtables.service
871a94d
871a94d
%postun
f7251e7
%systemd_postun_with_restart ebtables.service
a3b0731
/sbin/ldconfig
871a94d
871a94d
%files
871a94d
%doc ChangeLog COPYING THANKS
871a94d
%doc %{_mandir}/man8/ebtables.8*
2dc06be
%if 0%{?fedora} <= 24
2dc06be
%{_sysconfdir}/ethertypes
2dc06be
%endif
f7f9a59
%config(noreplace) %{_sysconfdir}/sysconfig/ebtables-config
f7251e7
%{_unitdir}/ebtables.service
f7251e7
%{_libexecdir}/ebtables
681c1b6
/%{_lib}/libebtc.so
409c505
/%{_lib}/ebtables/
f7f9a59
/sbin/ebtables*
f7f9a59
%ghost %{_sysconfdir}/sysconfig/ebtables.filter
f7f9a59
%ghost %{_sysconfdir}/sysconfig/ebtables.nat
f7f9a59
%ghost %{_sysconfdir}/sysconfig/ebtables.broute
871a94d
871a94d
%changelog
158d794
* Wed Feb 07 2018 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-25
158d794
- Rebuilt for https://fedoraproject.org/wiki/Fedora_28_Mass_Rebuild
158d794
17ee6e5
* Wed Aug 02 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-24
17ee6e5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Binutils_Mass_Rebuild
17ee6e5
ffa4137
* Wed Jul 26 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-23
ffa4137
- Rebuilt for https://fedoraproject.org/wiki/Fedora_27_Mass_Rebuild
ffa4137
b0905b5
* Fri Feb 10 2017 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-22
b0905b5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_26_Mass_Rebuild
b0905b5
9f6db44
* Fri Jul 22 2016 Thomas Woerner <twoerner@redhat.com> - 2.0.10-21
2dc06be
- /etc/ethertypes has been moved into the setup package for F-25+.
2dc06be
  (RHBZ#1329256)
9f6db44
8e67d1c
* Mon May  9 2016 Thomas Woerner <twoerner@redhat.com> - 2.0.10-20
8e67d1c
- add upstream --noflush option patch for ebtables-restore
8e67d1c
0798ce5
* Wed Feb 03 2016 Fedora Release Engineering <releng@fedoraproject.org> - 2.0.10-19
0798ce5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_24_Mass_Rebuild
0798ce5
c3a2b8c
* Mon Jan 18 2016 Tom Callaway <spot@fedoraproject.org> - 2.0.10-18
c3a2b8c
- Move lock file to /run/ebtables.lock (bz 1290327)
c3a2b8c
641e9c8
* Wed Jun 17 2015 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-17
641e9c8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_23_Mass_Rebuild
641e9c8
32da809
* Sat Aug 16 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-16
32da809
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_22_Mass_Rebuild
32da809
062704f
* Tue Jun 24 2014 Tom Callaway <spot@fedoraproject.org> - 2.0.10-15
062704f
- create and own /var/lib/ebtables (bz 1093361)
062704f
300046f
* Sat Jun 07 2014 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-14
300046f
- Rebuilt for https://fedoraproject.org/wiki/Fedora_21_Mass_Rebuild
300046f
81261f9
* Mon Mar 31 2014 Tom Callaway <spot@fedoraproject.org> - 2.0.10-13
81261f9
- use standard optflags and ldflags (bz 1071993)
81261f9
139410d
* Wed Feb 19 2014 Tom Callaway <spot@fedoraproject.org> - 2.0.10-12
139410d
- remove executable bit from systemd service file
139410d
- add RARP type to ethertypes (bz 1060537)
139410d
f7251e7
* Wed Aug 21 2013 Tom Callaway <spot@fedoraproject.org> - 2.0.10-11
f7251e7
- convert to systemd
f7251e7
e25de9b
* Sat Aug 03 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-9
e25de9b
- Rebuilt for https://fedoraproject.org/wiki/Fedora_20_Mass_Rebuild
e25de9b
8e0f4ac
* Thu Mar 21 2013 Tom Callaway <spot@fedoraproject.org> - 2.0.10-8
8e0f4ac
- add audit module
8e0f4ac
424a928
* Wed Feb 13 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-7
424a928
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
424a928
4492fda
* Wed Jul 18 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-6
4492fda
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
4492fda
681c1b6
* Thu Apr  5 2012 Tom Callaway <spot@fedoraproject.org> - 2.0.10-5
681c1b6
- update to 2.0.10-4 (upstream numbering is goofy)
681c1b6
- fix missing symbol issue with extension modules (bz810006)
681c1b6
accea79
* Thu Feb 16 2012 Thomas Woerner <twoerner@redhat.com> - 2.0.10-4
accea79
- replaced ebtables-save perl script by bash script to get rid of the perl 
accea79
  requirement
accea79
56169b8
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.10-3
56169b8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
56169b8
9d9b543
* Thu Aug 11 2011 Tom Callaway <spot@fedoraproject.org> - 2.0.10-2
9d9b543
- update to 2.0.10-2
9d9b543
d85d9ec
* Mon Jul 11 2011 Tom Callaway <spot@fedoraproject.org> - 2.0.10-1
d85d9ec
- update to 2.0.10-1
d85d9ec
b523a50
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.9-6
b523a50
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
b523a50
0758cdf
* Mon Feb 15 2010 Tom "spot" Callaway <tcallawa@redhat.com> - 2.0.9-5
0758cdf
- update to 2.0.9-2
0758cdf
409c505
* Fri Jan 29 2010 Thomas Woerner <twoerner@redhat.com> - 2.0.9-4
409c505
- moved ebtables modules to /lib[64]/ebtables (rhbz#558886)
409c505
409c505
* Fri Jan 15 2010 Thomas Woerner <twoerner@redhat.com> - 2.0.9-3
409c505
- fixed init script to be lsb conform (rhbz#536828)
409c505
- fixed download link according to package review
409c505
9674a09
* Wed Aug 19 2009 Tom "spot" Callaway <tcallawa@redhat.com> - 2.0.9-2
9674a09
- fix source0 url
9674a09
be11fba
* Mon Jul 27 2009 Tom "spot" Callaway <tcallawa@redhat.com> - 2.0.9-1
be11fba
- update to 2.0.9
be11fba
89647de
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.8-7
89647de
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
89647de
1948cfd
* Tue Feb 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 2.0.8-6
1948cfd
- Rebuilt for https://fedoraproject.org/wiki/Fedora_11_Mass_Rebuild
1948cfd
340dd09
* Tue Feb 19 2008 Fedora Release Engineering <rel-eng@fedoraproject.org> - 2.0.8-5
340dd09
- Autorebuild for GCC 4.3
340dd09
7f333f5
* Sun Oct 28 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-4
7f333f5
- bump to 2.0.8-2 from upstream
7f333f5
- keep _libdir/ebtables, even though upstream just moved away from it.
7f333f5
f7f9a59
* Thu Aug 23 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-3
f7f9a59
- use _libdir/ebtables to match upstream RPATH (bugzilla 248865)
f7f9a59
- correct license tag
f7f9a59
- use upstream init script
f7f9a59
- enable build-id
f7f9a59
- use cflags for all compiles
f7f9a59
- be sane with DESTDIR
f7f9a59
8816379
* Mon Jul  9 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-2
8816379
- remove "Fedora Core" reference in spec
8816379
a5becf7
* Mon Jul  2 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-1
a5becf7
- final 2.0.8 release
a5becf7
99b5bbb
* Wed Jan 17 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.8.rc3
99b5bbb
- fix release order
99b5bbb
02b0e90
* Wed Jan 17 2007 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.1.rc3
02b0e90
- bump to rc3
02b0e90
a2fd289
* Thu Oct 05 2006 Christian Iseli <Christian.Iseli@licr.org> 2.0.8-0.7.rc2
a2fd289
 - rebuilt for unwind info generation, broken in gcc-4.1.1-21
a2fd289
ecc18e6
* Mon Sep 18 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.6.rc2
ecc18e6
- fix versioning
ecc18e6
003f904
* Thu Sep 14 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.3.rc2
003f904
- fix bugzilla 206257
003f904
668cf0e
* Tue Sep 12 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.2.rc2
668cf0e
- fix for FC-6
668cf0e
aaac54b
* Mon Apr 24 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.1.rc2
aaac54b
- bump to rc2
aaac54b
fbac009
* Sun Apr  2 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.5.rc1
fbac009
- learn to use "install" correctly. :/
fbac009
a3b0731
* Sun Apr  2 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.4.rc1
a3b0731
- package up the shared libs too
a3b0731
87584c1
* Wed Mar 29 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.3.rc1
87584c1
- use -fPIC
87584c1
18d9d63
* Wed Mar 29 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.2.rc1
18d9d63
- broken tagging
18d9d63
2ffd59a
* Tue Jan 10 2006 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.8-0.1.rc1
2ffd59a
- bump to 2.0.8-rc1
2ffd59a
dd9418e
* Mon Jul  4 2005 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.6-7
dd9418e
- buildsystem error requires artificial release bump
dd9418e
79bd249
* Mon Jul  4 2005 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.6-6
79bd249
- actually touch ghosted files
79bd249
1829901
* Fri Jul  1 2005 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.6-5
1829901
- fix sysv file
1829901
871a94d
* Fri Jul  1 2005 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.6-4
871a94d
- remove INSTALL file
1829901
- add some text to description, correct typos
be11fba
- fix %%postun
1829901
- add PreReqs
be11fba
- add %%ghost config files
871a94d
871a94d
* Tue May 31 2005 Tom "spot" Callaway <tcallawa@redhat.com> 2.0.6-3
871a94d
- reworked for Fedora Extras
871a94d
- add gcc4 fix
871a94d
- move init file into SOURCE1
871a94d
871a94d
* Thu Dec 02 2004 Dag Wieers <dag@wieers.com> - 2.0.6-2
871a94d
- Added patch for gcc 3.4. (Nigel Smith)
871a94d
871a94d
* Tue Apr 27 2004 Dag Wieers <dag@wieers.com> - 2.0.6-2
871a94d
- Cosmetic changes.
871a94d
871a94d
* Tue Apr 27 2004 Dag Wieers <dag@wieers.com> - 2.0.6-1
871a94d
- Initial package. (using DAR)