Blame SOURCES/0205-Don-t-check-for-rpmvercmp-in-librpm.patch

8e15ce
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
8e15ce
From: Javier Martinez Canillas <javierm@redhat.com>
8e15ce
Date: Fri, 11 Jun 2021 13:13:27 +0200
8e15ce
Subject: [PATCH] Don't check for rpmvercmp in librpm
8e15ce
8e15ce
The rpmvercmp() function was moved from librpm to librpmio. The configure
8e15ce
option had some logic to first check if the symbol is in librpm and then
8e15ce
librpmio if this check didn't succeed.
8e15ce
8e15ce
But the logic wasn't working and rpm sorting was always disabled. Instead
8e15ce
of trying to fix this logic, let's just remove since the function already
8e15ce
moved and there's no need to check librpm anymore. Now it's enabled again:
8e15ce
8e15ce
  GRUB2 will be compiled with following components:
8e15ce
  ...
8e15ce
  grub-rpm-sort: Yes
8e15ce
  ...
8e15ce
8e15ce
Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
8e15ce
---
8e15ce
 configure.ac | 19 +++++--------------
8e15ce
 1 file changed, 5 insertions(+), 14 deletions(-)
8e15ce
8e15ce
diff --git a/configure.ac b/configure.ac
8e15ce
index c7842ec29d8..3c808a72230 100644
8e15ce
--- a/configure.ac
8e15ce
+++ b/configure.ac
8e15ce
@@ -1947,24 +1947,15 @@ if test x"$rpm_sort_excuse" = x ; then
8e15ce
 fi
8e15ce
 
8e15ce
 if test x"$rpm_sort_excuse" = x ; then
8e15ce
-  # Check for rpm library.
8e15ce
-  AC_CHECK_LIB([rpm], [rpmvercmp], [],
8e15ce
-               [rpm_sort_excuse="rpmlib missing rpmvercmp"])
8e15ce
-fi
8e15ce
-
8e15ce
-if test x"$rpm_sort_excuse" = x ; then
8e15ce
-   LIBRPM="-lrpm";
8e15ce
-   AC_DEFINE([HAVE_RPM], [1],
8e15ce
-             [Define to 1 if you have the rpm library.])
8e15ce
-fi
8e15ce
-
8e15ce
-if test x"$LIBRPM" = x ; then
8e15ce
-  # Check for rpm library.
8e15ce
+  # Check for rpmio library.
8e15ce
   AC_CHECK_LIB([rpmio], [rpmvercmp], [],
8e15ce
                [rpm_sort_excuse="rpmio missing rpmvercmp"])
8e15ce
+fi
8e15ce
+
8e15ce
+if test x"$rpm_sort_excuse" = x ; then
8e15ce
    LIBRPM="-lrpmio";
8e15ce
    AC_DEFINE([HAVE_RPMIO], [1],
8e15ce
-             [Define to 1 if you have the rpm library.])
8e15ce
+             [Define to 1 if you have the rpmio library.])
8e15ce
 fi
8e15ce
 
8e15ce
 AC_SUBST([LIBRPM])