forked from pool/openscap
Accepting request 1059915 from security
- 0001-Use-correct-includes.patch: fixed build with rpm 4.18 (forwarded request 1059914 from msmeissn) OBS-URL: https://build.opensuse.org/request/show/1059915 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/openscap?expand=0&rev=80
This commit is contained in:
commit
fbbb5de23b
61
0001-Use-correct-includes.patch
Normal file
61
0001-Use-correct-includes.patch
Normal file
@ -0,0 +1,61 @@
|
||||
From 8dec1bb5e9546e75ae6e7b7cf94cf00197ce3e5d Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Jan=20=C4=8Cern=C3=BD?= <jcerny@redhat.com>
|
||||
Date: Tue, 24 May 2022 12:15:44 +0200
|
||||
Subject: [PATCH] Use correct includes
|
||||
|
||||
rpmvercmp is defined in rpm/rpmver.h
|
||||
risdigit is defined in rpm/rpmstring.h
|
||||
|
||||
Resolves: rhbz#2080210
|
||||
---
|
||||
cmake/FindRPM.cmake | 3 +++
|
||||
config.h.in | 1 +
|
||||
src/OVAL/results/oval_cmp_evr_string.c | 5 +++++
|
||||
3 files changed, 9 insertions(+)
|
||||
|
||||
diff --git a/cmake/FindRPM.cmake b/cmake/FindRPM.cmake
|
||||
index a666942ea..369d153fc 100644
|
||||
--- a/cmake/FindRPM.cmake
|
||||
+++ b/cmake/FindRPM.cmake
|
||||
@@ -30,6 +30,9 @@ set(RPM_VERSION ${RPM_PKGCONF_VERSION})
|
||||
if(RPM_VERSION)
|
||||
string(COMPARE GREATER "4.6" ${RPM_VERSION} RPM46_FOUND)
|
||||
string(COMPARE GREATER "4.7" ${RPM_VERSION} RPM47_FOUND)
|
||||
+ if(NOT (RPM_VERSION VERSION_LESS "4.18"))
|
||||
+ set(RPM418_FOUND 1)
|
||||
+ endif()
|
||||
endif()
|
||||
|
||||
# Set the include dir variables and the libraries and let libfind_process do the rest.
|
||||
diff --git a/config.h.in b/config.h.in
|
||||
index 1b7285582..bb1428afc 100644
|
||||
--- a/config.h.in
|
||||
+++ b/config.h.in
|
||||
@@ -44,6 +44,7 @@
|
||||
#cmakedefine HAVE_RPMVERCMP
|
||||
#cmakedefine RPM46_FOUND
|
||||
#cmakedefine RPM47_FOUND
|
||||
+#cmakedefine RPM418_FOUND
|
||||
|
||||
#cmakedefine BZIP2_FOUND
|
||||
|
||||
diff --git a/src/OVAL/results/oval_cmp_evr_string.c b/src/OVAL/results/oval_cmp_evr_string.c
|
||||
index 3bfc8ce5f..3ba0fa0cb 100644
|
||||
--- a/src/OVAL/results/oval_cmp_evr_string.c
|
||||
+++ b/src/OVAL/results/oval_cmp_evr_string.c
|
||||
@@ -37,7 +37,12 @@
|
||||
#include "common/_error.h"
|
||||
|
||||
#ifdef HAVE_RPMVERCMP
|
||||
+#ifdef RPM418_FOUND
|
||||
+#include <rpm/rpmver.h>
|
||||
+#include <rpm/rpmstring.h>
|
||||
+#else
|
||||
#include <rpm/rpmlib.h>
|
||||
+#endif
|
||||
#else
|
||||
#ifdef OS_WINDOWS
|
||||
#include <malloc.h>
|
||||
--
|
||||
2.35.3
|
||||
|
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Thu Jan 19 15:55:11 UTC 2023 - Marcus Meissner <meissner@suse.com>
|
||||
|
||||
- 0001-Use-correct-includes.patch: fixed build with rpm 4.18
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Sep 21 07:41:07 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
|
@ -1,7 +1,7 @@
|
||||
#
|
||||
# spec file for package openscap
|
||||
#
|
||||
# Copyright (c) 2022 SUSE LLC
|
||||
# Copyright (c) 2023 SUSE LLC
|
||||
#
|
||||
# All modifications and additions to the file contributed by third parties
|
||||
# remain the property of their copyright owners, unless otherwise agreed
|
||||
@ -44,6 +44,7 @@ Patch3: openscap-docker-add-suse.patch
|
||||
%if 0%{?suse_version} != 1599
|
||||
Patch4: oscap-remediate.service.in.patch
|
||||
%endif
|
||||
Patch5: 0001-Use-correct-includes.patch
|
||||
BuildRequires: asciidoc
|
||||
# Use package name cause of "have choice for perl(XML::Parser): brp-check-suse perl-XML-Parser"
|
||||
BuildRequires: cmake
|
||||
|
Loading…
Reference in New Issue
Block a user