File ipfixcol.spec of Package ipfixcol
#
# spec file for package ipfixcol
#
# Copyright (c) 2016, Martin Hauke <mardnh@gmx.de>
#
# 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/
#
Name: ipfixcol
Version: 0.0.0.git1461821550.1c037a2
Release: 0
Summary: An IPFIX (RFC 7011) collector
License: BSD-2-Clause and GPL-2.0+ and MIT
Group: Productivity/Networking/Diagnostic
Url: https://github.com/CESNET/ipfixcol
Source: %{name}-%{version}.tar.xz
Patch0: ipfixcol-fix-compile-warning.diff
BuildRequires: autoconf
BuildRequires: automake
BuildRequires: libtool
BuildRequires: flex
BuildRequires: bison
BuildRequires: gcc-c++
BuildRequires: pkg-config
BuildRequires: pkgconfig(libxml-2.0)
BuildRequires: libopenssl-devel
BuildRequires: lksctp-tools-devel
# for git-version-gen
BuildRequires: git-core
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%description
IPFIXcol is an implementation of an IPFIX (RFC 7011) collector.
%package devel
Summary: Development files for the ipfixcol library
License: BSD-2-Clause and GPL-2.0+ and MIT
Group: Development/Libraries/C and C++
Requires: %{name} = %{version}
%description devel
IPFIXcol is an implementation of an IPFIX (RFC 7011) collector.
This subpackage contains libraries and header files for developing
applications that want to make use of ipfixcol.
%prep
%setup -q
%patch0 -p1
# fix plugin path
find . -name "Makefile.am" | xargs sed -i 's/pluginsdir = $(pkgdatadir)/pluginsdir = $(pkglibdir)/g'
%build
cd base
autoreconf -fiv
%configure \
--disable-doc \
--with-distro=suse
make %{?_smp_mflags}
%install
cd base
%makeinstall
find %{buildroot} -type f -name "*.la" -delete -print
# _sysconfdir seems a better place for this file
mv %{buildroot}/%{_datadir}/ipfixcol/ipfixviewer_startup.xml %{buildroot}/%{_sysconfdir}/ipfixcol/ipfixviewer_startup.xml
%check
#cd base
#make test
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%files
%defattr(-,root,root)
%doc base/{changelog.md,README.md}
%{_bindir}/ipfixcol
%{_bindir}/ipfixconf
%{_bindir}/ipfixsend
%{_bindir}/ipfixviewer
%dir %{_sysconfdir}/ipfixcol/
%config %{_sysconfdir}/ipfixcol/internalcfg.xml
%config %{_sysconfdir}/ipfixcol/ipfix-elements.xml
%config %{_sysconfdir}/ipfixcol/startup.xml
%config %{_sysconfdir}/ipfixcol/ipfixviewer_startup.xml
%files devel
%defattr(-,root,root)
%{_includedir}/ipfixcol.h
%dir %{_includedir}/ipfixcol/
%{_includedir}/ipfixcol/*.h
%dir %{_libdir}/ipfixcol
%dir %{_libdir}/ipfixcol/plugins
%{_libdir}/ipfixcol/plugins/ipfixcol-*
%{_libdir}/pkgconfig/ipfixcol.pc
## libsiso
%{_includedir}/siso.h
%{_libdir}/libsiso.so
%changelog