SHA256
1
0
forked from pool/pesign

Accepting request 1116045 from home:dancermak:branches:Base:System

Create pesign-systemd subpackage to remove systemd dependency

OBS-URL: https://build.opensuse.org/request/show/1116045
OBS-URL: https://build.opensuse.org/package/show/Base:System/pesign?expand=0&rev=72
This commit is contained in:
Gary Ching-Pang Lin 2023-11-01 07:16:53 +00:00 committed by Git OBS Bridge
parent 361faa327f
commit e2291ee74b
2 changed files with 24 additions and 16 deletions

View File

@ -1,3 +1,8 @@
-------------------------------------------------------------------
Fri Oct 6 13:13:09 UTC 2023 - Dan Čermák <dcermak@suse.com>
- Create pesign-systemd subpackage to remove systemd dependency
-------------------------------------------------------------------
Wed Feb 22 08:05:20 UTC 2023 - Gary Ching-Pang Lin <glin@suse.com>

View File

@ -48,25 +48,24 @@ BuildRequires: popt-devel
BuildRequires: sysuser-tools
BuildRequires: pkgconfig(systemd)
%sysusers_requires
%{?systemd_requires}
ExclusiveArch: ia64 %ix86 x86_64 aarch64 %arm riscv64
Recommends: %{name}-systemd
%description
Signing tool for PE-COFF binaries. It is vaguely compliant
with the PE and Authenticode specifications.
%package systemd
Summary: Systemd units for pesign
Requires: %{name} = %{version}
%{?systemd_requires}
BuildArch: noarch
%description systemd
Systemd units for the pesign package.
%prep
%setup -q
%patch1 -p1
%patch2 -p1
%patch3 -p1
%patch4 -p1
%patch5 -p1
%patch6 -p1
%patch7 -p1
%patch8 -p1
%patch9 -p1
%patch10 -p1
%autosetup -p1
%build
%sysusers_generate_pre %{SOURCE1} %{name} %{name}.conf
@ -92,16 +91,18 @@ rm -rf %{buildroot}%{_libdir}/libdpe*
install -Dm0644 %{SOURCE1} %{buildroot}%{_sysusersdir}/%{name}.conf
%pre -f %{name}.pre
%pre systemd
%service_add_pre pesign.service
%preun
%preun systemd
%service_del_preun pesign.service
%post
%post systemd
%service_add_post pesign.service
systemd-tmpfiles --create %{_tmpfilesdir}/pesign.conf || :
%postun
%postun systemd
%service_del_postun pesign.service
%files
@ -120,7 +121,6 @@ systemd-tmpfiles --create %{_tmpfilesdir}/pesign.conf || :
%config %{_sysconfdir}/popt.d/pesign.popt
%{_rpmmacrodir}/macros.pesign
%{_mandir}/man?/*
%{_unitdir}/pesign.service
%{_sysusersdir}/pesign.conf
%{_tmpfilesdir}/pesign.conf
%dir %{_libexecdir}/pesign
@ -130,4 +130,7 @@ systemd-tmpfiles --create %{_tmpfilesdir}/pesign.conf || :
%ghost %dir %attr(0770,pesign,pesign) /run/%{name}
%dir %attr(0770,pesign,pesign) %{_localstatedir}/lib/%{name}
%files systemd
%{_unitdir}/pesign.service
%changelog