File vdr-plugin-streamdev.spec of Package vdr-plugin-streamdev

#
# spec file for package vdr-plugin-streamdev
#
# Copyright (c) 2022 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#


Name:           vdr-plugin-streamdev
Version:        0.6.3
Release:        0
Summary:        Streamdev plugin adds streaming capabilities to your VDR
License:        GPL-2.0-only
Group:          Hardware/TV
URL:            https://github.com/vdr-projects/vdr-plugin-streamdev
Source0:        %{name}-%{version}.tar.xz
Patch0:         makefile-realpath.patch
BuildRequires:  gcc-c++
BuildRequires:  pkg-config
BuildRequires:  vdr-devel
BuildRoot:      %{_tmppath}/%{name}-%{version}-build

%description
The streamdev plugin adds streaming capabilities to your VDR. It comes in two
flavours: VDR-to-VDR streaming using the proprietary VTP protocol and HTTP
based streaming which is understood by a couple of software clients.

%package client
Summary:        The streamdev plugin adds streaming capabilities to your VDR
Group:          Hardware/TV
# Requires(pre) is not enough, as it does not work on updates
Requires:       vdr(abi) = %{vdr_apiversion}

%description client
The streamdev plugin adds streaming capabilities to your VDR. It comes in two
flavours: VDR-to-VDR streaming using the proprietary VTP protocol and HTTP
based streaming which is understood by a couple of software clients. This
package contains the client-plugin.

%package server
Summary:        The streamdev plugin adds streaming capabilities to your VDR
Group:          Hardware/TV
# Requires(pre) is not enough, as it does not work on updates
Requires:       vdr(abi) = %{vdr_apiversion}

%description server
The streamdev plugin adds streaming capabilities to your VDR. It comes in two
flavours: VDR-to-VDR streaming using the proprietary VTP protocol and HTTP
based streaming which is understood by a couple of software clients. This
package contains the server-plugin.

%prep
%autosetup -p 1

%build
# use msgmerge wrapper
export PATH=%{_datadir}/vdr:$PATH
make %{?_smp_mflags}

%install
make DESTDIR=%{buildroot} install
%{vdr_find_locale_name -n vdr-streamdev-client}
%{vdr_find_locale_name -n vdr-streamdev-server}
install -d %{buildroot}%{vdr_sysconfdir}/plugins/streamdev-server
install -m 644 streamdev-server/streamdevhosts.conf  %{buildroot}%{_sysconfdir}/vdr/plugins/streamdev-server/
# 644 to not execute it in the default installation
install -m 644 streamdev-server/externremux.sh       %{buildroot}%{_sysconfdir}/vdr/plugins/streamdev-server/
echo "The externremux.sh script is not executable in the default installation.
Use 'chmod 755 /etc/vdr/plugins/streamdev-server/externremux.sh' if you want
to use it." > %{buildroot}%{_sysconfdir}/vdr/plugins/streamdev-server/externremux.README

%files client -f vdr-streamdev-client.files
%defattr(-,root,root)
%{_libdir}/vdr/libvdr-streamdev-client*
%{vdr_dirs}
%doc HISTORY README CONTRIBUTORS PROTOCOL
%license COPYING

%files server -f vdr-streamdev-server.files
%defattr(-,root,root)
%{_libdir}/vdr/libvdr-streamdev-server*
%{vdr_dirs}
%attr(755,vdr,root) %dir %{vdr_sysconfdir}/plugins/streamdev-server
%config %{_sysconfdir}/vdr/plugins/streamdev-server/streamdevhosts.conf
%config %{_sysconfdir}/vdr/plugins/streamdev-server/externremux.sh
%{_sysconfdir}/vdr/plugins/streamdev-server/externremux.README
%doc HISTORY README CONTRIBUTORS PROTOCOL
%license COPYING

%changelog
openSUSE Build Service is sponsored by