File tree Expand file tree Collapse file tree 3 files changed +15
-5
lines changed Expand file tree Collapse file tree 3 files changed +15
-5
lines changed Original file line number Diff line number Diff line change @@ -129,19 +129,25 @@ case "$PACKAGING" in
129
129
fi
130
130
fi
131
131
132
- # determine policy-version for rhel systems so we can require what we build with
132
+ # determine system-provided dependency versions that we build with so that installs work well
133
133
if [ " $OS " = " rhel" ]; then
134
134
SELINUX_POLICY_VERSION=$( rpm -q --qf ' %{VERSION}\n' selinux-policy)
135
135
if [ -z " $SELINUX_POLICY_VERSION " ]; then
136
136
echo " error: unable to determine selinux-policy package version"
137
137
exit 1
138
138
fi
139
+ OPENSSL_VERSION=$( rpm -q --provides openssl-libs | grep OPENSSL_ | sed ' s/^.*_\([0-9.]*\).*$/\1/' | sort -n | tail -1)
140
+ if [ -z " $OPENSSL_VERSION " ]; then
141
+ echo " error: unable to determine openssl package version"
142
+ exit 1
143
+ fi
139
144
fi
140
145
141
146
sed \
142
147
-e " s/@@VERSION@@/$RPM_VERSION /g" \
143
148
-e " s/@@RELEASE@@/$safe_prefix$RPM_RELEASE /g" \
144
149
-e " s/@@SELINUX_POLICY_VERSION@@/$SELINUX_POLICY_VERSION /g" \
150
+ -e " s/@@OPENSSL_VERSION@@/$OPENSSL_VERSION /g" \
145
151
-e " /^%pre\$ /r $PREINSTALL " \
146
152
-e " /^%post\$ /r $POSTINSTALL " \
147
153
-e " /^%preun\$ /r $PREREMOVE " \
Original file line number Diff line number Diff line change @@ -33,9 +33,11 @@ Requires: libssl.so.1.1()(64bit) libssl.so.1.1(OPENSSL_1_1_0)(64bit) libssl.so.1
33
33
Requires: libcrypto.so.1.1()(64bit) libcrypto.so.1.1(OPENSSL_1_1_0)(64bit)
34
34
%endif
35
35
36
+ # libcurl can rely on a more specific version of openssl so use the one we build with.
37
+ # OPENSSL_VERSION is determined in build-scripts/package script.
36
38
%if %{?rhel}%{!?rhel:0} > 8
37
- Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_3.0.0)(64bit) libcrypto.so.3(OPENSSL_3.0.1 )(64bit)
38
- Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_3.0.0 )(64bit)
39
+ Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_@@OPENSSL_VERSION@@ )(64bit)
40
+ Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_@@OPENSSL_VERSION@@ )(64bit)
39
41
%endif
40
42
41
43
# cfbs/Build requires Python 3.5+ (not available on RHEL 6)
Original file line number Diff line number Diff line change @@ -29,9 +29,11 @@ Requires: libssl.so.1.1()(64bit) libssl.so.1.1(OPENSSL_1_1_0)(64bit) libssl.so.1
29
29
Requires: libcrypto.so.1.1()(64bit) libcrypto.so.1.1(OPENSSL_1_1_0)(64bit)
30
30
%endif
31
31
32
+ # libcurl can rely on a more specific version of openssl so use the one we build with.
33
+ # OPENSSL_VERSION is determined in build-scripts/package script.
32
34
%if %{?rhel}%{!?rhel:0} > 8
33
- Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_3.0.0)(64bit) libcrypto.so.3(OPENSSL_3.0.1 )(64bit)
34
- Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_3.0.0 )(64bit)
35
+ Requires: libcrypto.so.3()(64bit) libcrypto.so.3(OPENSSL_@@OPENSSL_VERSION@@ )(64bit)
36
+ Requires: libssl.so.3()(64bit) libssl.so.3(OPENSSL_@@OPENSSL_VERSION@@ )(64bit)
35
37
%endif
36
38
37
39
AutoReqProv: no
You can’t perform that action at this time.
0 commit comments