Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

False positive: systemd-service-without-service_del_postun if service restart is disabled #72

Open
Vogtinator opened this issue Feb 9, 2023 · 0 comments

Comments

@Vogtinator
Copy link
Member

The sddm service must not be restarted on upgrades, so the %postun scriptlet contains:

%postun
# Don't restart on upgrades (boo#1161826)
%if 0%{?suse_version} > 1500
%service_del_postun_without_restart sddm.service
%else
%service_del_postun -n sddm.service
%endif

This leads to:

[  129s] sddm.x86_64: E: systemd-service-without-service_del_postun sddm.service
[  129s] The package contains a systemd service but doesn't contain a %postun with a
[  129s] call to service_del_postun.

The expanded scriptlet does not mention the unit names at all:

postuninstall scriptlet (using /bin/sh):
# Don't restart on upgrades (boo#1161826)

if [ -x /usr/bin/systemctl ]; then
        /usr/bin/systemctl daemon-reload || :
fi
jdsn added a commit to jdsn/juliogonzalez--nexus-oss-rpms that referenced this issue Oct 12, 2023
Since suse_version > 1500
the macro "%service_del_postun -n"
must be replaced with %service_del_postun_without_restart.

This fix should fix the build for Tumbleweed and Factory.

See also:
openSUSE/rpmlint-checks#72
danigm added a commit to rpm-software-management/rpmlint that referenced this issue Nov 6, 2024
danigm added a commit to rpm-software-management/rpmlint that referenced this issue Nov 6, 2024
danigm added a commit to rpm-software-management/rpmlint that referenced this issue Nov 6, 2024
danigm added a commit to rpm-software-management/rpmlint that referenced this issue Nov 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant