Skip to content

Fixed issue where rhel >8 packages would not have correct openssl dependency version (3.24) #1572

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

Open
wants to merge 1 commit into
base: 3.24.x
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions build-scripts/package
Original file line number Diff line number Diff line change
Expand Up @@ -136,12 +136,18 @@ case "$PACKAGING" in
echo "error: unable to determine selinux-policy package version"
exit 1
fi
OPENSSL_VERSION=$(rpm -q --qf '%{VERSION}\n' openssl | sed 's/\([0-9]*.[0-9]*.\)[0-9]*/\10/')
if [ -z "$OPENSSL_VERSION" ]; then
echo "error: unable to determine openssl package version"
exit 1
fi
fi

sed \
-e "s/@@VERSION@@/$RPM_VERSION/g" \
-e "s/@@RELEASE@@/$safe_prefix$RPM_RELEASE/g" \
-e "s/@@SELINUX_POLICY_VERSION@@/$SELINUX_POLICY_VERSION/g" \
-e "s/@@OPENSSL_VERSION@@/$OPENSSL_VERSION/g" \
-e "/^%pre\$/r $PREINSTALL" \
-e "/^%post\$/r $POSTINSTALL" \
-e "/^%preun\$/r $PREREMOVE" \
Expand Down
6 changes: 4 additions & 2 deletions packaging/cfengine-nova/cfengine-nova.spec.in
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,11 @@ Requires: libssl.so.1.1()(64bit) libssl.so.1.1(OPENSSL_1_1_0)(64bit) libssl.so.1
Requires: libcrypto.so.1.1()(64bit) libcrypto.so.1.1(OPENSSL_1_1_0)(64bit)
%endif

# libcurl will end up depending on the specific version we build with so list that as a requirement.
# OPENSSL_VERSION is determined in build-scripts/package script in this same project.
%if %{?rhel}%{!?rhel:0} > 8
Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_3.0.0)(64bit) libcrypto.so.3(OPENSSL_3.0.1)(64bit)
Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_3.0.0)(64bit)
Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_@@OPENSSL_VERSION@@)(64bit)
Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_@@OPENSSL_VERSION@@)(64bit)
%endif

AutoReqProv: no
Expand Down