2013-10-10 15:30:12 +02:00
|
|
|
#
|
|
|
|
# spec file for package open-lldp
|
|
|
|
#
|
2017-02-28 09:25:57 +01:00
|
|
|
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
|
2013-10-10 15:30:12 +02:00
|
|
|
#
|
|
|
|
# All modifications and additions to the file contributed by third parties
|
|
|
|
# remain the property of their copyright owners, unless otherwise agreed
|
|
|
|
# upon. The license for this file, and modifications and additions to the
|
|
|
|
# file, is the same license as for the pristine package itself (unless the
|
|
|
|
# license for the pristine package is not an Open Source License, in which
|
|
|
|
# case the license is the MIT License). An "Open Source License" is a
|
|
|
|
# license that conforms to the Open Source Definition (Version 1.9)
|
|
|
|
# published by the Open Source Initiative.
|
|
|
|
|
|
|
|
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
%define libname liblldp_clif1
|
|
|
|
Name: open-lldp
|
|
|
|
Summary: Link Layer Discovery Protocol (LLDP) Agent
|
|
|
|
License: GPL-2.0
|
|
|
|
Group: System/Daemons
|
2015-08-03 16:18:29 +02:00
|
|
|
Version: 1.0.1
|
2013-10-10 15:30:12 +02:00
|
|
|
Release: 0
|
|
|
|
BuildRequires: bison
|
|
|
|
BuildRequires: flex
|
|
|
|
BuildRequires: libconfig-devel
|
2014-05-19 23:35:06 +02:00
|
|
|
BuildRequires: libnl3-devel
|
2013-10-10 15:30:12 +02:00
|
|
|
BuildRequires: libtool
|
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: readline-devel
|
|
|
|
Url: http://open-lldp.org/
|
2017-02-28 12:50:31 +01:00
|
|
|
Source: %{name}-%{version}.tar.gz
|
|
|
|
#Source: http://ftp-osl.osuosl.org/pub/%{name}/%{name}-%{version}.tar.gz
|
2014-03-27 10:30:31 +01:00
|
|
|
Patch0: %{name}-git-update.patch.bz2
|
2015-08-03 16:18:29 +02:00
|
|
|
Patch1: 0001-l2_linux_packet-correctly-process-return-value-of-ge.patch
|
|
|
|
Patch2: 0002-lldpad-Only-set-Tx-adminStatus-if-interface-is-not-m.patch
|
2015-04-08 12:28:44 +02:00
|
|
|
Patch3: open-lldp-gcc5.patch
|
2013-10-10 15:30:12 +02:00
|
|
|
BuildRoot: %{_tmppath}/%{name}-%{version}-build
|
|
|
|
Provides: dcbd = %{version}
|
|
|
|
Obsoletes: dcbd < %{version}
|
|
|
|
Provides: lldpad = %{version}
|
|
|
|
Obsoletes: lldpad < %{version}
|
|
|
|
BuildRequires: systemd
|
|
|
|
%systemd_requires
|
|
|
|
|
|
|
|
%description
|
|
|
|
This package contains the Link Layer Discovery Protocol (LLDP) Agent
|
|
|
|
with Data Center Bridging (DCB) for Intel(R) Network Connections
|
|
|
|
'lldpad' plus the configuration tools 'dcbtool' and 'lldptool'.
|
|
|
|
|
|
|
|
%package -n %{libname}
|
|
|
|
Summary: Link Layer Discovery Protocol (LLDP) libraries
|
|
|
|
Group: System/Libraries
|
|
|
|
|
|
|
|
%description -n %{libname}
|
|
|
|
This package contains the Link Layer Discovery Protocol (LLDP) libraries
|
|
|
|
|
|
|
|
%package devel
|
|
|
|
Summary: Link Layer Discovery Protocol (LLDP) Agent
|
|
|
|
Group: Development/Libraries/C and C++
|
|
|
|
Requires: %{libname} = %{version}
|
|
|
|
Requires: %{name} = %{version}
|
2013-10-10 17:14:38 +02:00
|
|
|
Provides: dcbd-devel = %{version}
|
|
|
|
Obsoletes: dcbd-devel < %{version}
|
|
|
|
Provides: lldpad-devel = %{version}
|
|
|
|
Obsoletes: lldpad-devel < %{version}
|
2013-10-10 15:30:12 +02:00
|
|
|
|
|
|
|
%description devel
|
|
|
|
This package contains the Link Layer Discovery Protocol (LLDP) Agent
|
|
|
|
with Data Center Bridging (DCB) for Intel(R) Network Connections
|
|
|
|
'lldpad' plus the configuration tools 'dcbtool' and 'lldptool'.
|
|
|
|
|
|
|
|
%prep
|
2013-10-11 09:15:11 +02:00
|
|
|
%setup
|
2013-10-10 15:30:12 +02:00
|
|
|
%patch0 -p1
|
2014-05-19 23:35:06 +02:00
|
|
|
%patch1 -p1
|
|
|
|
%patch2 -p1
|
2015-04-08 12:28:44 +02:00
|
|
|
%patch3 -p1
|
2013-10-10 15:30:12 +02:00
|
|
|
|
|
|
|
%build
|
|
|
|
autoreconf -vi
|
|
|
|
%configure \
|
|
|
|
--disable-static
|
|
|
|
make %{?_smp_mflags}
|
|
|
|
|
|
|
|
%check
|
|
|
|
make check %{?_smp_mflags}
|
|
|
|
|
|
|
|
%install
|
|
|
|
mkdir -p %{buildroot}/var/lib/lldpad
|
|
|
|
%makeinstall
|
|
|
|
# remove la archives
|
|
|
|
rm -rf %{buildroot}/%{_libdir}/*.la
|
2014-03-27 10:30:31 +01:00
|
|
|
ln -s service %{buildroot}%{_sbindir}/rclldpad
|
2013-10-10 15:30:12 +02:00
|
|
|
|
|
|
|
%post
|
2017-02-28 09:25:57 +01:00
|
|
|
%{fillup_only -n -i lldpad}
|
2013-10-10 15:30:12 +02:00
|
|
|
%service_add_post lldpad.service
|
|
|
|
|
2014-06-05 17:51:14 +02:00
|
|
|
%pre
|
|
|
|
%service_add_pre lldpad.service
|
|
|
|
|
2013-10-10 15:30:12 +02:00
|
|
|
%preun
|
|
|
|
%service_del_preun lldpad.service
|
|
|
|
|
|
|
|
%postun
|
2014-06-05 17:51:14 +02:00
|
|
|
%service_del_postun lldpad.service
|
2013-10-10 15:30:12 +02:00
|
|
|
|
|
|
|
%post -n %libname -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%postun -n %libname -p /sbin/ldconfig
|
|
|
|
|
|
|
|
%files
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%doc COPYING README ChangeLog
|
|
|
|
%dir /var/lib/lldpad
|
|
|
|
%{_unitdir}/*
|
|
|
|
%{_sbindir}/*
|
2015-08-03 16:18:29 +02:00
|
|
|
%{_mandir}/man3/*
|
2013-10-10 15:30:12 +02:00
|
|
|
%{_mandir}/man8/*
|
|
|
|
%config /etc/bash_completion.d/*
|
|
|
|
|
|
|
|
%files -n %libname
|
|
|
|
%defattr(-,root,root)
|
|
|
|
%{_libdir}/*.so.*
|
|
|
|
|
|
|
|
%files devel
|
|
|
|
%defattr(-,root,root,-)
|
|
|
|
%{_includedir}/*
|
|
|
|
%{_libdir}/pkgconfig/*.pc
|
|
|
|
%{_libdir}/*.so
|
|
|
|
|
|
|
|
%changelog
|