Blame SPECS/lldpad.spec

2de5c2
# https://fedoraproject.org/wiki/Packaging:Guidelines#Compiler_flags
2de5c2
%define _hardened_build 1
2de5c2
2de5c2
Name:               lldpad
2de5c2
Version:            0.9.46
44fc57
Release:            10%{?dist}
2de5c2
Summary:            Intel LLDP Agent
2de5c2
Group:              System Environment/Daemons
2de5c2
License:            GPLv2
2de5c2
URL:                http://open-lldp.org/
2de5c2
Source0:            %{name}-%{version}.tar.gz
44fc57
Patch0:             %{name}-%{version}-123-g48a5f38.patch
44fc57
Patch1:             %{name}-0.9.46-Ignore-supplied-PG-configuration-if-PG-is-being-disabled.patch
2de5c2
Requires:           kernel >= 2.6.32
2de5c2
BuildRequires:      automake autoconf libtool
2de5c2
BuildRequires:      flex >= 2.5.33
2de5c2
BuildRequires:      kernel-headers >= 2.6.32
2de5c2
BuildRequires:      libconfig-devel >= 1.3.2
44fc57
BuildRequires:      libnl3-devel
2de5c2
BuildRequires:      readline-devel
2de5c2
BuildRequires:      systemd
2de5c2
Requires:           readline
2de5c2
Requires(post):     systemd
2de5c2
Requires(preun):    systemd
2de5c2
Requires(postun):   systemd
2de5c2
Provides:           dcbd = %{version}-%{release}
2de5c2
Obsoletes:          dcbd < 0.9.26
2de5c2
2de5c2
%description
2de5c2
This package contains the Linux user space daemon and configuration tool for
2de5c2
Intel LLDP Agent with Enhanced Ethernet support for the Data Center.
2de5c2
2de5c2
%package            devel
2de5c2
Summary:            Development files for %{name}
2de5c2
Group:              Development/Libraries
2de5c2
Requires:           %{name}%{?_isa} = %{version}-%{release}
2de5c2
Provides:           dcbd-devel = %{version}-%{release}
2de5c2
Obsoletes:          dcbd-devel < 0.9.26
2de5c2
2de5c2
%description devel
2de5c2
The %{name}-devel package contains header files for developing applications
2de5c2
that use %{name}.
2de5c2
2de5c2
%prep
2de5c2
%setup -q
2de5c2
%patch0 -p1
3e0fe9
%patch1 -p1
2de5c2
2de5c2
%build
2de5c2
./bootstrap.sh
2de5c2
%configure --disable-static
2de5c2
# fix the hardened build flags
2de5c2
sed -i -e 's! \\\$compiler_flags !&\\\$CFLAGS \\\$LDFLAGS !' libtool
2de5c2
make %{?_smp_mflags}
2de5c2
2de5c2
%install
2de5c2
make install DESTDIR=%{buildroot}
2de5c2
mkdir -p %{buildroot}%{_sharedstatedir}/%{name}
2de5c2
rm -f %{buildroot}%{_libdir}/liblldp_clif.la
2de5c2
2de5c2
%post
2de5c2
/sbin/ldconfig
44fc57
%systemd_post %{name}.service %{name}.socket
2de5c2
2de5c2
%preun
44fc57
%systemd_preun %{name}.service %{name}.socket
2de5c2
2de5c2
%postun
2de5c2
/sbin/ldconfig
44fc57
%systemd_postun_with_restart %{name}.service %{name}.socket
2de5c2
2de5c2
%post devel
2de5c2
## provide legacy support for apps that use the old dcbd interface.
2de5c2
if [ ! -e %{_includedir}/dcbd ]; then
2de5c2
    ln -T -s %{_includedir}/lldpad %{_includedir}/dcbd
2de5c2
fi
2de5c2
if [ ! -e %{_includedir}/dcbd/clif_cmds.h ]; then
2de5c2
    ln -T -s %{_includedir}/lldpad/lldp_dcbx_cmds.h %{_includedir}/dcbd/clif_cmds.h
2de5c2
fi
2de5c2
2de5c2
%preun devel
2de5c2
if [ -e %{_includedir}/dcbd/clif_cmds.h ]; then
2de5c2
    rm -f %{_includedir}/dcbd/clif_cmds.h
2de5c2
fi
2de5c2
if [ -e %{_includedir}/dcbd ]; then
2de5c2
    rm -f %{_includedir}/dcbd
2de5c2
fi
2de5c2
2de5c2
%files
2de5c2
%doc COPYING README ChangeLog
2de5c2
%{_sbindir}/*
2de5c2
%{_libdir}/liblldp_clif.so.*
2de5c2
%dir %{_sharedstatedir}/%{name}
2de5c2
%{_unitdir}/%{name}.service
44fc57
%{_unitdir}/%{name}.socket
2de5c2
%dir %{_sysconfdir}/bash_completion.d/
2de5c2
%{_sysconfdir}/bash_completion.d/*
2de5c2
%{_mandir}/man8/*
2de5c2
2de5c2
%files devel
2de5c2
%{_includedir}/*
2de5c2
%{_libdir}/pkgconfig/*.pc
2de5c2
%{_libdir}/liblldp_clif.so
2de5c2
2de5c2
%changelog
44fc57
* Tue Oct 21 2014 Chris Leech <cleech@redhat.com> - 0.9.46-10
44fc57
- Sync with upstream v0.9.46-123-g48a5f38 (#1087096)
44fc57
475e44
* Fri Jun 27 2014 Chris Leech <cleech@redhat.com> - 0.9.46-9
475e44
- Fix IEEE mode DCBX (#1102886)
475e44
3e0fe9
* Wed Mar 19 2014 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-8
3e0fe9
- Ignore supplied PG configuration if PG is being disabled (#1067261)
3e0fe9
3e0fe9
* Tue Mar 18 2014 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-7
3e0fe9
- Migrate properly with VEPA (#1070725)
3e0fe9
3e0fe9
* Fri Jan 24 2014 Daniel Mach <dmach@redhat.com> - 0.9.46-6
3e0fe9
- Mass rebuild 2014-01-24
3e0fe9
3e0fe9
* Fri Dec 27 2013 Daniel Mach <dmach@redhat.com> - 0.9.46-5
3e0fe9
- Mass rebuild 2013-12-27
3e0fe9
2de5c2
* Fri Nov 08 2013 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-4
2de5c2
- Support multiple virtual machines again (#1020625)
2de5c2
2de5c2
* Wed Jul 31 2013 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-3
2de5c2
- Require 'systemd' instead of 'systemd-units'
2de5c2
2de5c2
* Tue Jul 02 2013 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-2
2de5c2
- Fix the hardened build flags
2de5c2
2de5c2
* Tue Jun 04 2013 Petr Ĺ abata <contyk@redhat.com> - 0.9.46-1
2de5c2
- 0.9.46 bump
2de5c2
- 802.1Qaz fixes to enable support on not CEE DCBX-enabled hardware
2de5c2
- 802.1Qbg EVB module support
2de5c2
- lldpad now supports bonded interfaces
2de5c2
2de5c2
* Tue Mar 05 2013 Petr Ĺ abata <contyk@redhat.com> - 0.9.45-5
2de5c2
- Fix build by patching the sizeof() call in lldp_8021qaz_cmds.c
2de5c2
2de5c2
* Thu Feb 14 2013 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.45-4
2de5c2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_19_Mass_Rebuild
2de5c2
2de5c2
* Tue Aug 28 2012 Petr Ĺ abata <contyk@redhat.com> - 0.9.45-3
2de5c2
- Migrate to systemd scriptlets (#850192)
2de5c2
2de5c2
* Thu Aug 23 2012 Petr Ĺ abata <contyk@redhat.com> - 0.9.45-2
2de5c2
- Fix displaying of the Management Address TLV (327ef662)
2de5c2
2de5c2
* Wed Aug 15 2012 Petr Ĺ abata <contyk@redhat.com> - 0.9.45-1
2de5c2
- 0.9.45 bump
2de5c2
- Provide bash-completion and the new clif library
2de5c2
2de5c2
* Thu Jul 19 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.44-2
2de5c2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_18_Mass_Rebuild
2de5c2
2de5c2
* Fri Jan 27 2012 Petr Ĺ abata <contyk@redhat.com> - 0.9.44-1
2de5c2
- 0.9.44 bump, patches cleanup
2de5c2
- Correct dependencies a bit
2de5c2
- Require dlopen()'d readline
2de5c2
2de5c2
* Fri Jan 13 2012 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.43-6
2de5c2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_17_Mass_Rebuild
2de5c2
2de5c2
* Thu Oct 06 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-5
2de5c2
- Do not enable lldpad by default (#701999)
2de5c2
2de5c2
* Fri Sep 23 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-4
2de5c2
- Enable hardened build
2de5c2
2de5c2
* Tue Sep 13 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-3
2de5c2
- Mute systemd output (#737897)
2de5c2
2de5c2
* Tue Aug 30 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-2
2de5c2
- Apply various upstream 0.9.43 bugfixes
2de5c2
- Include not yet accepted Jens Osterkamp's patch to fix bug #720080
2de5c2
- Whitespace cleanup, phew
2de5c2
2de5c2
* Thu Jul 07 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-1
2de5c2
- 0.9.43 bump
2de5c2
- Drop the the clean exit patch and our unit file, both are now included upstream
2de5c2
2de5c2
* Tue Jun 21 2011 Petr Sabata <contyk@redhat.com> - 0.9.42-2
2de5c2
- Introduce systemd unit file, drop SysV support
2de5c2
- Call systemctl instead of service and chkconfig
2de5c2
- Enable the service only on new installation (post)
2de5c2
- Clean exit patch
2de5c2
2de5c2
* Mon Jun 13 2011 Petr Sabata <contyk@redhat.com> - 0.9.42-1
2de5c2
- 0.9.42 bump (massive patches cleanup)
2de5c2
- Remove obsolete defattr
2de5c2
- Remove COPYING and README from devel subpackage
2de5c2
2de5c2
* Wed May  4 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-3
2de5c2
- Fix the frequent, power consuming lldpad wake-ups (rhbz#701943)
2de5c2
2de5c2
* Thu Apr 21 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-2
2de5c2
- Bring in upstream 802.1Qbg bugfixes
2de5c2
2de5c2
* Thu Feb 10 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-1
2de5c2
- 0.9.41 bump
2de5c2
- New BR: autotools, flex
2de5c2
- Buildroot garbage removed
2de5c2
- Devel post and preun scriptlets sanitized
2de5c2
2de5c2
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.38-2
2de5c2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
2de5c2
2de5c2
* Mon Jun 28 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.38-1
2de5c2
- rebased to 0.9.38 (various enhancements and bugfixes, see 
2de5c2
  lldpad-0.9.38-relnotes.txt on http://e1000.sf.net for complete list)
2de5c2
2de5c2
* Mon May 10 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.32-2
2de5c2
- rebuild to match new libconfig
2de5c2
2de5c2
* Mon Apr 12 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.32-1
2de5c2
- rebased to 0.9.32 (various enhancements and bugfixes, see 
2de5c2
  lldpad-0.9.32-relnotes.txt on http://e1000.sf.net for complete list)
2de5c2
2de5c2
* Thu Mar 25 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.29-2
2de5c2
- added Provides and Obsoletes tags to devel subpackage
2de5c2
2de5c2
* Mon Mar 15 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.29-1
2de5c2
- updated package to 0.9.29, improved compatibility with fcoe-utils
2de5c2
2de5c2
* Fri Feb 26 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.26-2
2de5c2
- updated spec file and LSB init script patch for re-review
2de5c2
  (#568641)
2de5c2
2de5c2
* Thu Feb 25 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.26-1
2de5c2
- rebased to 0.9.26
2de5c2
- package renamed to lldpad
2de5c2
- enahanced functionality (LLDP supported as well as DCBX)
2de5c2
2de5c2
* Fri Nov 13 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.19-2
2de5c2
- init script patch adding LSB compliance
2de5c2
2de5c2
* Thu Oct 08 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.19-1
2de5c2
- update to new upstream version
2de5c2
2de5c2
* Mon Oct 05 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-5
2de5c2
- replaced the last patch, which was not fully functional, with
2de5c2
  the new one
2de5c2
2de5c2
* Wed Sep 09 2009 Karsten Hopp <karsten@redhat.com> 0.9.15-4
2de5c2
- buildrequire libconfig-devel >= 1.3.2, it doesn't build with 1.3.1 due to
2de5c2
  the different config_lookup_string api
2de5c2
2de5c2
* Thu Aug 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-3
2de5c2
- update of config_lookup_string() function calls
2de5c2
2de5c2
* Thu Aug 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-2
2de5c2
- rebuild in order to match new libconfig
2de5c2
2de5c2
* Mon Aug 17 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-1
2de5c2
- rebase to 0.9.15
2de5c2
2de5c2
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.7-5
2de5c2
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
2de5c2
2de5c2
* Fri Mar 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-4
2de5c2
- updated scriptlets in spec file to follow the rules
2de5c2
2de5c2
* Wed Mar 11 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-3
2de5c2
- added devel files again to support fcoe-utils package
2de5c2
- added kernel >= 2.6.29 to Requires, deleted dcbnl.h, since it is
2de5c2
  aviable in kernel 2.6.29-rc7
2de5c2
- changed config dir from /etc/sysconfig/dcbd to /etc/dcbd
2de5c2
- updated init script: added mandatory Short description tag,
2de5c2
  deleted default runlevels, which should start the script
2de5c2
2de5c2
* Tue Mar 10 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-2
2de5c2
- added patch to enable usage of libconfig shared in system
2de5c2
- removed devel part of package
2de5c2
2de5c2
* Mon Mar 2 2009 Chris Leech <christopher.leech@intel.com> - 0.9.7-1
2de5c2
- Updated to 0.9.7
2de5c2
- Added a private copy of dcbnl.h until kernel-headers includes it.
2de5c2
  Export patch is making it's way to the upstream kernel via net-2.6,
2de5c2
  expected in 2.6.29-rc7
2de5c2
2de5c2
* Thu Feb 26 2009 Chris Leech <christopher.leech@intel.com> - 0.9.5-1
2de5c2
- initial RPM packaging