286 lines
10 KiB
RPMSpec
286 lines
10 KiB
RPMSpec
# https://fedoraproject.org/wiki/Packaging:Guidelines#Compiler_flags
|
|
%define _hardened_build 1
|
|
|
|
Name: lldpad
|
|
Version: 0.9.43
|
|
Release: 4%{?dist}
|
|
Summary: Intel LLDP Agent
|
|
Group: System Environment/Daemons
|
|
License: GPLv2
|
|
URL: http://open-lldp.org/
|
|
Source0: %{name}-%{version}.tar.gz
|
|
Patch0: lldpad-0.9.41-make.patch
|
|
Patch1: lldpad-0.9.41-lldptool-invalid-pointer.patch
|
|
# Patchwork
|
|
Patch50: lldpad-0.9.43-vdp-must-be-enabled-on-interface.patch
|
|
# Upstream, 0.9.43+
|
|
Patch100: lldpad-0.9.43-add-man-page-for-EVB-TLV.patch
|
|
Patch101: lldpad-0.9.43-add-man-page-for-VDP.patch
|
|
Patch102: lldpad-0.9.43-add-some-files-in-include-linux-to-inst_SOURCES.patch
|
|
Patch103: lldpad-0.9.43-lldpad-Add-EVB-and-VDP-man-pages-to-install-path.patch
|
|
Patch104: lldpad-0.9.43-lldpad-802.1Qaz-PFC-TLV-incorrectly-sets-willing-cap.patch
|
|
Patch105: lldpad-0.9.43-lldpad-Add-ports-even-w-out-link-at-init-time.patch
|
|
Patch106: lldpad-0.9.43-lldpad-remove-app-data-on-CEE-unregister.patch
|
|
Patch107: lldpad-0.9.43-lldpad-remove-unused-exported-DCBX-routines.patch
|
|
Patch108: lldpad-0.9.43-Create-man-page-for-MED-usage.patch
|
|
Patch109: lldpad-0.9.43-lldpad-802.1Qaz-resolve-incorrect-tcbw-memcpy.patch
|
|
Patch110: lldpad-0.9.43-dcbtool-return-different-error-codes-for-invalid-dev.patch
|
|
Patch111: lldpad-0.9.43-lldpad-802.1Qaz-make-ETS-CFG-willing-yes-no-values-v.patch
|
|
Patch112: lldpad-0.9.43-lldpad-use-is_valid_lldp_device-in-scan-path.patch
|
|
Patch113: lldpad-0.9.43-lldpad-resolve-segfault-with-ECP-and-bonding.patch
|
|
Patch114: lldpad-0.9.43-lldpad-dcbx-mode-needs-to-be-set-before-set_state-cm.patch
|
|
Patch115: lldpad-0.9.43-lldpad-fix-compile-warnings-in-802.1Qaz-debug-code.patch
|
|
Patch116: lldpad-0.9.43-lldpad-Do-not-enable-CEE-mode-if-explicitly-disabled.patch
|
|
Patch117: lldpad-0.9.43-lldapd-802.1Qaz-add-output-buffer-response-to-set-pf.patch
|
|
Patch118: lldpad-0.9.43-lldpad-ETS-add-another-example-to-man-page.patch
|
|
Patch119: lldpad-0.9.43-lldptool-better-TLV_ID-validation.patch
|
|
Patch120: lldpad-0.9.43-This-patch-fixes-a-warning-issued-when-building-the-.patch
|
|
Patch121: lldpad-0.9.43-lldpad-Avoid-possible-resource-leak-in-get_bcn.patch
|
|
Patch122: lldpad-0.9.43-Avoid-possible-resource-leaks.patch
|
|
Patch123: lldpad-0.9.43-lldpad-Fix-logging-to-no-longer-use-message-IDs.patch
|
|
Patch124: lldpad-0.9.43-lldpad-Fix-error-path-in-save_dcbx_version.patch
|
|
Patch125: lldpad-0.9.43-bugfix-to-print-all-profiles.patch
|
|
Patch126: lldpad-0.9.43-prevent-crash-on-invalid-response-code.patch
|
|
Patch127: lldpad-0.9.43-bugfix-go-to-VSI_EXIT-immediately-on-neg-response.patch
|
|
Patch128: lldpad-0.9.43-some-minor-bugfixes.patch
|
|
Requires: kernel >= 2.6.32
|
|
BuildRequires: systemd-units
|
|
BuildRequires: libconfig-devel >= 1.3.2 kernel-headers >= 2.6.32
|
|
BuildRequires: flex >= 2.5.33
|
|
BuildRequires: automake autoconf libtool
|
|
BuildRequires: libnl-devel libnl
|
|
Requires(post): systemd-units
|
|
Requires(preun): systemd-units
|
|
Requires(postun): systemd-units
|
|
Provides: dcbd = %{version}-%{release}
|
|
Obsoletes: dcbd < 0.9.26
|
|
|
|
%description
|
|
This package contains the Linux user space daemon and configuration tool for
|
|
Intel LLDP Agent with Enhanced Ethernet support for the Data Center.
|
|
|
|
%package devel
|
|
Summary: Development files for %{name}
|
|
Group: Development/Libraries
|
|
Requires: %{name} = %{version}-%{release}
|
|
Provides: dcbd-devel = %{version}-%{release}
|
|
Obsoletes: dcbd-devel < 0.9.26
|
|
|
|
%description devel
|
|
The %{name}-devel package contains header files for developing applications
|
|
that use %{name}.
|
|
|
|
%prep
|
|
%setup -q -n open-lldp
|
|
# Upstream patches
|
|
%patch100 -p1
|
|
%patch101 -p1
|
|
%patch102 -p1
|
|
%patch103 -p1
|
|
%patch104 -p1
|
|
%patch105 -p1
|
|
%patch106 -p1
|
|
%patch107 -p1
|
|
%patch108 -p1
|
|
%patch109 -p1
|
|
%patch110 -p1
|
|
%patch111 -p1
|
|
%patch112 -p1
|
|
%patch113 -p1
|
|
%patch114 -p1
|
|
%patch115 -p1
|
|
%patch116 -p1
|
|
%patch117 -p1
|
|
%patch118 -p1
|
|
%patch119 -p1
|
|
%patch120 -p1
|
|
%patch121 -p1
|
|
%patch122 -p1
|
|
%patch123 -p1
|
|
%patch124 -p1
|
|
%patch125 -p1
|
|
%patch126 -p1
|
|
%patch127 -p1
|
|
%patch128 -p1
|
|
# Submitted (not yet accepted upstream) patches
|
|
%patch50 -p1
|
|
# Fedora patches
|
|
%patch0 -p1 -b .make
|
|
%patch1 -p1 -b .invalid-pointer
|
|
|
|
%build
|
|
./bootstrap.sh
|
|
%configure
|
|
make %{?_smp_mflags}
|
|
|
|
%install
|
|
make install DESTDIR=%{buildroot}
|
|
rm -f %{buildroot}%{_mandir}/man8/dcbd.8
|
|
mkdir -p %{buildroot}%{_unitdir}
|
|
install -m644 %{name}.service %{buildroot}%{_unitdir}
|
|
rm -rf %{buildroot}/etc/init.d
|
|
|
|
%post
|
|
if [ $1 -eq 1 ]; then
|
|
systemctl daemon-reload >/dev/null 2>&1 || :
|
|
systemctl enable %{name}.service >/dev/null 2>&1 || :
|
|
fi
|
|
|
|
%preun
|
|
if [ $1 -eq 0 ]; then
|
|
systemctl --no-reload disable %{name}.service >/dev/null 2>&1 || :
|
|
systemctl stop %{name}.service >/dev/null 2>&1 || :
|
|
fi
|
|
|
|
%postun
|
|
if [ $1 -eq 1 ]; then
|
|
systemctl try-restart %{name}.service >/dev/null 2>&1 || :
|
|
fi
|
|
|
|
%post devel
|
|
## provide legacy support for apps that use the old dcbd interface.
|
|
if [ ! -e %{_includedir}/dcbd ]; then
|
|
ln -T -s %{_includedir}/lldpad %{_includedir}/dcbd
|
|
fi
|
|
if [ ! -e %{_includedir}/dcbd/clif_cmds.h ]; then
|
|
ln -T -s %{_includedir}/lldpad/lldp_dcbx_cmds.h %{_includedir}/dcbd/clif_cmds.h
|
|
fi
|
|
|
|
%preun devel
|
|
if [ -e %{_includedir}/dcbd/clif_cmds.h ]; then
|
|
rm -f %{_includedir}/dcbd/clif_cmds.h
|
|
fi
|
|
if [ -e %{_includedir}/dcbd ]; then
|
|
rm -f %{_includedir}/dcbd
|
|
fi
|
|
|
|
%files
|
|
%doc COPYING README ChangeLog
|
|
%{_sbindir}/*
|
|
%dir %{_sharedstatedir}/%{name}
|
|
%{_unitdir}/%{name}.service
|
|
%{_mandir}/man8/*
|
|
|
|
%files devel
|
|
%{_includedir}/*
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
|
%changelog
|
|
* Fri Sep 23 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-4
|
|
- Enable hardened build
|
|
|
|
* Tue Sep 13 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-3
|
|
- Mute systemd output (#737897)
|
|
|
|
* Tue Aug 30 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-2
|
|
- Apply various upstream 0.9.43 bugfixes
|
|
- Include not yet accepted Jens Osterkamp's patch to fix bug #720080
|
|
- Whitespace cleanup, phew
|
|
|
|
* Thu Jul 07 2011 Petr Sabata <contyk@redhat.com> - 0.9.43-1
|
|
- 0.9.43 bump
|
|
- Drop the the clean exit patch and our unit file, both are now included upstream
|
|
|
|
* Tue Jun 21 2011 Petr Sabata <contyk@redhat.com> - 0.9.42-2
|
|
- Introduce systemd unit file, drop SysV support
|
|
- Call systemctl instead of service and chkconfig
|
|
- Enable the service only on new installation (%post)
|
|
- Clean exit patch
|
|
|
|
* Mon Jun 13 2011 Petr Sabata <contyk@redhat.com> - 0.9.42-1
|
|
- 0.9.42 bump (massive patches cleanup)
|
|
- Remove obsolete defattr
|
|
- Remove COPYING and README from devel subpackage
|
|
|
|
* Wed May 4 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-3
|
|
- Fix the frequent, power consuming lldpad wake-ups (rhbz#701943)
|
|
|
|
* Thu Apr 21 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-2
|
|
- Bring in upstream 802.1Qbg bugfixes
|
|
|
|
* Thu Feb 10 2011 Petr Sabata <psabata@redhat.com> - 0.9.41-1
|
|
- 0.9.41 bump
|
|
- New BR: autotools, flex
|
|
- Buildroot garbage removed
|
|
- Devel post and preun scriptlets sanitized
|
|
|
|
* Tue Feb 08 2011 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.38-2
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_15_Mass_Rebuild
|
|
|
|
* Mon Jun 28 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.38-1
|
|
- rebased to 0.9.38 (various enhancements and bugfixes, see
|
|
lldpad-0.9.38-relnotes.txt on http://e1000.sf.net for complete list)
|
|
|
|
* Mon May 10 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.32-2
|
|
- rebuild to match new libconfig
|
|
|
|
* Mon Apr 12 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.32-1
|
|
- rebased to 0.9.32 (various enhancements and bugfixes, see
|
|
lldpad-0.9.32-relnotes.txt on http://e1000.sf.net for complete list)
|
|
|
|
* Thu Mar 25 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.29-2
|
|
- added Provides and Obsoletes tags to devel subpackage
|
|
|
|
* Mon Mar 15 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.29-1
|
|
- updated package to 0.9.29, improved compatibility with fcoe-utils
|
|
|
|
* Fri Feb 26 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.26-2
|
|
- updated spec file and LSB init script patch for re-review
|
|
(#568641)
|
|
|
|
* Thu Feb 25 2010 Jan Zeleny <jzeleny@redhat.com> - 0.9.26-1
|
|
- rebased to 0.9.26
|
|
- package renamed to lldpad
|
|
- enahanced functionality (LLDP supported as well as DCBX)
|
|
|
|
* Fri Nov 13 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.19-2
|
|
- init script patch adding LSB compliance
|
|
|
|
* Thu Oct 08 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.19-1
|
|
- update to new upstream version
|
|
|
|
* Mon Oct 05 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-5
|
|
- replaced the last patch, which was not fully functional, with
|
|
the new one
|
|
|
|
* Wed Sep 09 2009 Karsten Hopp <karsten@redhat.com> 0.9.15-4
|
|
- buildrequire libconfig-devel >= 1.3.2, it doesn't build with 1.3.1 due to
|
|
the different config_lookup_string api
|
|
|
|
* Thu Aug 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-3
|
|
- update of config_lookup_string() function calls
|
|
|
|
* Thu Aug 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-2
|
|
- rebuild in order to match new libconfig
|
|
|
|
* Mon Aug 17 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.15-1
|
|
- rebase to 0.9.15
|
|
|
|
* Fri Jul 24 2009 Fedora Release Engineering <rel-eng@lists.fedoraproject.org> - 0.9.7-5
|
|
- Rebuilt for https://fedoraproject.org/wiki/Fedora_12_Mass_Rebuild
|
|
|
|
* Fri Mar 20 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-4
|
|
- updated scriptlets in spec file to follow the rules
|
|
|
|
* Wed Mar 11 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-3
|
|
- added devel files again to support fcoe-utils package
|
|
- added kernel >= 2.6.29 to Requires, deleted dcbnl.h, since it is
|
|
aviable in kernel 2.6.29-rc7
|
|
- changed config dir from /etc/sysconfig/dcbd to /etc/dcbd
|
|
- updated init script: added mandatory Short description tag,
|
|
deleted default runlevels, which should start the script
|
|
|
|
* Tue Mar 10 2009 Jan Zeleny <jzeleny@redhat.com> - 0.9.7-2
|
|
- added patch to enable usage of libconfig shared in system
|
|
- removed devel part of package
|
|
|
|
* Mon Mar 2 2009 Chris Leech <christopher.leech@intel.com> - 0.9.7-1
|
|
- Updated to 0.9.7
|
|
- Added a private copy of dcbnl.h until kernel-headers includes it.
|
|
Export patch is making it's way to the upstream kernel via net-2.6,
|
|
expected in 2.6.29-rc7
|
|
|
|
* Thu Feb 26 2009 Chris Leech <christopher.leech@intel.com> - 0.9.5-1
|
|
- initial RPM packaging
|
|
|