File osmo-cbc.spec of Package osmo-cbc

#
# spec file for package osmo-cbc
#
# Copyright (c) 2019-2021, 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:           osmo-cbc
Version:        0.2.3
Release:        0
Summary:        Osmocom Cell Broadcast Centre
License:        AGPL-3.0-or-later
Group:          Productivity/Telephony/Utilities
URL:            https://osmocom.org/projects/osmo-cbc/wiki
Source:         %{name}-%{version}.tar.xz
BuildRequires:  autoconf
BuildRequires:  automake
BuildRequires:  libtool
BuildRequires:  pkgconfig >= 0.20
BuildRequires:  pkgconfig(libosmo-netif) >= 1.1.0
BuildRequires:  pkgconfig(libosmocore) >= 1.5.0
BuildRequires:  pkgconfig(libosmogsm) >= 1.5.0
BuildRequires:  pkgconfig(libosmovty) >= 1.5.0
BuildRequires:  pkgconfig(libulfius)
BuildRequires:  pkgconfig(systemd)

%description
Osmocom Cell Broadcast Centre.

%prep
%setup -q

%build
echo "%{version}" >.tarball-version
autoreconf -fiv
%configure -docdir=%{_docdir}/%{name}
%make_build

%install
%make_install

%check
%make_build check || (find . -name testsuite.log -exec cat {} +)

%preun
%service_del_preun %{name}.service

%postun
%service_del_postun %{name}.service

%pre
%service_add_pre %{name}.service

%post
%service_add_post %{name}.service

%files
%license COPYING
%doc %{_docdir}/osmo-cbc
%doc %{_docdir}/osmo-cbc/examples
%{_bindir}/osmo-cbc
%{_unitdir}/osmo-cbc.service
%dir %{_sysconfdir}/osmocom
%config(noreplace) %{_sysconfdir}/osmocom/osmo-cbc.cfg

%changelog
openSUSE Build Service is sponsored by