From c850cd52dcee8d2e5107af5ddf33e79b4e33527f Mon Sep 17 00:00:00 2001 From: Alexander Bokovoy Date: Mon, 15 Nov 2021 16:41:01 +0200 Subject: [PATCH] freeipa.spec.in: -server subpackage should require samba-client-libs KDB driver extensively uses NDR parsing and marshalling code provided by Samba libraries. Since these libraries are internal to Samba, they often change structures without updating SONAME. Typical changes include adding new structures, so we should require samba-client-libs we were built against. There used to be %requires_eq macros in RPM but it was removed from Fedora some time ago. We need greater than or equal version of it, thus %ipa_requires_gt is defined in the spec file. Related: https://pagure.io/freeipa/issue/9031 Signed-off-by: Alexander Bokovoy Reviewed-By: Florence Blanc-Renaud Reviewed-By: Francois Cami --- freeipa.spec.in | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/freeipa.spec.in b/freeipa.spec.in index 952c1ad18..e20edb7bc 100755 --- a/freeipa.spec.in +++ b/freeipa.spec.in @@ -1,3 +1,5 @@ +%define ipa_requires_gt() %(LC_ALL="C" echo '%*' | xargs -r rpm -q --qf 'Requires: %%{name} >= %%{epoch}:%%{version}-%%{release}\\n' | sed -e 's/ (none):/ /' -e 's/ 0:/ /' | grep -v "is not") + # ipatests enabled by default, can be disabled with --without ipatests %bcond_without ipatests # default to not use XML-RPC in Rawhide, can be turned around with --with ipa_join_xml @@ -473,6 +475,8 @@ Requires: gssproxy >= 0.7.0-2 Requires: sssd-dbus >= %{sssd_version} Requires: libpwquality Requires: cracklib-dicts +# NDR libraries are internal in Samba and change with version without changing SONAME +%ipa_requires_gt samba-client-libs Provides: %{alt_name}-server = %{version} Conflicts: %{alt_name}-server