From e172635965af0cdd2d8355840e93f24e7cbe81d2 Mon Sep 17 00:00:00 2001 From: Igor Gnatenko Date: Mar 29 2019 16:49:34 +0000 Subject: Update to 0.7.4 Signed-off-by: Igor Gnatenko (cherry picked from commit 6d0b5397e240d518318808a458444880161d5690) --- diff --git a/.gitignore b/.gitignore index 895d7a0..f0e3a63 100644 --- a/.gitignore +++ b/.gitignore @@ -45,3 +45,4 @@ /libsolv-0.7.0.tar.gz /libsolv-0.7.1.tar.gz /libsolv-0.7.2.tar.gz +/libsolv-0.7.4.tar.gz diff --git a/0001-Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job.patch b/0001-Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job.patch deleted file mode 100644 index dc7af19..0000000 --- a/0001-Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job.patch +++ /dev/null @@ -1,46 +0,0 @@ -From 5323eb7e5c0c8dcdf339113f091317afaed810cc Mon Sep 17 00:00:00 2001 -From: Michael Schroeder -Date: Tue, 15 Jan 2019 14:06:08 +0100 -Subject: [PATCH] Do not disable infarch rules when they don't conflict with the job - ---- - src/rules.c | 16 +++++++++++++--- - 1 file changed, 13 insertions(+), 3 deletions(-) - -diff --git a/src/rules.c b/src/rules.c -index 2087b35..175cb8d 100644 ---- a/src/rules.c -+++ b/src/rules.c -@@ -2126,7 +2126,13 @@ jobtodisablelist(Solver *solv, Id how, Id what, Queue *q) - if ((set & SOLVER_SETARCH) != 0 && solv->infarchrules != solv->infarchrules_end) - { - if (select == SOLVER_SOLVABLE) -- queue_push2(q, DISABLE_INFARCH, pool->solvables[what].name); -+ { -+ for (i = solv->infarchrules; i < solv->infarchrules_end; i++) -+ if (solv->rules[i].p == -what) -+ break; -+ if (i < solv->infarchrules_end) -+ queue_push2(q, DISABLE_INFARCH, pool->solvables[what].name); -+ } - else - { - int qcnt = q->count; -@@ -2140,8 +2146,12 @@ jobtodisablelist(Solver *solv, Id how, Id what, Queue *q) - if (q->elements[i + 1] == s->name) - break; - if (i < q->count) -- continue; -- queue_push2(q, DISABLE_INFARCH, s->name); -+ continue; /* already have that DISABLE_INFARCH element */ -+ for (i = solv->infarchrules; i < solv->infarchrules_end; i++) -+ if (solv->rules[i].p == -p) -+ break; -+ if (i < solv->infarchrules_end) -+ queue_push2(q, DISABLE_INFARCH, s->name); - } - } - } --- -libgit2 0.27.7 - diff --git a/0002-Add-support-for-modular-updateinfoxml-data.patch b/0002-Add-support-for-modular-updateinfoxml-data.patch deleted file mode 100644 index 0955503..0000000 --- a/0002-Add-support-for-modular-updateinfoxml-data.patch +++ /dev/null @@ -1,101 +0,0 @@ -From aac9f0c2d791fa96bc9423231050f9e18fb973d6 Mon Sep 17 00:00:00 2001 -From: Jaroslav Mracek -Date: Thu, 17 Jan 2019 12:48:05 +0100 -Subject: [PATCH] Add support for modular updateinfo.xml data - ---- - ext/repo_updateinfoxml.c | 37 +++++++++++++++++++++++++++++++++++++ - src/knownid.h | 8 ++++++++ - 2 files changed, 45 insertions(+) - -diff --git a/ext/repo_updateinfoxml.c b/ext/repo_updateinfoxml.c -index ff84d32..8a3d147 100644 ---- a/ext/repo_updateinfoxml.c -+++ b/ext/repo_updateinfoxml.c -@@ -37,6 +37,7 @@ - * - * - * Fedora 8 -+ * - * - * imlib-debuginfo-1.9.15-6.fc8.ppc64.rpm - * True -@@ -70,6 +71,7 @@ enum state { - STATE_RELOGIN, - STATE_RIGHTS, - STATE_SEVERITY, -+ STATE_MODULE, - NUMSTATES - }; - -@@ -92,6 +94,7 @@ static struct solv_xmlparser_element stateswitches[] = { - { STATE_PKGLIST, "collection", STATE_COLLECTION, 0 }, - { STATE_COLLECTION, "name", STATE_NAME, 1 }, - { STATE_COLLECTION, "package", STATE_PACKAGE, 0 }, -+ { STATE_COLLECTION, "module", STATE_MODULE, 0 }, - { STATE_PACKAGE, "filename", STATE_FILENAME, 1 }, - { STATE_PACKAGE, "reboot_suggested",STATE_REBOOT, 1 }, - { STATE_PACKAGE, "restart_suggested",STATE_RESTART, 1 }, -@@ -321,6 +324,40 @@ startElement(struct solv_xmlparser *xmlp, int state, const char *name, const cha - repodata_set_id(pd->data, pd->collhandle, UPDATE_COLLECTION_ARCH, a); - break; - } -+ case STATE_MODULE: -+ { -+ const char *name = 0, *stream = 0, *version = 0, *context = 0, *arch = 0; -+ Id name_id, stream_id, version_id, context_id, arch_id = 0; -+ for (; *atts; atts += 2) -+ { -+ if (!strcmp(*atts, "arch")) -+ arch = atts[1]; -+ else if (!strcmp(*atts, "name")) -+ name = atts[1]; -+ else if (!strcmp(*atts, "stream")) -+ stream = atts[1]; -+ else if (!strcmp(*atts, "version")) -+ version = atts[1]; -+ else if (!strcmp(*atts, "context")) -+ context = atts[1]; -+ } -+ name_id = pool_str2id(pool, name, 1); -+ if (arch) -+ arch_id = pool_str2id(pool, arch, 1); -+ stream_id = pool_str2id(pool, stream, 1); -+ version_id = pool_str2id(pool, version, 1); -+ context_id = pool_str2id(pool, context, 1); -+ -+ Id module_handle = repodata_new_handle(pd->data); -+ repodata_set_id(pd->data, module_handle, UPDATE_MODULE_NAME, name_id); -+ repodata_set_id(pd->data, module_handle, UPDATE_MODULE_STREAM, stream_id); -+ repodata_set_id(pd->data, module_handle, UPDATE_MODULE_VERSION, version_id); -+ repodata_set_id(pd->data, module_handle, UPDATE_MODULE_CONTEXT, context_id); -+ if (arch_id) -+ repodata_set_id(pd->data, module_handle, UPDATE_MODULE_ARCH, arch_id); -+ repodata_add_flexarray(pd->data, pd->handle, UPDATE_MODULE, module_handle); -+ break; -+ } - - default: - break; -diff --git a/src/knownid.h b/src/knownid.h -index 8e53183..b5b41d6 100644 ---- a/src/knownid.h -+++ b/src/knownid.h -@@ -250,6 +250,14 @@ KNOWNID(SIGNATURE_TIME, "signature:time"), - KNOWNID(SIGNATURE_EXPIRES, "signature:expires"), - KNOWNID(SIGNATURE_DATA, "signature:data"), - -+/* 'content' of patch, usually list of modules */ -+KNOWNID(UPDATE_MODULE, "update:module"), /* "name stream version context arch" */ -+KNOWNID(UPDATE_MODULE_NAME, "update:module:name"), /* name */ -+KNOWNID(UPDATE_MODULE_STREAM, "update:module:stream"), /* stream */ -+KNOWNID(UPDATE_MODULE_VERSION, "update:module:version"), /* version */ -+KNOWNID(UPDATE_MODULE_CONTEXT, "update:module:context"), /* context */ -+KNOWNID(UPDATE_MODULE_ARCH, "update:module:arch"), /* architecture */ -+ - KNOWNID(ID_NUM_INTERNAL, 0) - - #ifdef KNOWNID_INITIALIZE --- -libgit2 0.27.7 - diff --git a/0003-Simplify-moldule-code.patch b/0003-Simplify-moldule-code.patch deleted file mode 100644 index db0cb41..0000000 --- a/0003-Simplify-moldule-code.patch +++ /dev/null @@ -1,57 +0,0 @@ -From f9a8953aee107d148ddabddd7217ba7656ec46f8 Mon Sep 17 00:00:00 2001 -From: Michael Schroeder -Date: Wed, 13 Feb 2019 14:02:31 +0100 -Subject: [PATCH] Simplify moldule code - ---- - ext/repo_updateinfoxml.c | 26 ++++++++++++-------------- - 1 file changed, 12 insertions(+), 14 deletions(-) - -diff --git a/ext/repo_updateinfoxml.c b/ext/repo_updateinfoxml.c -index 8a3d147..f375727 100644 ---- a/ext/repo_updateinfoxml.c -+++ b/ext/repo_updateinfoxml.c -@@ -327,7 +327,8 @@ startElement(struct solv_xmlparser *xmlp, int state, const char *name, const cha - case STATE_MODULE: - { - const char *name = 0, *stream = 0, *version = 0, *context = 0, *arch = 0; -- Id name_id, stream_id, version_id, context_id, arch_id = 0; -+ Id module_handle; -+ - for (; *atts; atts += 2) - { - if (!strcmp(*atts, "arch")) -@@ -341,20 +342,17 @@ startElement(struct solv_xmlparser *xmlp, int state, const char *name, const cha - else if (!strcmp(*atts, "context")) - context = atts[1]; - } -- name_id = pool_str2id(pool, name, 1); -+ module_handle = repodata_new_handle(pd->data); -+ if (name) -+ repodata_set_poolstr(pd->data, module_handle, UPDATE_MODULE_NAME, name); -+ if (stream) -+ repodata_set_poolstr(pd->data, module_handle, UPDATE_MODULE_STREAM, stream); -+ if (version) -+ repodata_set_poolstr(pd->data, module_handle, UPDATE_MODULE_VERSION, version); -+ if (context) -+ repodata_set_poolstr(pd->data, module_handle, UPDATE_MODULE_CONTEXT, context); - if (arch) -- arch_id = pool_str2id(pool, arch, 1); -- stream_id = pool_str2id(pool, stream, 1); -- version_id = pool_str2id(pool, version, 1); -- context_id = pool_str2id(pool, context, 1); -- -- Id module_handle = repodata_new_handle(pd->data); -- repodata_set_id(pd->data, module_handle, UPDATE_MODULE_NAME, name_id); -- repodata_set_id(pd->data, module_handle, UPDATE_MODULE_STREAM, stream_id); -- repodata_set_id(pd->data, module_handle, UPDATE_MODULE_VERSION, version_id); -- repodata_set_id(pd->data, module_handle, UPDATE_MODULE_CONTEXT, context_id); -- if (arch_id) -- repodata_set_id(pd->data, module_handle, UPDATE_MODULE_ARCH, arch_id); -+ repodata_set_poolstr(pd->data, module_handle, UPDATE_MODULE_ARCH, arch); - repodata_add_flexarray(pd->data, pd->handle, UPDATE_MODULE, module_handle); - break; - } --- -libgit2 0.27.7 - diff --git a/libsolv.spec b/libsolv.spec index d9dc721..d7d3dda 100644 --- a/libsolv.spec +++ b/libsolv.spec @@ -39,16 +39,13 @@ %endif Name: lib%{libname} -Version: 0.7.2 -Release: 3%{?dist} +Version: 0.7.4 +Release: 1%{?dist} Summary: Package dependency solver License: BSD URL: https://github.com/openSUSE/libsolv Source: %{url}/archive/%{version}/%{name}-%{version}.tar.gz -Patch0001: 0001-Do-not-disable-infarch-rules-when-they-dont-conflict-with-the-job.patch -Patch0002: 0002-Add-support-for-modular-updateinfoxml-data.patch -Patch0003: 0003-Simplify-moldule-code.patch BuildRequires: cmake BuildRequires: gcc-c++ @@ -291,6 +288,9 @@ Python 3 version. %endif %changelog +* Fri Mar 29 16:13:00 CET 2019 Igor Gnatenko - 0.7.4-1 +- Update to 0.7.4 + * Tue Feb 26 2019 Pavla Kratochvilova - 0.7.2-3 - Backport: Add support for modular updateinfo.xml data diff --git a/sources b/sources index bc61345..8a4a3ae 100644 --- a/sources +++ b/sources @@ -1 +1 @@ -SHA512 (libsolv-0.7.2.tar.gz) = 4b61e63ffa71305cbbcbdb50f178fbfbf0ac6bf23f4def60221665129b75e7c4b63c48164398635a05ae17e99974b908c6db739c21625aa6946924dd81734e63 +SHA512 (libsolv-0.7.4.tar.gz) = 74507b131bf9341d9ed9ff113cb01ccd2bc0e0315e6f2361fd23939de5ef051ba6e4bf1df494989569881849b7dd8cefbefe09fba5f9774f5435cfa8ab25512d