added patches for x86_64 cohexistance with x86 packages and for openmamba kernel packages names [release 0.31.0-2mamba;Sun Jun 23 2019]

This commit is contained in:
Silvan Calarco 2024-01-06 04:07:28 +01:00
parent f2102a7a80
commit 13b37f631f
4 changed files with 79 additions and 10 deletions

View File

@ -0,0 +1,26 @@
--- libdnf-0.31.0/libdnf/hy-util.cpp.orig 2019-07-13 13:40:25.132045332 +0200
+++ libdnf-0.31.0/libdnf/hy-util.cpp 2019-07-13 13:41:53.216392596 +0200
@@ -108,23 +108,6 @@
if (uname(&un) < 0)
return DNF_ERROR_FAILED;
- if (!strncmp(un.machine, "armv", 4)) {
- /* un.machine is armvXE, where X is version number and E is
- * endianness (b or l); we need to add modifiers such as
- * h (hardfloat), n (neon), c (crypto extensions) */
- char endian = un.machine[strlen(un.machine)-1];
- char *modifier = un.machine + 5;
- while(isdigit(*modifier)) /* keep armv7, armv8, armv9, armv10, armv100, ... */
- modifier++;
- if (getauxval(AT_HWCAP) & HWCAP_ARM_VFP)
- *modifier++ = 'h';
- if (getauxval(AT_HWCAP2) & HWCAP2_AES)
- *modifier++ = 'c';
- if (getauxval(AT_HWCAP) & HWCAP_ARM_NEON)
- *modifier++ = 'n';
- *modifier++ = endian;
- *modifier = 0;
- }
#ifdef __MIPSEL__
if (!strcmp(un.machine, "mips"))
strcpy(un.machine, "mipsel");

View File

@ -0,0 +1,19 @@
--- libdnf-0.31.0/libdnf/dnf-context.cpp 2019-06-22 18:34:20.000000000 +0200
+++ libdnf-0.31.0.patched/libdnf/dnf-context.cpp 2019-06-23 19:42:26.970196883 +0200
@@ -889,8 +889,14 @@
dnf_context_get_installonly_pkgs(DnfContext *context)
{
static const gchar *installonly_pkgs[] = {
- "kernel",
- "kernel-PAE",
+ "kernel-mamba-longterm","kernel-mamba-longterm-headers",
+ "kernel-mamba-longterm-4GB","kernel-mamba-longterm-4GB-headers",
+ "kernel-mamba","kernel-mamba-headers",
+ "kernel-mamba-64GB","kernel-mamba-64GB-headers",
+ "kernel-mamba-x86_64","kernel-mamba-x86_64-headers",
+ "kernel-raspberrypi","kernel-raspberrypi-headers",
+ "kernel-rpi","kernel-rpi-headers",
+ "kernel-rpi-v7","kernel-rpi-v7-headers",
"installonlypkg(kernel)",
"installonlypkg(kernel-module)",
"installonlypkg(vm)",

View File

@ -0,0 +1,11 @@
--- libdnf-0.31.0/libdnf/goal/Goal.cpp.orig 2019-06-23 18:33:29.205434790 +0200
+++ libdnf-0.31.0/libdnf/goal/Goal.cpp 2019-06-23 19:33:44.093032736 +0200
@@ -1185,6 +1185,8 @@
solver_set_flag(solv, SOLVER_FLAG_ALLOW_VENDORCHANGE, 1);
/* don't erase packages that are no longer in repo during distupgrade */
solver_set_flag(solv, SOLVER_FLAG_KEEP_ORPHANS, 1);
+ /* x86_64: disable inferior arch check to allow x86 packages cohexistance */
+ solver_set_flag(solv, SOLVER_FLAG_NO_INFARCHCHECK, 1);
/* no arch change for forcebest */
solver_set_flag(solv, SOLVER_FLAG_BEST_OBEY_POLICY, 1);
/* support package splits via obsoletes */

View File

@ -1,6 +1,6 @@
Name: libdnf
Version: 0.26.0
Release: 1mamba
Version: 0.31.0
Release: 2mamba
Summary: Software management library
Group: System/Libraries
Vendor: openmamba
@ -13,6 +13,9 @@ Patch0: libdnf-0.33.0-gcc-8.3.0.patch
Patch1: libdnf-0.22.0-rpm5.patch
Patch2: libdnf-0.22.0-rpm5-2.patch
Patch3: libdnf-0.22.0-rpm5-additional.patch
Patch4: libdnf-0.31.0-x86_64-disable_inferior_arch_check.patch
Patch5: libdnf-0.31.0-openmamba-kernel-packages.patch
Patch6: libdnf-0.31.0-arm-detect-arch-using-uname.patch
License: LGPL
## AUTOBUILDREQ-BEGIN
BuildRequires: glibc-devel
@ -27,14 +30,15 @@ BuildRequires: libopenssl-devel
BuildRequires: libpython-devel
BuildRequires: libpython27-devel
BuildRequires: librepo-devel
BuildRequires: librpm-devel
BuildRequires: libsmartcols-devel
BuildRequires: libsolv-devel
BuildRequires: libsqlite-devel
BuildRequires: libstdc++6-devel
BuildRequires: rpm-devel
## AUTOBUILDREQ-END
BuildRequires: cmake
BuildRequires: libsolv >= 0.7.4
BuildRequires: libsolv >= 0.7.5
BuildRequires: libmodulemd >= 2.5.0
#BuildRequires: libmodulemd-devel
Provides: libhawkey
Obsoletes: libhawkey
@ -59,14 +63,17 @@ This package contains libraries and header files for developing applications tha
%prep
%setup -q
%patch0 -p1
%patch1 -p1
%patch2 -p1
%patch3 -p1
#%patch1 -p1
#%patch2 -p1
#%patch3 -p1
%ifarch x86_64
%patch4 -p1
%endif
%patch5 -p1
%patch6 -p1
%build
%cmake -d build \
-DCMAKE_CXX_FLAGS="-Doff64_t=__off64_t -Duint64_t=u_int64_t -Duint32_t=u_int32_t -Duint16_t=u_int16_t -Duint8_t=u_int8_t -I%{_includedir}/rpm" \
-DCMAKE_C_FLAGS="-Doff64_t=__off64_t -Duint64_t=u_int64_t -Duint32_t=u_int32_t -Duint16_t=u_int16_t -Duint8_t=u_int8_t -I%{_includedir}/rpm"
%cmake -d build
%make
@ -105,6 +112,12 @@ This package contains libraries and header files for developing applications tha
%doc README.md
%changelog
* Sun Jun 23 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 0.31.0-2mamba
- added patches for x86_64 cohexistance with x86 packages and for openmamba kernel packages names
* Sat Jun 22 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 0.31.0-1mamba
- update to 0.31.0
* Tue Jun 04 2019 Silvan Calarco <silvan.calarco@mambasoft.it> 0.26.0-1mamba
- update to 0.26.0