File sysdb.spec of Package sysdb

#
# spec file for package sysdb
#
# Copyright (c) 2017 SUSE LINUX GmbH, Nuernberg, Germany.
#
# 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:           sysdb
Version:        0.8.0
Release:        0
Summary:        The system management and inventory collection service
License:        BSD-2-Clause
Group:          System/Monitoring
Url:            https://sysdb.io
Source0:        sysdb-%{version}.tar.gz
Source1:        sysdbd.service
BuildRoot:      %{_tmppath}/%{name}-%{version}-build
BuildRequires:  asciidoc
BuildRequires:  libdbi-devel
BuildRequires:  gcc-c++
BuildRequires:  xmlto
BuildRequires:  libedit-devel
BuildRequires:  libopenssl-devel
BuildRequires:  check-devel
BuildRequires:  rrdtool-devel
BuildRequires:  libtool
BuildRequires:  readline-devel
BuildRequires:  systemd-rpm-macros
%{?systemd_requires}

#required for tests to succeed
BuildRequires:  valgrind-devel
BuildRequires:  netcat-openbsd
BuildRequires:  timezone

%description
“System Datebase” (SysDB) is an Open Source daemon which aggregates system management and inventory information and stores them in a central database. All information is retrieved from other hardware or software systems and may be queried through a generic interface. 

%prep
%setup -q

%build
%configure --enable-static=no
make %{?_smp_mflags}

%check
make check %{?_smp_mflags}

%install
%make_install

%pre
%service_add_pre sysdbd.service

%post
%service_add_post sysdbd.service

%preun
%service_del_preun sysdbd.service

%postun
%service_del_postun sysdbd.service


%files
%defattr(-,root,root)
%dir %{_libdir}/sysdb
%{_bindir}/sysdb
%{_bindir}/sysdbd
%{_libdir}/sysdb/*
%doc %{_mandir}/man5/sysdbd*
%doc %{_mandir}/man1/sysdb*
%dir /etc/sysdb
%config /etc/sysdb/sysdbd.conf.sample

%package  devel
Summary: Development files for sysdb
Group: Development/Languages/C and C++

%description  devel
This package contains header files, and libraries needed to develop application that use sysdb

%files devel
%defattr(-,root,root)
/usr/include/sysdb/

%package  doc
Summary: Documentation for sysdb

%description  doc
This package contains the documentation for digikam

%files doc
%defattr(-,root,root)
%doc /usr/share/man/man7/sysdb*
%doc /usr/share/doc/sysdb/


%changelog
openSUSE Build Service is sponsored by