From ac84bbd0905e4618778a222e6a24d63869dde4f6 Mon Sep 17 00:00:00 2001 From: Zhao Hang Date: Wed, 15 Dec 2021 08:28:08 +0000 Subject: [PATCH 1/3] !1 Disable rhsm support in Anolis and fix platform compatibility * rebrand: fix platform compatibility * Disable rhsm support in Anolis --- 1000-anolis-fix-platform-compatibility.path | 15 +++++++++++++++ libdnf.spec | 19 ++++++++++++++++++- 2 files changed, 33 insertions(+), 1 deletion(-) create mode 100644 1000-anolis-fix-platform-compatibility.path diff --git a/1000-anolis-fix-platform-compatibility.path b/1000-anolis-fix-platform-compatibility.path new file mode 100644 index 0000000..977f72e --- /dev/null +++ b/1000-anolis-fix-platform-compatibility.path @@ -0,0 +1,15 @@ +diff -Nur libdnf-0.55.0/libdnf/module/ModulePackage.cpp libdnf-0.55.0.new/libdnf/module/ModulePackage.cpp +--- libdnf-0.55.0/libdnf/module/ModulePackage.cpp 2020-11-09 22:42:13.000000000 +0800 ++++ libdnf-0.55.0.new/libdnf/module/ModulePackage.cpp 2021-07-08 16:40:15.635247194 +0800 +@@ -580,6 +580,11 @@ + Id id = repo_add_solvable(repo); + Solvable *solvable = pool_id2solvable(pool, id); + setSovable(pool, solvable, name, stream, version, context, "noarch"); ++ if (name == "platform" and stream == "an8") ++ { ++ std::string compatible_stream = "el8"; ++ setSovable(pool, solvable, name, compatible_stream, version, context, "noarch"); ++ } + repoImpl->needs_internalizing = 1; + dnf_sack_set_provides_not_ready(moduleSack); + dnf_sack_set_considered_to_update(moduleSack); diff --git a/libdnf.spec b/libdnf.spec index 131c72b..9670b22 100644 --- a/libdnf.spec +++ b/libdnf.spec @@ -1,3 +1,4 @@ +%define anolis_release .0.1 %global libsolv_version 0.7.17 %global libmodulemd_version 2.11.2-2 %global librepo_version 1.13.1 @@ -36,7 +37,7 @@ %bcond_without python2 %endif -%if 0%{?rhel} && ! 0%{?centos} +%if 0%{?rhel} && ! 0%{?centos} && ! 0%{?anolis} %bcond_without rhsm %else %bcond_with rhsm @@ -56,7 +57,11 @@ Name: libdnf Version: %{libdnf_major_version}.%{libdnf_minor_version}.%{libdnf_micro_version} +<<<<<<< HEAD Release: 7%{?dist} +======= +Release: 3%{anolis_release}%{?dist} +>>>>>>> dc984c9 (!1 Disable rhsm support in Anolis and fix platform compatibility) Summary: Library providing simplified C and Python API to libsolv License: LGPLv2+ URL: https://github.com/rpm-software-management/libdnf @@ -87,6 +92,8 @@ Patch23: 0023-Turn-off-strict-validation-of-modulemd-documents-RhBug20048 Patch24: 0024-Add-unittest-for-setting-up-repo-with-empty-keyfile-RhBug1994614.patch Patch25: 0025-Add-getLatestModules.patch +Patch1000: 1000-anolis-fix-platform-compatibility.path + BuildRequires: cmake BuildRequires: gcc BuildRequires: gcc-c++ @@ -330,6 +337,7 @@ popd %endif %changelog +<<<<<<< HEAD * Fri Jan 14 2022 Pavla Kratochvilova - 0.63.0-7 - Rebuild with new release number @@ -344,6 +352,15 @@ popd * Tue Nov 09 2021 Pavla Kratochvilova - 0.63.0-3 - Turn off strict validation of modulemd documents (RhBug:2004853,2007166,2007167) +======= +* Wed Dec 15 2021 zhangbinchen - 0.63.0-3.0.1 +- cherry-pick [8469287] +- Disable rhsm support in Anolis +- Fix platform compatibility + +* Mon Sep 13 2021 Marek Blaha - 0.63.0-3 +- Update translations (RhBug:1961634) +>>>>>>> dc984c9 (!1 Disable rhsm support in Anolis and fix platform compatibility) * Tue Jul 27 2021 Pavla Kratochvilova - 0.63.0-2 - Fix: dnf_context_module_install: memory leaks -- Gitee From 12f798b5349da11d67e19935c6ae02347478252a Mon Sep 17 00:00:00 2001 From: Liwei Ge Date: Thu, 23 Dec 2021 16:30:20 +0800 Subject: [PATCH 2/3] module: fix platform compatibility with centos Signed-off-by: Liwei Ge Signed-off-by: yunqi.zwt --- 1000-anolis-fix-platform-compatibility.path | 7 ++++++- libdnf.spec | 19 +++++++++---------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/1000-anolis-fix-platform-compatibility.path b/1000-anolis-fix-platform-compatibility.path index 977f72e..b470693 100644 --- a/1000-anolis-fix-platform-compatibility.path +++ b/1000-anolis-fix-platform-compatibility.path @@ -1,7 +1,7 @@ diff -Nur libdnf-0.55.0/libdnf/module/ModulePackage.cpp libdnf-0.55.0.new/libdnf/module/ModulePackage.cpp --- libdnf-0.55.0/libdnf/module/ModulePackage.cpp 2020-11-09 22:42:13.000000000 +0800 +++ libdnf-0.55.0.new/libdnf/module/ModulePackage.cpp 2021-07-08 16:40:15.635247194 +0800 -@@ -580,6 +580,11 @@ +@@ -580,6 +580,16 @@ Id id = repo_add_solvable(repo); Solvable *solvable = pool_id2solvable(pool, id); setSovable(pool, solvable, name, stream, version, context, "noarch"); @@ -9,6 +9,11 @@ diff -Nur libdnf-0.55.0/libdnf/module/ModulePackage.cpp libdnf-0.55.0.new/libdnf + { + std::string compatible_stream = "el8"; + setSovable(pool, solvable, name, compatible_stream, version, context, "noarch"); ++ } ++ if (name == "platform" and stream == "el8") ++ { ++ std::string compatible_stream = "an8"; ++ setSovable(pool, solvable, name, compatible_stream, version, context, "noarch"); + } repoImpl->needs_internalizing = 1; dnf_sack_set_provides_not_ready(moduleSack); diff --git a/libdnf.spec b/libdnf.spec index 9670b22..515f851 100644 --- a/libdnf.spec +++ b/libdnf.spec @@ -1,4 +1,4 @@ -%define anolis_release .0.1 +%define anolis_release .0.2 %global libsolv_version 0.7.17 %global libmodulemd_version 2.11.2-2 %global librepo_version 1.13.1 @@ -57,11 +57,8 @@ Name: libdnf Version: %{libdnf_major_version}.%{libdnf_minor_version}.%{libdnf_micro_version} -<<<<<<< HEAD Release: 7%{?dist} -======= Release: 3%{anolis_release}%{?dist} ->>>>>>> dc984c9 (!1 Disable rhsm support in Anolis and fix platform compatibility) Summary: Library providing simplified C and Python API to libsolv License: LGPLv2+ URL: https://github.com/rpm-software-management/libdnf @@ -337,13 +334,19 @@ popd %endif %changelog -<<<<<<< HEAD + * Fri Jan 14 2022 Pavla Kratochvilova - 0.63.0-7 - Rebuild with new release number * Tue Jan 11 2022 Pavla Kratochvilova - 0.63.0-6 - Add getLatestModules() +* Thu Dec 23 2021 Liwei Ge - 0.63.0-3.0.2 +- Fix platform compatibility with centos + +* Wed Dec 15 2021 Zhao Hang - 0.63.0-3 +- !1 Disable rhsm support in Anolis and fix platform compatibility + * Mon Nov 29 2021 Pavla Kratochvilova - 0.63.0-5 - Add unittest for setting up repo with empty keyfile (RhBug:1994614) @@ -352,16 +355,12 @@ popd * Tue Nov 09 2021 Pavla Kratochvilova - 0.63.0-3 - Turn off strict validation of modulemd documents (RhBug:2004853,2007166,2007167) -======= + * Wed Dec 15 2021 zhangbinchen - 0.63.0-3.0.1 - cherry-pick [8469287] - Disable rhsm support in Anolis - Fix platform compatibility -* Mon Sep 13 2021 Marek Blaha - 0.63.0-3 -- Update translations (RhBug:1961634) ->>>>>>> dc984c9 (!1 Disable rhsm support in Anolis and fix platform compatibility) - * Tue Jul 27 2021 Pavla Kratochvilova - 0.63.0-2 - Fix: dnf_context_module_install: memory leaks - covscan: remove unused vars, mark private func static, return values -- Gitee From a090811f8703547fdb9186510c542fec760dc1ce Mon Sep 17 00:00:00 2001 From: liuxiaoping Date: Sun, 24 Apr 2022 15:52:57 +0800 Subject: [PATCH 3/3] update to libdnf-0.63.0 --- libdnf.spec | 6 ------ 1 file changed, 6 deletions(-) diff --git a/libdnf.spec b/libdnf.spec index 515f851..d852fe9 100644 --- a/libdnf.spec +++ b/libdnf.spec @@ -334,7 +334,6 @@ popd %endif %changelog - * Fri Jan 14 2022 Pavla Kratochvilova - 0.63.0-7 - Rebuild with new release number @@ -356,11 +355,6 @@ popd * Tue Nov 09 2021 Pavla Kratochvilova - 0.63.0-3 - Turn off strict validation of modulemd documents (RhBug:2004853,2007166,2007167) -* Wed Dec 15 2021 zhangbinchen - 0.63.0-3.0.1 -- cherry-pick [8469287] -- Disable rhsm support in Anolis -- Fix platform compatibility - * Tue Jul 27 2021 Pavla Kratochvilova - 0.63.0-2 - Fix: dnf_context_module_install: memory leaks - covscan: remove unused vars, mark private func static, return values -- Gitee