add missing BuildRequires: systemd-rpm-macros#99
Draft
corporate-gadfly wants to merge 1 commit into
Draft
Conversation
On SLES, the package uses %service_del_preun and %service_del_postun macros but doesn't declare systemd-rpm-macros as a build dependency. This causes the macros to be incorrectly expanded or missing, resulting in scriptlet failures during package removal on SLES15: error: %preun(openvox-server) scriptlet failed, exit status 1 /var/tmp/rpm-tmp.XXX: line 1: fg: no job control Adding the BuildRequires ensures the macros are properly defined during package build. Signed-off-by: Corporate Gadfly <haroon.rafique@gmail.com>
bastelfreak
approved these changes
May 18, 2026
Contributor
Author
|
@nmburgan Thoughts on using following diff in diff --git a/Dockerfile b/Dockerfile
index 74b2df1cd1..7634b50a6a 100644
--- a/Dockerfile
+++ b/Dockerfile
@@ -4,8 +4,14 @@ RUN apt-get update && \
apt-get install -y --no-install-recommends \
openjdk-17-jdk-headless \
rpm \
+ cpio \
&& rm -rf /var/lib/apt/lists/*
+# Extract the RPM macros to resolve the expansion of macros on SLES
+RUN wget -q https://rpmfind.net/linux/opensuse/distribution/leap/16.0/repo/oss/noarch/systemd-rpm-macros-26-160000.2.2.noarch.rpm -O /tmp/suse-macros.rpm && \
+ rpm2cpio /tmp/suse-macros.rpm | cpio -idmv -D / && \
+ rm /tmp/suse-macros.rpm
+
RUN wget -q https://raw.githubusercontent.com/technomancy/leiningen/stable/bin/lein -O /usr/local/bin/lein && \
chmod a+x /usr/local/bin/lein |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
On SLES, the package uses %service_del_preun and %service_del_postun macros but doesn't declare systemd-rpm-macros as a build dependency.
This causes the macros to be incorrectly expanded or missing, resulting in scriptlet failures during package removal on SLES15:
error: %preun(openvox-server) scriptlet failed, exit status 1
/var/tmp/rpm-tmp.XXX: line 1: fg: no job control
Adding the BuildRequires ensures the macros are properly defined during package build.