mirror of
git://git.yoctoproject.org/poky.git
synced 2025-07-19 12:59:02 +02:00
libdnf: upgrade 0.73.4 -> 0.74.0
(From OE-Core rev: 2606586c10b9a3297fcab15cd45f519975649655) Signed-off-by: Wang Mingyu <wangmy@fujitsu.com> Signed-off-by: Mathieu Dubois-Briand <mathieu.dubois-briand@bootlin.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
parent
057049c1b6
commit
f42a153439
|
@ -1,84 +0,0 @@
|
|||
From f3302a865b230e021e9defbcea978ed1290a9b2f Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Miro=20Hron=C4=8Dok?= <miro@hroncok.cz>
|
||||
Date: Fri, 6 Dec 2024 18:01:16 +0100
|
||||
Subject: [PATCH] Fix a segfault in iterator of a ConfigParser section
|
||||
|
||||
An iterator should return self on __iter__.
|
||||
|
||||
So that this works:
|
||||
|
||||
>>> it1 = iter(sectObj)
|
||||
>>> it2 = iter(it1)
|
||||
>>> it1 is it2
|
||||
True
|
||||
|
||||
Previously, this iterator did not return self on __iter__, it was like this:
|
||||
|
||||
class PreserveOrderMapStringStringIterator(object):
|
||||
...
|
||||
def __iter__(self):
|
||||
return _common_types.PreserveOrderMapStringStringIterator___iter__(self)
|
||||
|
||||
And that returned a new Python object.
|
||||
|
||||
This fixes https://bugzilla.redhat.com/2330562 by avoiding a second iterator object.
|
||||
|
||||
My SWIG skills are close to zero,
|
||||
perhaps this is not the best way to return self, but it seems to work.
|
||||
|
||||
Upstream-Status: Backport
|
||||
(https://github.com/rpm-software-management/libdnf/commit/f3302a865b)
|
||||
|
||||
Backport so that it works properly with Python 3.13.1.
|
||||
|
||||
Signed-off-by: Trevor Gamblin <tgamblin@baylibre.com>
|
||||
|
||||
---
|
||||
bindings/swig/common_types.i | 11 +++++++----
|
||||
bindings/swig/conf.i | 4 ----
|
||||
2 files changed, 7 insertions(+), 8 deletions(-)
|
||||
|
||||
diff --git a/bindings/swig/common_types.i b/bindings/swig/common_types.i
|
||||
index c9ae798a..a1f90d9e 100644
|
||||
--- a/bindings/swig/common_types.i
|
||||
+++ b/bindings/swig/common_types.i
|
||||
@@ -63,10 +63,6 @@ template<class T>
|
||||
class Iterator {
|
||||
public:
|
||||
Iterator(typename T::iterator _cur, typename T::iterator _end) : cur(_cur), end(_end) {}
|
||||
- Iterator* __iter__()
|
||||
- {
|
||||
- return this;
|
||||
- }
|
||||
|
||||
typename T::iterator cur;
|
||||
typename T::iterator end;
|
||||
@@ -165,3 +161,10 @@ EXTEND_TEMPLATE_PreserveOrderMapIterator(std::string, std::string)
|
||||
EXTEND_TEMPLATE_PreserveOrderMapIterator(std::string, libdnf::PreserveOrderMap<std::string, std::string>)
|
||||
|
||||
%exception; // beware this resets all exception handlers if you import this file after defining any
|
||||
+
|
||||
+%pythoncode %{
|
||||
+def PreserveOrderMapStringStringIterator___iter__(self):
|
||||
+ return self
|
||||
+PreserveOrderMapStringStringIterator.__iter__ = PreserveOrderMapStringStringIterator___iter__
|
||||
+del PreserveOrderMapStringStringIterator___iter__
|
||||
+%}
|
||||
diff --git a/bindings/swig/conf.i b/bindings/swig/conf.i
|
||||
index b6a0ce88..2f77003f 100644
|
||||
--- a/bindings/swig/conf.i
|
||||
+++ b/bindings/swig/conf.i
|
||||
@@ -71,10 +71,6 @@ template<class T>
|
||||
class Iterator {
|
||||
public:
|
||||
Iterator(typename T::iterator _cur, typename T::iterator _end) : cur(_cur), end(_end) {}
|
||||
- Iterator* __iter__()
|
||||
- {
|
||||
- return this;
|
||||
- }
|
||||
|
||||
typename T::iterator cur;
|
||||
typename T::iterator end;
|
||||
--
|
||||
2.39.5
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
From 05fff53c13fc5969e17f1e887b0b59bf0a088a6e Mon Sep 17 00:00:00 2001
|
||||
From 870f50ba4761317f2db018ac130a42087230dded Mon Sep 17 00:00:00 2001
|
||||
From: Joe Slater <joe.slater@windriver.com>
|
||||
Date: Wed, 22 Jul 2020 13:31:11 -0700
|
||||
Subject: [PATCH] libdnf: allow reproducible binary builds
|
||||
|
@ -14,14 +14,14 @@ Signed-off-by: Joe Slater <joe.slater@windriver.com>
|
|||
1 file changed, 6 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/CMakeLists.txt b/CMakeLists.txt
|
||||
index 60c66e94..1459dfbf 100644
|
||||
index b1daacb..f461e54 100644
|
||||
--- a/CMakeLists.txt
|
||||
+++ b/CMakeLists.txt
|
||||
@@ -132,7 +132,12 @@ add_definitions(-DGETTEXT_DOMAIN=\\"libdnf\\")
|
||||
add_definitions(-DG_LOG_DOMAIN=\\"libdnf\\")
|
||||
@@ -131,7 +131,12 @@ add_definitions(-DGETTEXT_DOMAIN="libdnf")
|
||||
add_definitions(-DG_LOG_DOMAIN="libdnf")
|
||||
|
||||
# tests
|
||||
-add_definitions(-DTESTDATADIR=\\"${CMAKE_SOURCE_DIR}/data/tests\\")
|
||||
-add_definitions(-DTESTDATADIR="${CMAKE_SOURCE_DIR}/data/tests")
|
||||
+if(NOT WITH_TESTS)
|
||||
+ set(TEST_DATA_DIR "/notests")
|
||||
+elseif(NOT DEFINED TEST_DATA_DIR)
|
||||
|
@ -31,3 +31,6 @@ index 60c66e94..1459dfbf 100644
|
|||
|
||||
# librhsm
|
||||
if(ENABLE_RHSM_SUPPORT)
|
||||
--
|
||||
2.43.0
|
||||
|
||||
|
|
|
@ -11,10 +11,9 @@ SRC_URI = "git://github.com/rpm-software-management/libdnf;branch=dnf-4-master;p
|
|||
file://enable_test_data_dir_set.patch \
|
||||
file://0001-drop-FindPythonInstDir.cmake.patch \
|
||||
file://armarch.patch \
|
||||
file://0001-Fix-a-segfault-in-iterator-of-a-ConfigParser-section.patch \
|
||||
"
|
||||
|
||||
SRCREV = "79ed383cd5a822e6d8d9d549835383f5c5106204"
|
||||
SRCREV = "91a0bf9aada36a722855051526f012e0b5ab1af9"
|
||||
UPSTREAM_CHECK_GITTAGREGEX = "(?P<pver>(?!4\.90)\d+(\.\d+)+)"
|
||||
|
||||
S = "${WORKDIR}/git"
|
Loading…
Reference in New Issue
Block a user