%global debug_package %{nil} Name: bazarr Version: 1.5.5 Release: %autorelease Summary: Companion application to Sonarr and Radarr. It manages and downloads subtitles based on your requirements License: GPL-3.0-only URL: https://github.com/morpheus65535/bazarr Source0: %{url}/archive/refs/tags/v%{version}.tar.gz Source1: %{name}.sysusers Source2: %{name}.service Source3: %{name}-service.preset Source4: %{name}-tmpfiles.conf Source5: %{name}-sysconfig.conf BuildRequires: nodejs BuildRequires: npm BuildRequires: python3-devel BuildRequires: sed BuildRequires: systemd-rpm-macros %{?systemd_requires} %{?sysusers_requires_compat} Requires: python3 Requires: python3dist(lxml) >= 4.3.0 Requires: python3dist(numpy) >= 1.12.0 Requires: python3dist(numpy) < 2.4.0 Requires: python3dist(pillow) >= 9.0.0 Requires: (ffmpeg or ffmpeg-free) Requires: unar Requires: unrar Requires: 7zip Recommends: ffmpeg Requires: python3dist(setuptools) Requires: python3dist(webrtcvad-wheels) >= 2.0.10 Recommends: python3dist(psycopg2) %description %{summary}. %prep %autosetup -n bazarr-%{version} %build pushd frontend HUSKY=0 npm ci npm run build popd %install install --directory "%{buildroot}%{_libexecdir}/%{name}" cp -a bazarr bazarr.py migrations custom_libs libs "%{buildroot}%{_libexecdir}/%{name}/" install --directory "%{buildroot}%{_libexecdir}/%{name}/frontend" cp -a frontend/build "%{buildroot}%{_libexecdir}/%{name}/frontend/" cp -a frontend/public "%{buildroot}%{_libexecdir}/%{name}/frontend/" %py_byte_compile %{python3} %{buildroot}%{_libexecdir}/%{name}/bazarr/ sed "s/@VERSION@/%{version}/g" "%{SOURCE2}" > "%{_builddir}/%{name}.service" install -D --mode=0644 "%{_builddir}/%{name}.service" %{buildroot}%{_unitdir}/%{name}.service install -D --mode=0644 "%{SOURCE3}" %{buildroot}%{_prefix}/lib/systemd/system-preset/90-%{name}.preset install -D --mode=0644 "%{SOURCE4}" %{buildroot}%{_exec_prefix}/lib/tmpfiles.d/%{name}.conf install -D --mode=0644 "%{SOURCE5}" %{buildroot}%{_sysconfdir}/sysconfig/%{name} install -D --mode=0644 "%{SOURCE1}" %{buildroot}%{_sysusersdir}/%{name}.conf %files %doc README.md %license LICENSE %{_libexecdir}/%{name}/ %{_unitdir}/%{name}.service %{_prefix}/lib/systemd/system-preset/90-%{name}.preset %{_exec_prefix}/lib/tmpfiles.d/%{name}.conf %config(noreplace) %{_sysconfdir}/sysconfig/%{name} %{_sysusersdir}/%{name}.conf %pre %sysusers_create_compat %{_sysusersdir}/%{name}.conf %post %systemd_post %{name}.service %preun %systemd_preun %{name}.service %postun %systemd_postun_with_restart %{name}.service %changelog %autochangelog