2018-11-15 18:40:08 +00:00
|
|
|
#
|
|
|
|
# spec file for package gerbera
|
|
|
|
#
|
2018-11-27 10:25:33 +00:00
|
|
|
# Copyright (c) 2018 SUSE LINUX GmbH, Nuernberg, Germany.
|
2018-11-15 18:40:08 +00: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.
|
|
|
|
|
2018-11-27 10:25:33 +00:00
|
|
|
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
2018-11-15 18:40:08 +00:00
|
|
|
#
|
|
|
|
|
|
|
|
|
|
|
|
Name: gerbera
|
2020-05-21 08:26:17 +00:00
|
|
|
Version: 1.5.0
|
2018-11-15 18:40:08 +00:00
|
|
|
Release: 0
|
|
|
|
Summary: UPnP Media Server
|
2018-11-27 10:25:33 +00:00
|
|
|
License: GPL-2.0-only
|
2018-11-15 18:40:08 +00:00
|
|
|
Group: Productivity/Multimedia/Other
|
2018-11-27 10:25:33 +00:00
|
|
|
URL: https://gerbera.io
|
2020-05-21 08:26:17 +00:00
|
|
|
Source0: https://github.com/gerbera/gerbera/archive/v%{version}.tar.gz#/%{name}-%{version}.tar.gz
|
2018-11-15 18:40:08 +00:00
|
|
|
Source3: gerbera.tmpfile.in
|
|
|
|
Source4: gerbera.sysusers.in
|
|
|
|
BuildRequires: cmake
|
|
|
|
BuildRequires: fdupes
|
|
|
|
BuildRequires: file-devel
|
2018-11-27 10:59:57 +00:00
|
|
|
BuildRequires: gcc-c++
|
2018-11-27 10:25:33 +00:00
|
|
|
BuildRequires: gmock
|
|
|
|
BuildRequires: gtest
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: hicolor-icon-theme
|
2020-05-21 08:26:17 +00:00
|
|
|
BuildRequires: libmatroska-devel
|
|
|
|
BuildRequires: libebml-devel
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: pkgconfig
|
|
|
|
BuildRequires: pkgconfig(duktape)
|
2018-11-27 10:25:33 +00:00
|
|
|
BuildRequires: pkgconfig(exiv2)
|
2020-05-21 08:26:17 +00:00
|
|
|
BuildRequires: pkgconfig(pugixml)
|
|
|
|
BuildRequires: pkgconfig(spdlog)
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: pkgconfig(libavcodec)
|
|
|
|
BuildRequires: pkgconfig(libavformat)
|
|
|
|
BuildRequires: pkgconfig(libavutil)
|
|
|
|
BuildRequires: pkgconfig(libcurl)
|
2018-11-27 10:25:33 +00:00
|
|
|
BuildRequires: pkgconfig(libffmpegthumbnailer)
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: pkgconfig(libswscale)
|
2020-05-21 08:26:17 +00:00
|
|
|
BuildRequires: pkgconfig(libupnp) >= 1.12.0
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: pkgconfig(sqlite3)
|
2018-11-27 10:25:33 +00:00
|
|
|
BuildRequires: pkgconfig(systemd)
|
2018-11-15 18:40:08 +00:00
|
|
|
BuildRequires: pkgconfig(taglib) >= 1.11
|
|
|
|
BuildRequires: pkgconfig(uuid)
|
2018-11-27 10:25:33 +00:00
|
|
|
BuildRequires: pkgconfig(zlib)
|
2018-11-15 18:40:08 +00:00
|
|
|
%{?systemd_requires}
|
|
|
|
|
|
|
|
%description
|
|
|
|
Gerbera is a UPnP media server which allows you to stream your digital
|
|
|
|
media through your home network and consume it on a variety of UPnP
|
|
|
|
compatible devices.
|
|
|
|
|
|
|
|
%prep
|
|
|
|
%setup -q
|
|
|
|
|
2018-11-27 10:25:33 +00:00
|
|
|
# server test hardcodes alpha strings
|
|
|
|
sed -i -e '/test_server/d' test/CMakeLists.txt
|
|
|
|
|
|
|
|
for _file in %{SOURCE3} %{SOURCE4}; do
|
|
|
|
sed -e 's/@USER@/gerbera/' \
|
|
|
|
-e 's/@GROUP@/gerbera/' \
|
2018-11-15 18:40:08 +00:00
|
|
|
< $_file > ${_file##*/}
|
|
|
|
done
|
|
|
|
|
|
|
|
%build
|
|
|
|
%cmake \
|
|
|
|
-DWITH_AVCODEC=1 \
|
2018-11-15 18:50:05 +00:00
|
|
|
-DWITH_EXIF=0 -DWITH_EXIV2=1 \
|
2020-05-21 08:26:17 +00:00
|
|
|
-DWITH_FFMPEGTHUMBNAILER=1
|
|
|
|
%cmake_build
|
2018-11-15 18:40:08 +00:00
|
|
|
|
|
|
|
%install
|
|
|
|
%cmake_install
|
|
|
|
|
|
|
|
install -d %{buildroot}%{_sbindir}
|
2018-11-27 10:25:33 +00:00
|
|
|
ln -s service %{buildroot}%{_sbindir}/rc%{name}
|
2018-11-15 18:40:08 +00:00
|
|
|
install -Dm 0644 %{name}.tmpfile.in %{buildroot}%{_tmpfilesdir}/%{name}.conf
|
|
|
|
install -Dm 0644 %{name}.sysusers.in %{buildroot}%{_sysusersdir}/%{name}.conf
|
|
|
|
|
|
|
|
install -d %{buildroot}%{_localstatedir}/lib/%{name}
|
|
|
|
touch %{buildroot}%{_localstatedir}/lib/%{name}/{config.xml,%{name}.db,%{name}.html}
|
|
|
|
|
2018-11-27 10:25:33 +00:00
|
|
|
%check
|
|
|
|
%ctest
|
|
|
|
|
2018-11-15 18:40:08 +00:00
|
|
|
%pre
|
2018-11-27 10:25:33 +00:00
|
|
|
getent group gerbera >/dev/null || groupadd -r gerbera
|
|
|
|
getent passwd gerbera >/dev/null || \
|
|
|
|
useradd -r -g gerbera -d %{_sysconfdir}/gerbera -s /sbin/nologin \
|
|
|
|
-c "To run Gerbera" gerbera
|
2018-11-15 18:40:08 +00:00
|
|
|
%service_add_pre %{name}.service
|
|
|
|
|
|
|
|
%post
|
|
|
|
%service_add_post %{name}.service
|
|
|
|
%tmpfiles_create %{_tmpfilesdir}/%{name}.conf
|
|
|
|
%sysusers_create %{_sysusersdir}/%{name}.conf
|
|
|
|
|
|
|
|
%preun
|
|
|
|
%service_del_preun %{name}.service
|
|
|
|
|
|
|
|
%postun
|
|
|
|
%service_del_postun %{name}.service
|
|
|
|
|
|
|
|
%files
|
2018-11-27 10:25:33 +00:00
|
|
|
%license LICENSE.md
|
|
|
|
%doc AUTHORS CONTRIBUTING.md ChangeLog.md
|
2018-11-15 18:40:08 +00:00
|
|
|
%{_bindir}/%{name}
|
|
|
|
%{_datadir}/%{name}/
|
|
|
|
%{_unitdir}/%{name}.service
|
|
|
|
%{_sbindir}/rc%{name}
|
|
|
|
%{_tmpfilesdir}/%{name}.conf
|
|
|
|
%{_sysusersdir}/%{name}.conf
|
2018-11-27 10:25:33 +00:00
|
|
|
%{_mandir}/man?/%{name}.?%{?ext_man}
|
|
|
|
%ghost %attr(-,gerbera,gerbera) %dir %{_localstatedir}/lib/%{name}
|
|
|
|
%ghost %attr(0660,gerbera,gerbera) %{_localstatedir}/lib/%{name}/config.xml
|
2020-05-21 08:26:17 +00:00
|
|
|
%ghost %attr(0750,gerbera,gerbera) %{_localstatedir}/lib/%{name}/%{name}.db
|
2018-11-27 10:25:33 +00:00
|
|
|
%ghost %attr(0660,gerbera,gerbera) %{_localstatedir}/lib/%{name}/%{name}.html
|
2018-11-15 18:40:08 +00:00
|
|
|
|
|
|
|
%changelog
|