* [PATCH v12 1/8] package_rpm.bbclass: Drop external dependency generator to support rpm 6
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 2/8] package_rpm.bbclass: Define _lib and _libdir for rpmbuild Sumanth Gavini
` (7 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
The rpm 6 doesn't support external dependency generator. Oe-core used it for
per file dependency which was saved into pn.requires and pn.provides,but that
hasn't been used any more since 2012 (rev:
be40f6d0bb80274366af00461112af65687a4de8), and there were no complains or
updates in the past 13 years, so just drop it to support rpm 6.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/classes-global/package_rpm.bbclass | 84 +------------------------
1 file changed, 3 insertions(+), 81 deletions(-)
diff --git a/meta/classes-global/package_rpm.bbclass b/meta/classes-global/package_rpm.bbclass
index 9eacd91cbc..f286d3a0e2 100644
--- a/meta/classes-global/package_rpm.bbclass
+++ b/meta/classes-global/package_rpm.bbclass
@@ -14,10 +14,6 @@ RPMBUILD_COMPMODE ?= "${@'w%dT%d.zstdio' % (int(d.getVar('ZSTD_COMPRESSION_LEVEL
PKGWRITEDIRRPM = "${WORKDIR}/deploy-rpms"
-# Maintaining the perfile dependencies has significant overhead when writing the
-# packages. When set, this value merges them for efficiency.
-MERGEPERFILEDEPS = "1"
-
# Filter dependencies based on a provided function.
def filter_deps(var, f):
import collections
@@ -36,67 +32,6 @@ def filter_nativesdk_deps(srcname, var):
var = filter_deps(var, lambda dep: not dep.startswith('/') and dep != 'perl' and not dep.startswith('perl('))
return var
-# Construct per file dependencies file
-def write_rpm_perfiledata(srcname, d):
- import oe.package
- workdir = d.getVar('WORKDIR')
- packages = d.getVar('PACKAGES')
- pkgd = d.getVar('PKGD')
-
- def dump_filerdeps(varname, outfile, d):
- outfile.write("#!/usr/bin/env python3\n\n")
- outfile.write("# Dependency table\n")
- outfile.write('deps = {\n')
- for pkg in packages.split():
- dependsflist_key = 'FILE' + varname + 'FLIST' + ":" + pkg
- dependsflist = (d.getVar(dependsflist_key) or "")
- for dfile in dependsflist.split():
- key = "FILE" + varname + ":" + dfile + ":" + pkg
- deps = filter_nativesdk_deps(srcname, d.getVar(key) or "")
- depends_dict = bb.utils.explode_dep_versions(deps)
- file = oe.package.file_reverse_translate(dfile)
- outfile.write('"' + pkgd + file + '" : "')
- for dep in depends_dict:
- ver = depends_dict[dep]
- if dep and ver:
- ver = ver.replace("(", "")
- ver = ver.replace(")", "")
- outfile.write(dep + " " + ver + " ")
- else:
- outfile.write(dep + " ")
- outfile.write('",\n')
- outfile.write('}\n\n')
- outfile.write("import sys\n")
- outfile.write("while 1:\n")
- outfile.write("\tline = sys.stdin.readline().strip()\n")
- outfile.write("\tif not line:\n")
- outfile.write("\t\tsys.exit(0)\n")
- outfile.write("\tif line in deps:\n")
- outfile.write("\t\tprint(deps[line] + '\\n')\n")
-
- # OE-core dependencies a.k.a. RPM requires
- outdepends = workdir + "/" + srcname + ".requires"
-
- dependsfile = open(outdepends, 'w')
-
- dump_filerdeps('RDEPENDS', dependsfile, d)
-
- dependsfile.close()
- os.chmod(outdepends, 0o755)
-
- # OE-core / RPM Provides
- outprovides = workdir + "/" + srcname + ".provides"
-
- providesfile = open(outprovides, 'w')
-
- dump_filerdeps('RPROVIDES', providesfile, d)
-
- providesfile.close()
- os.chmod(outprovides, 0o755)
-
- return (outdepends, outprovides)
-
-
python write_specfile () {
import oe.packagedata
import os,pwd,grp,stat
@@ -311,7 +246,6 @@ python write_specfile () {
spec_files_top = []
spec_files_bottom = []
- perfiledeps = (d.getVar("MERGEPERFILEDEPS") or "0") == "0"
extra_pkgdata = (d.getVar("RPM_EXTRA_PKGDATA") or "0") == "1"
for pkg in packages.split():
@@ -365,10 +299,9 @@ python write_specfile () {
splitrpostrm = localdata.getVar('pkg_postrm')
- if not perfiledeps:
- # Add in summary of per file dependencies
- splitrdepends = splitrdepends + " " + get_perfile('RDEPENDS', pkg, d)
- splitrprovides = splitrprovides + " " + get_perfile('RPROVIDES', pkg, d)
+ # Add in summary of per file dependencies
+ splitrdepends = splitrdepends + " " + get_perfile('RDEPENDS', pkg, d)
+ splitrprovides = splitrprovides + " " + get_perfile('RPROVIDES', pkg, d)
splitrdepends = filter_nativesdk_deps(srcname, splitrdepends)
@@ -630,10 +563,6 @@ python do_package_rpm () {
d.setVar('OUTSPECFILE', outspecfile)
bb.build.exec_func('write_specfile', d)
- perfiledeps = (d.getVar("MERGEPERFILEDEPS") or "0") == "0"
- if perfiledeps:
- outdepends, outprovides = write_rpm_perfiledata(srcname, d)
-
# Setup the rpmbuild arguments...
rpmbuild = d.getVar('RPMBUILD')
rpmbuild_compmode = d.getVar('RPMBUILD_COMPMODE')
@@ -658,7 +587,6 @@ python do_package_rpm () {
cmd = cmd + " --define '_topdir " + workdir + "' --define '_rpmdir " + pkgwritedir + "'"
cmd = cmd + " --define '_builddir " + d.getVar('B') + "'"
cmd = cmd + " --define '_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm'"
- cmd = cmd + " --define '_use_internal_dependency_generator 0'"
cmd = cmd + " --define '_binaries_in_noarch_packages_terminate_build 0'"
cmd = cmd + " --define '_build_id_links none'"
cmd = cmd + " --define '_smp_ncpus_max 4'"
@@ -668,12 +596,6 @@ python do_package_rpm () {
cmd = cmd + " --define 'use_source_date_epoch_as_buildtime 1'"
cmd = cmd + " --define '_buildhost reproducible'"
cmd = cmd + " --define '__font_provides %{nil}'"
- if perfiledeps:
- cmd = cmd + " --define '__find_requires " + outdepends + "'"
- cmd = cmd + " --define '__find_provides " + outprovides + "'"
- else:
- cmd = cmd + " --define '__find_requires %{nil}'"
- cmd = cmd + " --define '__find_provides %{nil}'"
cmd = cmd + " --define '_unpackaged_files_terminate_build 0'"
cmd = cmd + " --define 'debug_package %{nil}'"
cmd = cmd + " --define '_tmppath " + workdir + "'"
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 2/8] package_rpm.bbclass: Define _lib and _libdir for rpmbuild
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 1/8] package_rpm.bbclass: Drop external dependency generator to support rpm 6 Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 3/8] lib/oe/package.py: Don't add ldconfig_postinst_fragment for glibc or musl Sumanth Gavini
` (6 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
The rpmbuild is from rpm-native, the lib and _libdir may be
incorrect for target, for example:
* rpm 4.20.1:
No pkg-config files can be found for qemux86-64 or qemuarm64
* rpm 6.0.2:
- qemux86-64: The _lib is lib64, this is incorrect when multilib is not
enabled, and _libdir is RECIPE_SYSROOT_NATIVE/usr/lib,this
makes the pkg-config files can't be matched.
- qemuarm64/qemux86: The _lib is lib64, this is incorrect, but _libdir is
correct (/usr/lib), so the pkg-config files can be found,
this also looks wild.
The rpmbuild is like cross build, define the values when run it can fix the
problems for rpm 6.0.2.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/classes-global/package_rpm.bbclass | 2 ++
1 file changed, 2 insertions(+)
diff --git a/meta/classes-global/package_rpm.bbclass b/meta/classes-global/package_rpm.bbclass
index f286d3a0e2..9af4cbdd94 100644
--- a/meta/classes-global/package_rpm.bbclass
+++ b/meta/classes-global/package_rpm.bbclass
@@ -585,6 +585,8 @@ python do_package_rpm () {
cmd = rpmbuild
cmd = cmd + " --noclean --nodeps --short-circuit --target " + pkgarch + " --buildroot " + pkgd
cmd = cmd + " --define '_topdir " + workdir + "' --define '_rpmdir " + pkgwritedir + "'"
+ cmd = cmd + " --define '_lib ${BASELIB}'"
+ cmd = cmd + " --define '_libdir ${libdir}'"
cmd = cmd + " --define '_builddir " + d.getVar('B') + "'"
cmd = cmd + " --define '_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm'"
cmd = cmd + " --define '_binaries_in_noarch_packages_terminate_build 0'"
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 3/8] lib/oe/package.py: Don't add ldconfig_postinst_fragment for glibc or musl
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 1/8] package_rpm.bbclass: Drop external dependency generator to support rpm 6 Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 2/8] package_rpm.bbclass: Define _lib and _libdir for rpmbuild Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 4/8] lib/oe/package.py: Don't redirect stderr Sumanth Gavini
` (5 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
Fixed:
$ bitbake core-image-full-cmdline:do_testimage
%post(busybox-1.38.0-r0.x86_64_v3): execv(/bin/sh) pid 679
error: failed to exec scriptlet interpreter /bin/sh: No such file or directory
It is because busybox and libc6 depends on each other, busybox' elf files
depends on libc6, and libc6's postin depends on busybox' /bin/sh, the do_rootfs
works well is because dnf-native has set RPM_NO_CHROOT_FOR_SCRIPTS=1, but it
would be failed without it.
In rpm 4.20.1, it let the installed files' Requires win, so it installed
busybox firstly, but in rpm 6.0.1, it let the postin's Requires win since
postin would run immediately after the files are installed, this does make
sense, so it installed busybox (which provides /bin/sh required by libc6'
postin) firstly, then we got the errors. I couldn't find which commit made this
change because a lot of files and functions are refactored during 4.20.1 and
6.0.0 (not .1), I also tried bisect, but failed because a lot of do_patch or
do_configure/do_compile failures for each build.
For libc6's the postin is:
#!/bin/sh
if [ x"$D" = "x" ]; then
if [ -x /sbin/ldconfig ]; then /sbin/ldconfig ; fi
fi
This doesn't make sense for libc6 since there is no /bin/sh or ldconfig when
libc6 is not ready yet, so just not add ldconfig_postinst_fragment for glibc
to fix the problem.
And also remove the workarounds in oeqa/runtime/cases/dnf.py, they are not
needed any more since the loop dependency is fixed.
Similar to musl.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/lib/oe/package.py | 3 ++-
meta/recipes-core/glibc/glibc-package.inc | 5 +++++
meta/recipes-core/musl/musl_git.bb | 4 ++++
3 files changed, 11 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py
index d047e41a78..8ccd89a190 100644
--- a/meta/lib/oe/package.py
+++ b/meta/lib/oe/package.py
@@ -1853,7 +1853,8 @@ def process_shlibs(pkgfiles, d):
if s[0] not in shlib_provider:
shlib_provider[s[0]] = {}
shlib_provider[s[0]][s[1]] = (pkg, pkgver)
- if needs_ldconfig:
+ if needs_ldconfig and \
+ not bb.utils.to_boolean(d.getVar('SKIP_LDCONFIG_POSTINST_FRAGMENT:%s' % pkg)):
bb.debug(1, 'adding ldconfig call to postinst for %s' % pkg)
postinst = d.getVar('pkg_postinst:%s' % pkg)
if not postinst:
diff --git a/meta/recipes-core/glibc/glibc-package.inc b/meta/recipes-core/glibc/glibc-package.inc
index 3d721d8f69..bea841b047 100644
--- a/meta/recipes-core/glibc/glibc-package.inc
+++ b/meta/recipes-core/glibc/glibc-package.inc
@@ -298,6 +298,11 @@ pkg_postinst:nscd () {
fi
fi
}
+
+# Avoid loop dependencies between /bin/sh and libc.so.6
+SKIP_LDCONFIG_POSTINST_FRAGMENT:${PN} = "1"
+do_package[vardeps] += "SKIP_LDCONFIG_POSTINST_FRAGMENT:${PN}"
+
CONFFILES:nscd = "${sysconfdir}/nscd.conf"
SYSTEMD_PACKAGES = "nscd"
diff --git a/meta/recipes-core/musl/musl_git.bb b/meta/recipes-core/musl/musl_git.bb
index 3aec643c40..057113bf16 100644
--- a/meta/recipes-core/musl/musl_git.bb
+++ b/meta/recipes-core/musl/musl_git.bb
@@ -80,4 +80,8 @@ LEAD_SONAME = "libc.so"
INSANE_SKIP:${PN}-dev = "staticdev"
INSANE_SKIP:${PN} = "libdir"
+# Avoid loop dependencies between /bin/sh and libc.so
+SKIP_LDCONFIG_POSTINST_FRAGMENT:${PN} = "1"
+do_package[vardeps] += "SKIP_LDCONFIG_POSTINST_FRAGMENT:${PN}"
+
UPSTREAM_CHECK_COMMITS = "1"
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 4/8] lib/oe/package.py: Don't redirect stderr
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (2 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 3/8] lib/oe/package.py: Don't add ldconfig_postinst_fragment for glibc or musl Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 5/8] target-sdk-provides-dummy: Add pkg-config to DUMMYPROVIDES Sumanth Gavini
` (4 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
This can make the debug easier.
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/lib/oe/package.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/meta/lib/oe/package.py b/meta/lib/oe/package.py
index 8ccd89a190..d8862ae92d 100644
--- a/meta/lib/oe/package.py
+++ b/meta/lib/oe/package.py
@@ -277,7 +277,7 @@ def filedeprunner(pkg, pkgfiles, rpmdeps, pkgdest):
return provides, requires
- output = subprocess.check_output(shlex.split(rpmdeps) + pkgfiles, stderr=subprocess.STDOUT).decode("utf-8")
+ output = subprocess.check_output(shlex.split(rpmdeps) + pkgfiles).decode("utf-8")
provides, requires = process_deps(output, pkg, pkgdest, provides, requires)
return (pkg, provides, requires)
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 5/8] target-sdk-provides-dummy: Add pkg-config to DUMMYPROVIDES
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (3 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 4/8] lib/oe/package.py: Don't redirect stderr Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 6/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (3 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
The rpm package requires /usr/bin/pkg-config when it has .pc files.
Fixed:
1) target-sdk-provides-dummy.bb:
- package acl-dev-2.3.2-r0.core2_64 from oe-repo requires
/usr/bin/pkg-config, but none of the providers can be installed
2) nativesdk-sdk-provides-dummy.bb:
- package nativesdk-wayland-dev-1.24.0-r0.x86_64_nativesdk from
oe-repo requires /usr/bin/pkg-config, but none of the providers can be installed
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/recipes-core/meta/nativesdk-sdk-provides-dummy.bb | 1 +
meta/recipes-core/meta/target-sdk-provides-dummy.bb | 1 +
2 files changed, 2 insertions(+)
diff --git a/meta/recipes-core/meta/nativesdk-sdk-provides-dummy.bb b/meta/recipes-core/meta/nativesdk-sdk-provides-dummy.bb
index 37dad54409..6075770bf0 100644
--- a/meta/recipes-core/meta/nativesdk-sdk-provides-dummy.bb
+++ b/meta/recipes-core/meta/nativesdk-sdk-provides-dummy.bb
@@ -11,6 +11,7 @@ DUMMYPROVIDES = "\
/bin/sh \
/bin/bash \
/usr/bin/env \
+ /usr/bin/pkg-config \
libGL.so()(64bit) \
libGL.so \
"
diff --git a/meta/recipes-core/meta/target-sdk-provides-dummy.bb b/meta/recipes-core/meta/target-sdk-provides-dummy.bb
index 65b87fd97d..ca155d0705 100644
--- a/meta/recipes-core/meta/target-sdk-provides-dummy.bb
+++ b/meta/recipes-core/meta/target-sdk-provides-dummy.bb
@@ -54,6 +54,7 @@ DUMMYPROVIDES = "\
/bin/bash \
/usr/bin/env \
/usr/bin/perl \
+ /usr/bin/pkg-config \
libperl.so.5 \
libperl.so.5()(64bit) \
"
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 6/8] rpm: 4.20.1 -> 6.0.2
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (4 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 5/8] target-sdk-provides-dummy: Add pkg-config to DUMMYPROVIDES Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 7/8] libarchive: Make it work with rpm 6.0.2 Sumanth Gavini
` (2 subsequent siblings)
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
* Add a tag to SRC_URI so that there will be errors when only change the
filename during upgrade it, as suggested by Alexander.
* Rebase the following patch:
- 0001-Add-a-color-setting-for-mips64_n32-binaries.patch
- 0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch
- 0001-Do-not-read-config-files-from-HOME.patch
- 0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
- 0001-When-cross-installing-execute-package-scriptlets-wit.patch
- 0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch
- 0001-lib-transaction.c-fix-file-conflicts-for-MIPS64-N32.patch
- 0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch
- 0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch
- 0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch
* Updated
0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
Remove the changes for macros.in since it doesn't work for rpmbuild, rpmbuild
is like cross build, will define the values in package_rpm.bbclass.
* Remove
0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch, there
are no such warnings in rpm 6.0.2.
* Remove backported patch
0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch
* Add the following patches:
- 0001-tools-elfdeps.cc-Remove-format-module.patch
There is no format until gcc 13.1, so remove the format module to make it
work on hosts such as Ubuntu 22.04.
- 0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch
Fixed:
GPG check FAILED
* Fix filter /usr/bin/pkg-config file dependency
pkg-config is a build-time tool, not a runtime dependency. Filter the
/usr/bin/pkg-config file dependency that RPM pkgconfig.attr
auto-detects for packages with .pc files, preventing unnecessary
hard dependencies in -dev packages.
* Add scdoc-native to DEPENDS to fix do_configure error for both native and
target:
Could not find SCDOC using the following names: scdoc
Note, both target and native need scdoc-native, it is used for generating the
manual, the man pages in *man/* are scdoc sources
* Add /etc/rpm to nativesdk-rpm to fix:
ERROR: nativesdk-rpm-1_6.0.1-r0 do_package: QA Issue: nativesdk-rpm:
Files/directories were installed but not shipped in any package:
/etc
/etc/rpm
* Add /etc/rpm to nativesdk-rpm to fix:
* Fix build with systemd, the rpm's sysuser creation doesn't work with
cross build, and we don't need rpm to create the users since we have
useradd.bbclass. The fix is:
cmd = cmd + " --define '__sysusers_path %{nil}'"
The error is:
/var/tmp/rpm-tmp.U4iaJX: line 114: tr: command not found
* Make rpmbuild can find the pkgconfig (.pc) files in
/usr/share/pkgconfig:
cmd = cmd + " --define '_datadir ${datadir}'"
The error is:
- nothing provides pkgconfig(shared-mime-info) needed by libgdk-pixbuf-2.0-dev-2.44.5-r0.x86_6
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
meta/classes-global/package_rpm.bbclass | 4 ++
...olor-setting-for-mips64_n32-binaries.patch | 22 ++++----
...akeLists.txt-Fix-checking-for-CFLAGS.patch | 46 -----------------
...et-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch | 50 -------------------
...satisfiable-dependency-when-building.patch | 18 ++++---
...lib-rpm-as-the-installation-path-for.patch | 24 +++------
...1-Do-not-read-config-files-from-HOME.patch | 18 ++++---
...-PATH-environment-variable-before-ru.patch | 16 +++---
...lling-execute-package-scriptlets-wit.patch | 12 +++--
...not-insert-payloadflags-into-.rpm-me.patch | 18 ++++---
....c-fix-file-conflicts-for-MIPS64-N32.patch | 18 ++++---
...kgverify_level-to-digest-as-RCPM-4.2.patch | 35 +++++++++++++
...ools-elfdeps.cc-Remove-format-module.patch | 38 ++++++++++++++
...prefixing-etc-from-RPM_ETCCONFIGDIR-.patch | 26 ++++++----
...avoid-using-GLOB_BRACE-if-undefined-.patch | 14 ++++--
...ge-logging-level-around-scriptlets-t.patch | 14 +++---
.../rpm/{rpm_4.20.1.bb => rpm_6.0.2.bb} | 14 +++---
17 files changed, 199 insertions(+), 188 deletions(-)
delete mode 100644 meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch
delete mode 100644 meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch
create mode 100644 meta/recipes-devtools/rpm/files/0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch
create mode 100644 meta/recipes-devtools/rpm/files/0001-tools-elfdeps.cc-Remove-format-module.patch
rename meta/recipes-devtools/rpm/{rpm_4.20.1.bb => rpm_6.0.2.bb} (96%)
diff --git a/meta/classes-global/package_rpm.bbclass b/meta/classes-global/package_rpm.bbclass
index 9af4cbdd94..51ad195baa 100644
--- a/meta/classes-global/package_rpm.bbclass
+++ b/meta/classes-global/package_rpm.bbclass
@@ -587,6 +587,7 @@ python do_package_rpm () {
cmd = cmd + " --define '_topdir " + workdir + "' --define '_rpmdir " + pkgwritedir + "'"
cmd = cmd + " --define '_lib ${BASELIB}'"
cmd = cmd + " --define '_libdir ${libdir}'"
+ cmd = cmd + " --define '_datadir ${datadir}'"
cmd = cmd + " --define '_builddir " + d.getVar('B') + "'"
cmd = cmd + " --define '_build_name_fmt %%{NAME}-%%{VERSION}-%%{RELEASE}.%%{ARCH}.rpm'"
cmd = cmd + " --define '_binaries_in_noarch_packages_terminate_build 0'"
@@ -601,6 +602,7 @@ python do_package_rpm () {
cmd = cmd + " --define '_unpackaged_files_terminate_build 0'"
cmd = cmd + " --define 'debug_package %{nil}'"
cmd = cmd + " --define '_tmppath " + workdir + "'"
+ cmd = cmd + " --define '__sysusers_path %{nil}'"
cmd = cmd + " --define '_use_weak_usergroup_deps 1'"
cmd = cmd + " --define '_passwd_path " + "/completely/bogus/path" + "'"
cmd = cmd + " --define '_group_path " + "/completely/bogus/path" + "'"
@@ -622,6 +624,8 @@ python do_package_rpm () {
python () {
if d.getVar('PACKAGES') != '':
deps = ' rpm-native:do_populate_sysroot virtual/fakeroot-native:do_populate_sysroot'
+ # The pkgconfig-native is required by rpm's pkgconfigdeps.sh
+ deps += ' pkgconfig-native:do_populate_sysroot'
d.appendVarFlag('do_package_write_rpm', 'depends', deps)
d.setVarFlag('do_package_write_rpm', 'fakeroot', '1')
diff --git a/meta/recipes-devtools/rpm/files/0001-Add-a-color-setting-for-mips64_n32-binaries.patch b/meta/recipes-devtools/rpm/files/0001-Add-a-color-setting-for-mips64_n32-binaries.patch
index 769d7b3409..a808009058 100644
--- a/meta/recipes-devtools/rpm/files/0001-Add-a-color-setting-for-mips64_n32-binaries.patch
+++ b/meta/recipes-devtools/rpm/files/0001-Add-a-color-setting-for-mips64_n32-binaries.patch
@@ -5,16 +5,20 @@ Subject: [PATCH] Add a color setting for mips64_n32 binaries
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- build/rpmfc.c | 4 ++++
+ build/rpmfc.cc | 4 ++++
rpmrc.in | 2 ++
2 files changed, 6 insertions(+)
-diff --git a/build/rpmfc.c b/build/rpmfc.c
-index 86dd36d14..df421a23f 100644
---- a/build/rpmfc.c
-+++ b/build/rpmfc.c
-@@ -716,6 +716,7 @@ static int rpmfcHelper(rpmfc fc, int *fnx, int nfn, const char *proto,
+diff --git a/build/rpmfc.cc b/build/rpmfc.cc
+index 833e56fa8..d50a3407f 100644
+--- a/build/rpmfc.cc
++++ b/build/rpmfc.cc
+@@ -690,6 +690,7 @@ static int rpmfcHelper(rpmfc fc, int *fnx, int nfn, const char *proto,
static const struct rpmfcTokens_s rpmfcTokens[] = {
{ "directory", RPMFC_INCLUDE },
@@ -22,7 +26,7 @@ index 86dd36d14..df421a23f 100644
{ "ELF 32-bit", RPMFC_ELF32|RPMFC_INCLUDE },
{ "ELF 64-bit", RPMFC_ELF64|RPMFC_INCLUDE },
-@@ -1258,6 +1259,9 @@ static uint32_t getElfColor(const char *fn)
+@@ -1191,6 +1192,9 @@ static uint32_t getElfColor(const char *fn)
color = 0;
break;
}
@@ -33,10 +37,10 @@ index 86dd36d14..df421a23f 100644
if (elf)
elf_end(elf);
diff --git a/rpmrc.in b/rpmrc.in
-index 8646a966b..7349fdfd3 100644
+index 8fd0d7ee1..4cc52ceb3 100644
--- a/rpmrc.in
+++ b/rpmrc.in
-@@ -142,6 +142,8 @@ archcolor: mipsr6el 1
+@@ -152,6 +152,8 @@ archcolor: mipsr6el 1
archcolor: mips64r6 2
archcolor: mips64r6el 2
diff --git a/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch b/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch
deleted file mode 100644
index 412e1c146d..0000000000
--- a/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch
+++ /dev/null
@@ -1,46 +0,0 @@
-From e14502834fe6a9c6c9a439401ac3d2c8fd979267 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Sun, 8 Jun 2025 00:36:38 -0700
-Subject: [PATCH] CMakeLists.txt: Improve checking for CFLAGS
-
-The previous log wasn't clear:
--- Performing Test found
--- Performing Test found - Success
--- Performing Test found
--- Performing Test found - Success
--- Performing Test found
--- Performing Test found - Failed
-
-Use a new var compiler-supports${flag} will make it more clear:
--- Performing Test compiler-supports-fno-strict-overflow
--- Performing Test compiler-supports-fno-strict-overflow - Success
--- Performing Test compiler-supports-fno-delete-null-pointer-checks
--- Performing Test compiler-supports-fno-delete-null-pointer-checks - Success
--- Performing Test compiler-supports-fhardened
--- Performing Test compiler-supports-fhardened - Failed
-
-Upstream-Status: Backport [https://github.com/rpm-software-management/rpm/commit/e14502834fe6a9c6c9a439401ac3d2c8fd979267]
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- CMakeLists.txt | 5 ++---
- 1 file changed, 2 insertions(+), 3 deletions(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 08e3e5274..f275c396b 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -416,11 +416,10 @@ endif()
-
- # try to ensure some compiler sanity and hardening options where supported
- foreach (flag -fno-strict-overflow -fno-delete-null-pointer-checks -fhardened)
-- check_c_compiler_flag(${flag} found)
-- if (found)
-+ check_c_compiler_flag(${flag} compiler-supports${flag})
-+ if (compiler-supports${flag})
- add_compile_options(${flag})
- endif()
-- unset(found)
- endforeach()
-
- # generated sources
diff --git a/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch b/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch
deleted file mode 100644
index 7db643871f..0000000000
--- a/meta/recipes-devtools/rpm/files/0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch
+++ /dev/null
@@ -1,50 +0,0 @@
-From cb5355da9b47166253dbe5ab3215e433b55068d1 Mon Sep 17 00:00:00 2001
-From: Yi Zhao <yi.zhao@windriver.com>
-Date: Fri, 26 Jul 2024 17:18:30 +0800
-Subject: [PATCH] CMakeLists.txt: set libdir to ${CMAKE_INSTALL_FULL_LIBDIR} in
- macros
-
-There is a patch in oe-core[1] to avoid hardcoded paths in macros. It
-tries to use libdir to expand %_libdir in macros.in. However, in
-upstream commit[2], libdir for macros in CMakeLists.txt is set to
-${prefix}/=LIB=, which causes %_libdir to expand to ${prefix}/=LIB=
-instead of the correct path in the final macros.
-
-On target:
-$ rpm --showrc | grep _libdir
-[snip]
--13: _libdir ${prefix}/=LIB=
-[snip]
-
-This also causes %__pkgconfig_path in fileattrs/pkgconfig.attr to become
-an invalid regular expression when building rpm packages. This results a
-warning in log.do_package_write_rpm in all packages:
-
-Warning: Ignoring invalid regular expression ^((${prefix}/=LIB=|usr/share)/pkgconfig/.*.pc|usr/bin/pkg-config)$
-
-Set libdir to ${CMAKE_INSTALL_FULL_LIBDIR} instead of ${prefix}/=LIB= to
-make sure it is expanded to the correct path in macros.
-
-[1] https://git.openembedded.org/openembedded-core/tree/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
-[2] https://github.com/rpm-software-management/rpm/commit/d2abb7a48760418aacd7f17c8b64e39c25ca50c9
-
-Upstream-Status: Inappropriate [oe specific]
-
-Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
----
- CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/CMakeLists.txt b/CMakeLists.txt
-index 08dabffd3..1b7661139 100644
---- a/CMakeLists.txt
-+++ b/CMakeLists.txt
-@@ -96,7 +96,7 @@ function(makemacros)
- set(sysconfdir "${CMAKE_INSTALL_FULL_SYSCONFDIR}")
- set(sharedstatedir "${CMAKE_INSTALL_FULL_SHAREDSTATEDIR}")
- set(localstatedir "${CMAKE_INSTALL_FULL_LOCALSTATEDIR}")
-- set(libdir "\${prefix}/=LIB=")
-+ set(libdir "${CMAKE_INSTALL_FULL_LIBDIR}")
- set(includedir "\${prefix}/${CMAKE_INSTALL_INCLUDEDIR}")
- set(oldincludedir "${CMAKE_INSTALL_FULL_OLDINCLUDEDIR}")
- set(infodir "\${prefix}/${CMAKE_INSTALL_INFODIR}")
diff --git a/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch b/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch
index 96a5e14999..63a10df0d5 100644
--- a/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch
+++ b/meta/recipes-devtools/rpm/files/0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch
@@ -9,16 +9,20 @@ hand produces rpms that way by design.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- build/pack.c | 4 ----
+ build/pack.cc | 4 ----
1 file changed, 4 deletions(-)
-diff --git a/build/pack.c b/build/pack.c
-index eb9c7b3f1..fb1f1bed8 100644
---- a/build/pack.c
-+++ b/build/pack.c
-@@ -712,10 +712,6 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch
- headerPutBin(pkg->header, RPMTAG_SOURCEPKGID, spec->sourcePkgId,16);
+diff --git a/build/pack.cc b/build/pack.cc
+index 49c9d0a58..b1cda6d75 100644
+--- a/build/pack.cc
++++ b/build/pack.cc
+@@ -805,10 +805,6 @@ static rpmRC packageBinary(rpmSpec spec, Package pkg, const char *cookie, int ch
+ headerPutBin(pkg->header, RPMTAG_SOURCESIGMD5, spec->sourcePkgId,16);
}
- if (cheating) {
diff --git a/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch b/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
index 6a44f4f22d..309320cf43 100644
--- a/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
+++ b/meta/recipes-devtools/rpm/files/0001-Do-not-hardcode-lib-rpm-as-the-installation-path-for.patch
@@ -6,10 +6,16 @@ Subject: [PATCH] Do not hardcode "lib/rpm" as the installation path for
Upstream-Status: Denied [https://github.com/rpm-software-management/rpm/pull/263]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Updated for rpm 6.0.2:
+Remove the changes for macros.in since it doesn't work for rpmbuild, rpmbuild
+is like cross build, will define the values in package_rpm.bbclass.
+
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
CMakeLists.txt | 2 +-
- macros.in | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
+ 1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/CMakeLists.txt b/CMakeLists.txt
index de0b578a6..9a3aba071 100644
@@ -23,17 +29,3 @@ index de0b578a6..9a3aba071 100644
+set(RPM_CONFIGDIR "${CMAKE_INSTALL_PREFIX}/${CMAKE_INSTALL_LIBDIR}/rpm" CACHE PATH "rpm home")
set(RPM_MACROSDIR "${RPM_CONFIGDIR}/macros.d")
set(RPM_VENDOR "vendor" CACHE STRING "rpm vendor string")
-
-diff --git a/macros.in b/macros.in
-index 4d3e8afdc..66e31320f 100644
---- a/macros.in
-+++ b/macros.in
-@@ -964,7 +964,7 @@ Supplements: (%{name} = %{version}-%{release} and langpacks-%{1})\
- %_sharedstatedir %{_var}/lib
- %_localstatedir %{_prefix}/var
- %_lib lib
--%_libdir %{_exec_prefix}/%{_lib}
-+%_libdir @libdir@
- %_includedir %{_prefix}/include
- %_infodir %{_datadir}/info
- %_mandir %{_datadir}/man
diff --git a/meta/recipes-devtools/rpm/files/0001-Do-not-read-config-files-from-HOME.patch b/meta/recipes-devtools/rpm/files/0001-Do-not-read-config-files-from-HOME.patch
index bfc9a74b6c..ae47499e22 100644
--- a/meta/recipes-devtools/rpm/files/0001-Do-not-read-config-files-from-HOME.patch
+++ b/meta/recipes-devtools/rpm/files/0001-Do-not-read-config-files-from-HOME.patch
@@ -5,15 +5,19 @@ Subject: [PATCH] Do not read config files from $HOME
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- lib/rpmrc.c | 6 ++----
+ lib/rpmrc.cc | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
-diff --git a/lib/rpmrc.c b/lib/rpmrc.c
-index 5d778b8b7..dc8d42aeb 100644
---- a/lib/rpmrc.c
-+++ b/lib/rpmrc.c
-@@ -485,8 +485,7 @@ static void setDefaults(void)
+diff --git a/lib/rpmrc.cc b/lib/rpmrc.cc
+index 2b3baeddc..cea6f4bc5 100644
+--- a/lib/rpmrc.cc
++++ b/lib/rpmrc.cc
+@@ -390,8 +390,7 @@ static void setDefaults(void)
if (!defrcfiles) {
defrcfiles = rstrscat(NULL, confdir, "/rpmrc", ":",
confdir, "/" RPM_VENDOR "/rpmrc", ":",
@@ -23,7 +27,7 @@ index 5d778b8b7..dc8d42aeb 100644
}
/* macrofiles may be pre-set from --macros */
-@@ -498,8 +497,7 @@ static void setDefaults(void)
+@@ -403,8 +402,7 @@ static void setDefaults(void)
confdir, "/" RPM_VENDOR "/macros", ":",
SYSCONFDIR "/rpm/macros.*", ":",
SYSCONFDIR "/rpm/macros", ":",
diff --git a/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch b/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
index d3263896ef..05c8b79f29 100644
--- a/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
+++ b/meta/recipes-devtools/rpm/files/0001-Do-not-reset-the-PATH-environment-variable-before-ru.patch
@@ -8,15 +8,19 @@ We add lots of native stuff into it and scriptlets rely on that.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini<sumanth.gavini@windriver.com>
---
- lib/rpmscript.c | 2 +-
+ lib/rpmscript.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/lib/rpmscript.c b/lib/rpmscript.c
-index 060fd8124..4dc6466a8 100644
---- a/lib/rpmscript.c
-+++ b/lib/rpmscript.c
-@@ -251,7 +251,7 @@ static void doScriptExec(ARGV_const_t argv, ARGV_const_t prefixes,
+diff --git a/lib/rpmscript.cc b/lib/rpmscript.cc
+index b75a62085..2d7a4c889 100644
+--- a/lib/rpmscript.cc
++++ b/lib/rpmscript.cc
+@@ -260,7 +260,7 @@ static void doScriptExec(ARGV_const_t argv, ARGV_const_t prefixes,
if (ipath && ipath[5] != '%')
path = ipath;
diff --git a/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch b/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
index b71156fe12..90f5322573 100644
--- a/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
+++ b/meta/recipes-devtools/rpm/files/0001-When-cross-installing-execute-package-scriptlets-wit.patch
@@ -26,15 +26,17 @@ Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Rebased to 4.20.1
+Rebased to 6.0.2
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- lib/rpmscript.c | 9 +++++++--
+ lib/rpmscript.cc | 9 +++++++--
1 file changed, 7 insertions(+), 2 deletions(-)
-diff --git a/lib/rpmscript.c b/lib/rpmscript.c
-index eb14870b3..1785e8f30 100644
---- a/lib/rpmscript.c
-+++ b/lib/rpmscript.c
+diff --git a/lib/rpmscript.cc b/lib/rpmscript.cc
+index b75a62085..7d667b7f5 100644
+--- a/lib/rpmscript.cc
++++ b/lib/rpmscript.cc
@@ -456,8 +456,7 @@ exit:
Fclose(out); /* XXX dup'd STDOUT_FILENO */
diff --git a/meta/recipes-devtools/rpm/files/0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch b/meta/recipes-devtools/rpm/files/0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch
index 0c29e5543a..fe4e029830 100644
--- a/meta/recipes-devtools/rpm/files/0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch
+++ b/meta/recipes-devtools/rpm/files/0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch
@@ -1,7 +1,7 @@
From e688eb54fd54d65181e94b854b3568d99cbf3a24 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Tue, 31 Aug 2021 10:37:05 +0200
-Subject: [PATCH] build/pack.c: do not insert payloadflags into .rpm metadata
+Subject: [PATCH] build/pack.cc: do not insert payloadflags into .rpm metadata
The flags look like '19T56' where 19 is the compression level
(deterministic), and 56 is the amount of threads (varies from one
@@ -9,15 +9,19 @@ host to the next and breaks reproducibility for .rpm).
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- build/pack.c | 2 +-
+ build/pack.cc | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
-diff --git a/build/pack.c b/build/pack.c
-index fb1f1bed8..45885a6ac 100644
---- a/build/pack.c
-+++ b/build/pack.c
-@@ -330,7 +330,7 @@ static char *getIOFlags(Package pkg)
+diff --git a/build/pack.cc b/build/pack.cc
+index b1cda6d75..1425d27ba 100644
+--- a/build/pack.cc
++++ b/build/pack.cc
+@@ -338,7 +338,7 @@ static char *getIOFlags(Package pkg)
headerPutString(pkg->header, RPMTAG_PAYLOADCOMPRESSOR, compr);
buf = xstrdup(rpmio_flags);
buf[s - rpmio_flags] = '\0';
diff --git a/meta/recipes-devtools/rpm/files/0001-lib-transaction.c-fix-file-conflicts-for-MIPS64-N32.patch b/meta/recipes-devtools/rpm/files/0001-lib-transaction.c-fix-file-conflicts-for-MIPS64-N32.patch
index 7d443ccc6c..5dc059493c 100644
--- a/meta/recipes-devtools/rpm/files/0001-lib-transaction.c-fix-file-conflicts-for-MIPS64-N32.patch
+++ b/meta/recipes-devtools/rpm/files/0001-lib-transaction.c-fix-file-conflicts-for-MIPS64-N32.patch
@@ -1,7 +1,7 @@
From ad530868e37f09e9236c085d25a834304750704b Mon Sep 17 00:00:00 2001
From: Changqing Li <changqing.li@windriver.com>
Date: Thu, 7 May 2020 17:40:58 +0800
-Subject: [PATCH] lib/transaction.c: fix file conflicts for MIPS64 N32
+Subject: [PATCH] lib/transaction.cc: fix file conflicts for MIPS64 N32
This patch is from:
https://github.com/rpm-software-management/rpm/issues/193
@@ -27,15 +27,19 @@ Fixed by performing a 'last-in-wins' resolution when "neither is preferred".
Upstream-Status: Submitted <https://github.com/rpm-software-management/rpm/issues/193>
Signed-off-by: Changqing Li <changqing.li@windriver.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- lib/transaction.c | 13 ++++++++++++-
+ lib/transaction.cc | 13 ++++++++++++-
1 file changed, 12 insertions(+), 1 deletion(-)
-diff --git a/lib/transaction.c b/lib/transaction.c
-index 5e4414d2a..b1c55bd44 100644
---- a/lib/transaction.c
-+++ b/lib/transaction.c
-@@ -400,7 +400,18 @@ static int handleColorConflict(rpmts ts,
+diff --git a/lib/transaction.cc b/lib/transaction.cc
+index de7cdabb2..697268733 100644
+--- a/lib/transaction.cc
++++ b/lib/transaction.cc
+@@ -375,7 +375,18 @@ static int handleColorConflict(rpmts ts,
rpmfsSetAction(ofs, ofx, FA_CREATE);
rpmfsSetAction(fs, fx, FA_SKIPCOLOR);
rConflicts = 0;
diff --git a/meta/recipes-devtools/rpm/files/0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch b/meta/recipes-devtools/rpm/files/0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch
new file mode 100644
index 0000000000..500a667a1b
--- /dev/null
+++ b/meta/recipes-devtools/rpm/files/0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch
@@ -0,0 +1,35 @@
+From 1cb53934b83b794c319813106c9f12d75cce66d2 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Sun, 18 Jan 2026 19:24:42 -0800
+Subject: [PATCH] macros.in: Set _pkgverify_level to digest as RPM 4.20.1
+
+Fixed:
+$ bitbake core-image-minimal
+Package bash-5.3-r0.16.x86_64_v3.rpm is not signed
+GPG check FAILED
+
+Set _pkgverify_level to digest as RPM 4.20.1 can fix the problem.
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ macros.in | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/macros.in b/macros.in
+index 38066f00c..7fe00ad09 100644
+--- a/macros.in
++++ b/macros.in
+@@ -680,7 +680,7 @@ Supplements: (%{name} = %{version}-%{release} and langpacks-%{1})\
+ # signature require valid signature(s)
+ # digest require valid digest(s)
+ # none traditional rpm behavior, nothing required
+-%_pkgverify_level all
++%_pkgverify_level digest
+
+ # Disabler flags for package verification (similar to vsflags)
+ # Set to 0x0 for full compatibility with v4 packages.
+--
+2.49.0
+
diff --git a/meta/recipes-devtools/rpm/files/0001-tools-elfdeps.cc-Remove-format-module.patch b/meta/recipes-devtools/rpm/files/0001-tools-elfdeps.cc-Remove-format-module.patch
new file mode 100644
index 0000000000..25f5496bde
--- /dev/null
+++ b/meta/recipes-devtools/rpm/files/0001-tools-elfdeps.cc-Remove-format-module.patch
@@ -0,0 +1,38 @@
+From 3536ef6bb74144cf9dce10200cd62c2ad9f7cae4 Mon Sep 17 00:00:00 2001
+From: Robert Yang <liezhi.yang@windriver.com>
+Date: Thu, 15 Jan 2026 19:36:17 -0800
+Subject: [PATCH] tools/elfdeps.cc: Remove format module
+
+There is no format until gcc 13.1, so remove the format module to make it work
+on hosts such as Ubuntu 22.04.
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ tools/elfdeps.cc | 3 +--
+ 1 file changed, 1 insertion(+), 2 deletions(-)
+
+diff --git a/tools/elfdeps.cc b/tools/elfdeps.cc
+index 17884b24e..33ff8d740 100644
+--- a/tools/elfdeps.cc
++++ b/tools/elfdeps.cc
+@@ -1,6 +1,5 @@
+ #include "system.h"
+
+-#include <format>
+ #include <string>
+ #include <vector>
+
+@@ -105,7 +104,7 @@ static void addSoDep(std::vector<std::string> & deps,
+ if (ver.empty() && marker.empty()) {
+ addDep(deps, soname);
+ } else {
+- auto dep = std::format("{}({}){}", soname, ver, marker);
++ std::string dep = soname + "(" + ver + ")" + marker;
+ addDep(deps, dep);
+ }
+ }
+--
+2.49.0
+
diff --git a/meta/recipes-devtools/rpm/files/0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch b/meta/recipes-devtools/rpm/files/0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch
index 082fb343c2..1004253ff8 100644
--- a/meta/recipes-devtools/rpm/files/0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch
+++ b/meta/recipes-devtools/rpm/files/0002-Add-support-for-prefixing-etc-from-RPM_ETCCONFIGDIR-.patch
@@ -9,15 +9,19 @@ from target rootfs instead of its own native sysroot.
Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- lib/rpmrc.c | 18 +++++++++++++-----
+ lib/rpmrc.cc | 18 +++++++++++++-----
1 file changed, 13 insertions(+), 5 deletions(-)
-diff --git a/lib/rpmrc.c b/lib/rpmrc.c
-index dc8d42aeb..3f2996850 100644
---- a/lib/rpmrc.c
-+++ b/lib/rpmrc.c
-@@ -481,11 +481,14 @@ static void setDefaults(void)
+diff --git a/lib/rpmrc.cc b/lib/rpmrc.cc
+index cea6f4bc5..e6cf21e1b 100644
+--- a/lib/rpmrc.cc
++++ b/lib/rpmrc.cc
+@@ -386,11 +386,14 @@ static void setDefaults(void)
userrc = xstrdup(oldrc);
}
}
@@ -33,7 +37,7 @@ index dc8d42aeb..3f2996850 100644
}
/* macrofiles may be pre-set from --macros */
-@@ -495,9 +498,9 @@ static void setDefaults(void)
+@@ -400,9 +403,9 @@ static void setDefaults(void)
confdir, "/platform/%{_target}/macros", ":",
confdir, "/fileattrs/*.attr", ":",
confdir, "/" RPM_VENDOR "/macros", ":",
@@ -46,7 +50,7 @@ index dc8d42aeb..3f2996850 100644
}
free(usermacros);
-@@ -1142,7 +1145,11 @@ static void read_auxv(void)
+@@ -1048,7 +1051,11 @@ static void read_auxv(void)
*/
static void defaultMachine(rpmrcCtx ctx, const char ** arch, const char ** os)
{
@@ -55,11 +59,11 @@ index dc8d42aeb..3f2996850 100644
+ if (etcconfdir == NULL)
+ etcconfdir = "";
+
-+ const char * const platform_path = rstrscat(NULL, etcconfdir, SYSCONFDIR "/rpm/platform", NULL);
++ char * const platform_path = rstrscat(NULL, etcconfdir, SYSCONFDIR "/rpm/platform", NULL);
static struct utsname un;
char * chptr;
- canonEntry canon;
-@@ -1462,6 +1469,7 @@ static void defaultMachine(rpmrcCtx ctx, const char ** arch, const char ** os)
+ int rc;
+@@ -1378,6 +1385,7 @@ static void defaultMachine(rpmrcCtx ctx, const char ** arch, const char ** os)
if (arch) *arch = un.machine;
if (os) *os = un.sysname;
diff --git a/meta/recipes-devtools/rpm/files/0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch b/meta/recipes-devtools/rpm/files/0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch
index 00fe19108e..59855466da 100644
--- a/meta/recipes-devtools/rpm/files/0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch
+++ b/meta/recipes-devtools/rpm/files/0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch
@@ -1,7 +1,7 @@
From d8972ff7fa0a30e199144ba135223bf561874e01 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex@linutronix.de>
Date: Tue, 16 Jan 2024 09:59:26 +0100
-Subject: [PATCH] rpmio/rpmglob.c: avoid using GLOB_BRACE if undefined by C
+Subject: [PATCH] rpmio/rpmglob.cc: avoid using GLOB_BRACE if undefined by C
library
This addresses musl failures; if there is code out there relying on
@@ -11,14 +11,18 @@ This is unlikely to be trivially fixable upstream.
Upstream-Status: Inappropriate [reported at https://github.com/rpm-software-management/rpm/issues/2844]
Signed-off-by: Alexander Kanavin <alex@linutronix.de>
+
+Rebased to 6.0.2
+Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- rpmio/rpmglob.c | 6 ++++++
+ rpmio/rpmglob.cc | 6 ++++++
1 file changed, 6 insertions(+)
-diff --git a/rpmio/rpmglob.c b/rpmio/rpmglob.c
+diff --git a/rpmio/rpmglob.cc b/rpmio/rpmglob.cc
index eb439cad8..1eef0b851 100644
---- a/rpmio/rpmglob.c
-+++ b/rpmio/rpmglob.c
+--- a/rpmio/rpmglob.cc
++++ b/rpmio/rpmglob.cc
@@ -33,6 +33,12 @@
#include "debug.h"
diff --git a/meta/recipes-devtools/rpm/files/0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch b/meta/recipes-devtools/rpm/files/0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch
index bac2d6331c..84f909c68b 100644
--- a/meta/recipes-devtools/rpm/files/0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch
+++ b/meta/recipes-devtools/rpm/files/0016-rpmscript.c-change-logging-level-around-scriptlets-t.patch
@@ -1,7 +1,7 @@
From 452b696ea3e1975ea30cf7a92678aa4b316e6300 Mon Sep 17 00:00:00 2001
From: Alexander Kanavin <alex.kanavin@gmail.com>
Date: Thu, 10 Jan 2019 18:14:18 +0100
-Subject: [PATCH] rpmscript.c: change logging level around scriptlets to INFO
+Subject: [PATCH] rpmscript.cc: change logging level around scriptlets to INFO
from DEBUG
That way we can debug scriptlet failures without writing lots of
@@ -11,15 +11,17 @@ Upstream-Status: Inappropriate [oe-core specific]
Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
Rebased to 4.20.1
+Rebased to 6.0.2
Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
- lib/rpmscript.c | 8 ++++----
+ lib/rpmscript.cc | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
-diff --git a/lib/rpmscript.c b/lib/rpmscript.c
-index e9f288ae0..f0c628708 100644
---- a/lib/rpmscript.c
-+++ b/lib/rpmscript.c
+diff --git a/lib/rpmscript.cc b/lib/rpmscript.cc
+index fe5fc9138..861fd8ca8 100644
+--- a/lib/rpmscript.cc
++++ b/lib/rpmscript.cc
@@ -299,7 +299,7 @@ static char * writeScript(const char *cmd, const char *script)
if (Ferror(fd))
goto exit;
diff --git a/meta/recipes-devtools/rpm/rpm_4.20.1.bb b/meta/recipes-devtools/rpm/rpm_6.0.2.bb
similarity index 96%
rename from meta/recipes-devtools/rpm/rpm_4.20.1.bb
rename to meta/recipes-devtools/rpm/rpm_6.0.2.bb
index 17e75c3e14..e8977aa31a 100644
--- a/meta/recipes-devtools/rpm/rpm_4.20.1.bb
+++ b/meta/recipes-devtools/rpm/rpm_6.0.2.bb
@@ -24,7 +24,7 @@ HOMEPAGE = "http://www.rpm.org"
LICENSE = "GPL-2.0-only"
LIC_FILES_CHKSUM = "file://COPYING;md5=066ecde17828e5c8911ec9eae8be78f4"
-SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.20.x;protocol=https \
+SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-6.0.x;protocol=https \
file://0001-Do-not-add-an-unsatisfiable-dependency-when-building.patch \
file://0001-Do-not-read-config-files-from-HOME.patch \
file://0001-When-cross-installing-execute-package-scriptlets-wit.patch \
@@ -37,14 +37,14 @@ SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-4.20.x;protoc
file://0001-build-pack.c-do-not-insert-payloadflags-into-.rpm-me.patch \
file://0001-CMakeLists.txt-look-for-lua-with-pkg-config-rather-t.patch \
file://0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch \
- file://0001-CMakeLists.txt-set-libdir-to-CMAKE_INSTALL_FULL_LIBD.patch \
- file://0001-CMakeLists.txt-Fix-checking-for-CFLAGS.patch \
+ file://0001-tools-elfdeps.cc-Remove-format-module.patch \
+ file://0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch \
"
PE = "1"
-SRCREV = "c8dc5ea575a2e9c1488036d12f4b75f6a5a49120"
+SRCREV = "a7f89afb57a98f6419d0eff35ca792198293b682"
-DEPENDS = "lua libgcrypt file popt xz bzip2 elfutils python3 sqlite3 zstd"
+DEPENDS = "lua libgcrypt file popt xz bzip2 elfutils python3 sqlite3 zstd scdoc-native"
DEPENDS:append:class-native = " file-replacement-native bzip2-replacement-native"
EXTRA_OECMAKE:append = " -D__CURL:FILEPATH=curl"
@@ -154,7 +154,8 @@ do_install:append () {
FILES:${PN} += "${libdir}/rpm-plugins/*.so \
"
-FILES:${PN}:append:class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/rpm.sh"
+FILES:${PN}:append:class-nativesdk = " ${SDKPATHNATIVE}/environment-setup.d/rpm.sh \
+ /etc/rpm"
FILES:${PN}-dev += "${libdir}/rpm-plugins/*.la \
"
@@ -181,6 +182,7 @@ FILES:${PN}-build = "\
${libdir}/rpm/mkinstalldirs \
${libdir}/rpm/macros.p* \
${libdir}/rpm/fileattrs/* \
+ ${libdir}/rpm/rpm-setup-autosign \
"
FILES:${PN}-sign = "\
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 7/8] libarchive: Make it work with rpm 6.0.2
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (5 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 6/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 4:08 ` [PATCH v12 8/8] rpm: filter /usr/bin/pkg-config from RPM auto-generated Requires Sumanth Gavini
2026-08-04 14:18 ` [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Mathieu Dubois-Briand
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
The patch is from:
https://github.com/libarchive/libarchive/pull/3346/
Fixed:
$ oe-selftest -r debuginfod.Debuginfod.test_debuginfod_native
cannot open archive from pipe
/path/to/tmp-debuginfod/work/x86-64-v3-poky-linux/xz/5.8.2/localpkgfeed/x86_64_v3/bash-locale-vi-5.3-r0.x86_64_v3.rpm
libarchive error: cannot open archive from pipe: Unrecognized archive
format
exceptions encountered during archive scan
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
...-Verify-that-bidder-and-filter-match.patch | 101 +++++++
...nd_filter-Use-last-bidder-for-filter.patch | 185 +++++++++++++
.../libarchive/0003-Remove-bidder-name.patch | 258 ++++++++++++++++++
.../libarchive/libarchive_3.8.9.bb | 3 +
4 files changed, 547 insertions(+)
create mode 100644 meta/recipes-extended/libarchive/libarchive/0001-append_filter-Verify-that-bidder-and-filter-match.patch
create mode 100644 meta/recipes-extended/libarchive/libarchive/0002-append_filter-Use-last-bidder-for-filter.patch
create mode 100644 meta/recipes-extended/libarchive/libarchive/0003-Remove-bidder-name.patch
diff --git a/meta/recipes-extended/libarchive/libarchive/0001-append_filter-Verify-that-bidder-and-filter-match.patch b/meta/recipes-extended/libarchive/libarchive/0001-append_filter-Verify-that-bidder-and-filter-match.patch
new file mode 100644
index 0000000000..2413f70785
--- /dev/null
+++ b/meta/recipes-extended/libarchive/libarchive/0001-append_filter-Verify-that-bidder-and-filter-match.patch
@@ -0,0 +1,101 @@
+From db4fb440792278cd01e0829c93f6b62f567b704b Mon Sep 17 00:00:00 2001
+From: Tobias Stoeckmann <tobias@stoeckmann.org>
+Date: Sun, 2 Aug 2026 14:26:22 +0200
+Subject: [PATCH 1/3] append_filter: Verify that bidder and filter match
+
+Make sure that appending a filter always matches its supposed bidder.
+
+Upstream-Status: Submitted [https://github.com/libarchive/libarchive/pull/3346]
+Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ Makefile.am | 1 +
+ libarchive/test/CMakeLists.txt | 1 +
+ .../test/test_archive_read_append_filter.c | 54 +++++++++++++++++++
+ 3 files changed, 56 insertions(+)
+ create mode 100644 libarchive/test/test_archive_read_append_filter.c
+
+diff --git a/Makefile.am b/Makefile.am
+index 2fb4fdf4..c96b3bc6 100644
+--- a/Makefile.am
++++ b/Makefile.am
+@@ -404,6 +404,7 @@ libarchive_test_SOURCES= \
+ libarchive/test/test_archive_pathmatch_oob.c \
+ libarchive/test/test_archive_read.c \
+ libarchive/test/test_archive_read_add_passphrase.c \
++ libarchive/test/test_archive_read_append_filter.c \
+ libarchive/test/test_archive_read_close_twice.c \
+ libarchive/test/test_archive_read_multiple_data_objects.c \
+ libarchive/test/test_archive_read_next_header_empty.c \
+diff --git a/libarchive/test/CMakeLists.txt b/libarchive/test/CMakeLists.txt
+index 44f839f8..c4102c3d 100644
+--- a/libarchive/test/CMakeLists.txt
++++ b/libarchive/test/CMakeLists.txt
+@@ -33,6 +33,7 @@ IF(ENABLE_TEST)
+ test_archive_pathmatch_oob.c
+ test_archive_read.c
+ test_archive_read_add_passphrase.c
++ test_archive_read_append_filter.c
+ test_archive_read_close_twice.c
+ test_archive_read_multiple_data_objects.c
+ test_archive_read_next_header_empty.c
+diff --git a/libarchive/test/test_archive_read_append_filter.c b/libarchive/test/test_archive_read_append_filter.c
+new file mode 100644
+index 00000000..5c301d52
+--- /dev/null
++++ b/libarchive/test/test_archive_read_append_filter.c
+@@ -0,0 +1,54 @@
++/*-
++ * Copyright (c) 2026 Tobias Stoeckmann
++ * All rights reserved.
++ *
++ * Redistribution and use in source and binary forms, with or without
++ * modification, are permitted provided that the following conditions
++ * are met:
++ * 1. Redistributions of source code must retain the above copyright
++ * notice, this list of conditions and the following disclaimer.
++ * 2. Redistributions in binary form must reproduce the above copyright
++ * notice, this list of conditions and the following disclaimer in the
++ * documentation and/or other materials provided with the distribution.
++ *
++ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR(S) ``AS IS'' AND ANY EXPRESS OR
++ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
++ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
++ * IN NO EVENT SHALL THE AUTHOR(S) BE LIABLE FOR ANY DIRECT, INDIRECT,
++ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
++ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
++ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
++ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
++ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
++ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
++ */
++
++#include "archive.h"
++#include "test.h"
++
++DEFINE_TEST(test_archive_read_append_filter)
++{
++ struct archive *a;
++ int r;
++
++ a = archive_read_new();
++ assert(a != NULL);
++
++ /* Append a program bidder (without filter). */
++ assertEqualIntA(a, ARCHIVE_OK,
++ archive_read_support_filter_program(a, "prog1"));
++
++ /* Append a filter program which comes with its own bidder. */
++ r = archive_read_append_filter_program(a, "prog2");
++
++ /* Verify that filter uses its own bidder. */
++ if (r == ARCHIVE_FATAL) {
++ assertEqualStringA(a, "Can't initialize filter; unable to run program \"prog2\"",
++ archive_error_string(a));
++ } else {
++ assertEqualIntA(a, ARCHIVE_OK, r);
++ assertEqualStringA(a, "Program: prog2", archive_filter_name(a, 0));
++ }
++
++ archive_read_free(a);
++}
diff --git a/meta/recipes-extended/libarchive/libarchive/0002-append_filter-Use-last-bidder-for-filter.patch b/meta/recipes-extended/libarchive/libarchive/0002-append_filter-Use-last-bidder-for-filter.patch
new file mode 100644
index 0000000000..f412b548d7
--- /dev/null
+++ b/meta/recipes-extended/libarchive/libarchive/0002-append_filter-Use-last-bidder-for-filter.patch
@@ -0,0 +1,185 @@
+From 6a3b6d4d2924e623c32c398b74d61bd49b88fc36 Mon Sep 17 00:00:00 2001
+From: Tobias Stoeckmann <tobias@stoeckmann.org>
+Date: Sun, 2 Aug 2026 14:27:17 +0200
+Subject: [PATCH 2/3] append_filter: Use last bidder for filter
+
+Appending a filter implies appending a bidder. Always use the last added
+bidder, since it was just added. This avoids desync situations where
+previously added bidders could erroneously match.
+
+Upstream-Status: Submitted [https://github.com/libarchive/libarchive/pull/3346]
+Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ libarchive/archive_read_append_filter.c | 72 ++++++++-----------------
+ 1 file changed, 22 insertions(+), 50 deletions(-)
+
+diff --git a/libarchive/archive_read_append_filter.c b/libarchive/archive_read_append_filter.c
+index 8de1b2ea..9dd9f536 100644
+--- a/libarchive/archive_read_append_filter.c
++++ b/libarchive/archive_read_append_filter.c
+@@ -33,14 +33,25 @@
+ #include "archive_private.h"
+ #include "archive_read_private.h"
+
++static struct archive_read_filter_bidder *
++get_last_bidder(struct archive_read *a)
++{
++ size_t i;
++
++ for (i = 0; i < sizeof(a->bidders) / sizeof(a->bidders[0]); i++)
++ {
++ if (a->bidders[i].vtable == NULL)
++ break;
++ }
++
++ return a->bidders + (i - 1);
++}
++
+ int
+ archive_read_append_filter(struct archive *_a, int code)
+ {
+- int r1, r2, number_bidders, i;
+- const char *str;
+- struct archive_read_filter_bidder *b;
+- struct archive_read_filter *f;
+ struct archive_read *a = (struct archive_read *)_a;
++ int r1, r2;
+
+ r2 = (ARCHIVE_OK);
+ switch (code)
+@@ -53,15 +64,12 @@ archive_read_append_filter(struct archive *_a, int code)
+ r1 = (ARCHIVE_OK);
+ break;
+ case ARCHIVE_FILTER_GZIP:
+- str = "gzip";
+ r1 = archive_read_support_filter_gzip(_a);
+ break;
+ case ARCHIVE_FILTER_BZIP2:
+- str = "bzip2";
+ r1 = archive_read_support_filter_bzip2(_a);
+ break;
+ case ARCHIVE_FILTER_COMPRESS:
+- str = "compress (.Z)";
+ r1 = archive_read_support_filter_compress(_a);
+ break;
+ case ARCHIVE_FILTER_PROGRAM:
+@@ -69,43 +77,33 @@ archive_read_append_filter(struct archive *_a, int code)
+ "Cannot append program filter using archive_read_append_filter");
+ return (ARCHIVE_FATAL);
+ case ARCHIVE_FILTER_LZMA:
+- str = "lzma";
+ r1 = archive_read_support_filter_lzma(_a);
+ break;
+ case ARCHIVE_FILTER_XZ:
+- str = "xz";
+ r1 = archive_read_support_filter_xz(_a);
+ break;
+ case ARCHIVE_FILTER_UU:
+- str = "uu";
+ r1 = archive_read_support_filter_uu(_a);
+ break;
+ case ARCHIVE_FILTER_RPM:
+- str = "rpm";
+ r1 = archive_read_support_filter_rpm(_a);
+ break;
+ case ARCHIVE_FILTER_LZ4:
+- str = "lz4";
+ r1 = archive_read_support_filter_lz4(_a);
+ break;
+ case ARCHIVE_FILTER_ZSTD:
+- str = "zstd";
+ r1 = archive_read_support_filter_zstd(_a);
+ break;
+ case ARCHIVE_FILTER_LZIP:
+- str = "lzip";
+ r1 = archive_read_support_filter_lzip(_a);
+ break;
+ case ARCHIVE_FILTER_LZOP:
+- str = "lzop";
+ r1 = archive_read_support_filter_lzop(_a);
+ break;
+ case ARCHIVE_FILTER_LRZIP:
+- str = "lrzip";
+ r1 = archive_read_support_filter_lrzip(_a);
+ break;
+ case ARCHIVE_FILTER_GRZIP:
+- str = "grzip";
+ r1 = archive_read_support_filter_grzip(_a);
+ break;
+ default:
+@@ -114,22 +112,10 @@ archive_read_append_filter(struct archive *_a, int code)
+ return (ARCHIVE_FATAL);
+ }
+
+- if (code != ARCHIVE_FILTER_NONE)
++ if (r1 > ARCHIVE_FATAL && code != ARCHIVE_FILTER_NONE)
+ {
+- number_bidders = sizeof(a->bidders) / sizeof(a->bidders[0]);
+-
+- b = a->bidders;
+- for (i = 1; i < number_bidders; i++, b++)
+- {
+- if (!b->name || !strcmp(b->name, str))
+- break;
+- }
+- if (!b->name || strcmp(b->name, str))
+- {
+- archive_set_error(&a->archive, ARCHIVE_ERRNO_PROGRAMMER,
+- "Internal error: Unable to append filter");
+- return (ARCHIVE_FATAL);
+- }
++ struct archive_read_filter_bidder *b;
++ struct archive_read_filter *f;
+
+ f = calloc(1, sizeof(*f));
+ if (f == NULL)
+@@ -137,6 +123,7 @@ archive_read_append_filter(struct archive *_a, int code)
+ archive_set_error(&a->archive, ENOMEM, "Out of memory");
+ return (ARCHIVE_FATAL);
+ }
++ b = get_last_bidder(a);
+ f->bidder = b;
+ f->archive = a;
+ f->upstream = a->filter;
+@@ -162,37 +149,22 @@ int
+ archive_read_append_filter_program_signature(struct archive *_a,
+ const char *cmd, const void *signature, size_t signature_len)
+ {
+- int r, number_bidders, i;
++ struct archive_read *a = (struct archive_read *)_a;
+ struct archive_read_filter_bidder *b;
+ struct archive_read_filter *f;
+- struct archive_read *a = (struct archive_read *)_a;
++ int r;
+
+ if (archive_read_support_filter_program_signature(_a, cmd, signature,
+ signature_len) != (ARCHIVE_OK))
+ return (ARCHIVE_FATAL);
+
+- number_bidders = sizeof(a->bidders) / sizeof(a->bidders[0]);
+-
+- b = a->bidders;
+- for (i = 0; i < number_bidders; i++, b++)
+- {
+- /* Program bidder name set to filter name after initialization */
+- if (b->data && !b->name)
+- break;
+- }
+- if (!b->data)
+- {
+- archive_set_error(&a->archive, ARCHIVE_ERRNO_PROGRAMMER,
+- "Internal error: Unable to append program filter");
+- return (ARCHIVE_FATAL);
+- }
+-
+ f = calloc(1, sizeof(*f));
+ if (f == NULL)
+ {
+ archive_set_error(&a->archive, ENOMEM, "Out of memory");
+ return (ARCHIVE_FATAL);
+ }
++ b = get_last_bidder(a);
+ f->bidder = b;
+ f->archive = a;
+ f->upstream = a->filter;
diff --git a/meta/recipes-extended/libarchive/libarchive/0003-Remove-bidder-name.patch b/meta/recipes-extended/libarchive/libarchive/0003-Remove-bidder-name.patch
new file mode 100644
index 0000000000..bbd2478577
--- /dev/null
+++ b/meta/recipes-extended/libarchive/libarchive/0003-Remove-bidder-name.patch
@@ -0,0 +1,258 @@
+From 76c7142bd2595184826722063598fddf62031cca Mon Sep 17 00:00:00 2001
+From: Tobias Stoeckmann <tobias@stoeckmann.org>
+Date: Sun, 2 Aug 2026 14:31:33 +0200
+Subject: [PATCH 3/3] Remove bidder name
+
+The name was only needed to find the appropriate bidder for a filter.
+Since this has been resolved by accessing the last bidder, since in these
+situations the bidder is added first, then the filter, the name is not
+needed anymore.
+
+Upstream-Status: Submitted [https://github.com/libarchive/libarchive/pull/3346]
+Signed-off-by: Tobias Stoeckmann <tobias@stoeckmann.org>
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ libarchive/archive_read.c | 2 --
+ libarchive/archive_read_append_filter.c | 1 -
+ libarchive/archive_read_private.h | 3 ---
+ libarchive/archive_read_support_filter_bzip2.c | 2 +-
+ libarchive/archive_read_support_filter_compress.c | 2 +-
+ libarchive/archive_read_support_filter_grzip.c | 2 +-
+ libarchive/archive_read_support_filter_gzip.c | 2 +-
+ libarchive/archive_read_support_filter_lrzip.c | 2 +-
+ libarchive/archive_read_support_filter_lz4.c | 2 +-
+ libarchive/archive_read_support_filter_lzop.c | 2 +-
+ libarchive/archive_read_support_filter_program.c | 2 +-
+ libarchive/archive_read_support_filter_rpm.c | 2 +-
+ libarchive/archive_read_support_filter_uu.c | 2 +-
+ libarchive/archive_read_support_filter_xz.c | 6 +++---
+ libarchive/archive_read_support_filter_zstd.c | 2 +-
+ 15 files changed, 14 insertions(+), 20 deletions(-)
+
+diff --git a/libarchive/archive_read.c b/libarchive/archive_read.c
+index e844e42d..406d84de 100644
+--- a/libarchive/archive_read.c
++++ b/libarchive/archive_read.c
+@@ -1290,7 +1290,6 @@ __archive_read_register_format(struct archive_read *a,
+ int
+ __archive_read_register_bidder(struct archive_read *a,
+ void *bidder_data,
+- const char *name,
+ const struct archive_read_filter_bidder_vtable *vtable)
+ {
+ struct archive_read_filter_bidder *bidder;
+@@ -1307,7 +1306,6 @@ __archive_read_register_bidder(struct archive_read *a,
+ memset(a->bidders + i, 0, sizeof(a->bidders[0]));
+ bidder = (a->bidders + i);
+ bidder->data = bidder_data;
+- bidder->name = name;
+ bidder->vtable = vtable;
+ if (bidder->vtable->bid == NULL || bidder->vtable->init == NULL) {
+ archive_set_error(&a->archive, ARCHIVE_ERRNO_PROGRAMMER,
+diff --git a/libarchive/archive_read_append_filter.c b/libarchive/archive_read_append_filter.c
+index 9dd9f536..5cc8ff55 100644
+--- a/libarchive/archive_read_append_filter.c
++++ b/libarchive/archive_read_append_filter.c
+@@ -174,7 +174,6 @@ archive_read_append_filter_program_signature(struct archive *_a,
+ __archive_read_free_filters(a);
+ return (ARCHIVE_FATAL);
+ }
+- b->name = a->filter->name;
+
+ a->bypass_filter_bidding = 1;
+ return r;
+diff --git a/libarchive/archive_read_private.h b/libarchive/archive_read_private.h
+index 3bd8de2d..e30b6c2b 100644
+--- a/libarchive/archive_read_private.h
++++ b/libarchive/archive_read_private.h
+@@ -68,8 +68,6 @@ struct archive_read_filter_bidder_vtable {
+ struct archive_read_filter_bidder {
+ /* Configuration data for the bidder. */
+ void *data;
+- /* Name of the filter */
+- const char *name;
+ const struct archive_read_filter_bidder_vtable *vtable;
+ };
+
+@@ -250,7 +248,6 @@ int __archive_read_register_format(struct archive_read *a,
+
+ int __archive_read_register_bidder(struct archive_read *a,
+ void *bidder_data,
+- const char *name,
+ const struct archive_read_filter_bidder_vtable *vtable);
+
+ const void *__archive_read_ahead(struct archive_read *, size_t, ssize_t *);
+diff --git a/libarchive/archive_read_support_filter_bzip2.c b/libarchive/archive_read_support_filter_bzip2.c
+index 588953f2..1cfc55dc 100644
+--- a/libarchive/archive_read_support_filter_bzip2.c
++++ b/libarchive/archive_read_support_filter_bzip2.c
+@@ -91,7 +91,7 @@ archive_read_support_filter_bzip2(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "bzip2",
++ if (__archive_read_register_bidder(a, NULL,
+ &bzip2_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_compress.c b/libarchive/archive_read_support_filter_compress.c
+index 4e1f1dc5..4763995e 100644
+--- a/libarchive/archive_read_support_filter_compress.c
++++ b/libarchive/archive_read_support_filter_compress.c
+@@ -160,7 +160,7 @@ archive_read_support_filter_compress(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- return __archive_read_register_bidder(a, NULL, "compress (.Z)",
++ return __archive_read_register_bidder(a, NULL,
+ &compress_bidder_vtable);
+ }
+
+diff --git a/libarchive/archive_read_support_filter_grzip.c b/libarchive/archive_read_support_filter_grzip.c
+index 9d9ad46e..8457ec7c 100644
+--- a/libarchive/archive_read_support_filter_grzip.c
++++ b/libarchive/archive_read_support_filter_grzip.c
+@@ -62,7 +62,7 @@ archive_read_support_filter_grzip(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "grzip",
++ if (__archive_read_register_bidder(a, NULL,
+ &grzip_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_gzip.c b/libarchive/archive_read_support_filter_gzip.c
+index 89ae0f37..34b174b7 100644
+--- a/libarchive/archive_read_support_filter_gzip.c
++++ b/libarchive/archive_read_support_filter_gzip.c
+@@ -96,7 +96,7 @@ archive_read_support_filter_gzip(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "gzip",
++ if (__archive_read_register_bidder(a, NULL,
+ &gzip_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_lrzip.c b/libarchive/archive_read_support_filter_lrzip.c
+index 33910fe1..a1d45d77 100644
+--- a/libarchive/archive_read_support_filter_lrzip.c
++++ b/libarchive/archive_read_support_filter_lrzip.c
+@@ -61,7 +61,7 @@ archive_read_support_filter_lrzip(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "lrzip",
++ if (__archive_read_register_bidder(a, NULL,
+ &lrzip_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_lz4.c b/libarchive/archive_read_support_filter_lz4.c
+index 19086a1f..28189a07 100644
+--- a/libarchive/archive_read_support_filter_lz4.c
++++ b/libarchive/archive_read_support_filter_lz4.c
+@@ -118,7 +118,7 @@ archive_read_support_filter_lz4(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "lz4",
++ if (__archive_read_register_bidder(a, NULL,
+ &lz4_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_lzop.c b/libarchive/archive_read_support_filter_lzop.c
+index ebfaf01e..5a552fce 100644
+--- a/libarchive/archive_read_support_filter_lzop.c
++++ b/libarchive/archive_read_support_filter_lzop.c
+@@ -109,7 +109,7 @@ archive_read_support_filter_lzop(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "lzop",
++ if (__archive_read_register_bidder(a, NULL,
+ &lzop_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_program.c b/libarchive/archive_read_support_filter_program.c
+index cf7c3613..a9e02a32 100644
+--- a/libarchive/archive_read_support_filter_program.c
++++ b/libarchive/archive_read_support_filter_program.c
+@@ -156,7 +156,7 @@ archive_read_support_filter_program_signature(struct archive *_a,
+ memcpy(state->signature, signature, signature_len);
+ }
+
+- if (__archive_read_register_bidder(a, state, NULL,
++ if (__archive_read_register_bidder(a, state,
+ &program_bidder_vtable) != ARCHIVE_OK) {
+ free_state(state);
+ return (ARCHIVE_FATAL);
+diff --git a/libarchive/archive_read_support_filter_rpm.c b/libarchive/archive_read_support_filter_rpm.c
+index 01bd1bf7..1cfddf75 100644
+--- a/libarchive/archive_read_support_filter_rpm.c
++++ b/libarchive/archive_read_support_filter_rpm.c
+@@ -71,7 +71,7 @@ archive_read_support_filter_rpm(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- return __archive_read_register_bidder(a, NULL, "rpm",
++ return __archive_read_register_bidder(a, NULL,
+ &rpm_bidder_vtable);
+ }
+
+diff --git a/libarchive/archive_read_support_filter_uu.c b/libarchive/archive_read_support_filter_uu.c
+index c0f6f48e..10d49648 100644
+--- a/libarchive/archive_read_support_filter_uu.c
++++ b/libarchive/archive_read_support_filter_uu.c
+@@ -92,7 +92,7 @@ archive_read_support_filter_uu(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- return __archive_read_register_bidder(a, NULL, "uu",
++ return __archive_read_register_bidder(a, NULL,
+ &uudecode_bidder_vtable);
+ }
+
+diff --git a/libarchive/archive_read_support_filter_xz.c b/libarchive/archive_read_support_filter_xz.c
+index 7c8e0cb5..b00ba543 100644
+--- a/libarchive/archive_read_support_filter_xz.c
++++ b/libarchive/archive_read_support_filter_xz.c
+@@ -115,7 +115,7 @@ archive_read_support_filter_xz(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "xz",
++ if (__archive_read_register_bidder(a, NULL,
+ &xz_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+@@ -147,7 +147,7 @@ archive_read_support_filter_lzma(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "lzma",
++ if (__archive_read_register_bidder(a, NULL,
+ &lzma_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+@@ -180,7 +180,7 @@ archive_read_support_filter_lzip(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "lzip",
++ if (__archive_read_register_bidder(a, NULL,
+ &lzip_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
+diff --git a/libarchive/archive_read_support_filter_zstd.c b/libarchive/archive_read_support_filter_zstd.c
+index 12eac04c..163f54b5 100644
+--- a/libarchive/archive_read_support_filter_zstd.c
++++ b/libarchive/archive_read_support_filter_zstd.c
+@@ -87,7 +87,7 @@ archive_read_support_filter_zstd(struct archive *_a)
+ {
+ struct archive_read *a = (struct archive_read *)_a;
+
+- if (__archive_read_register_bidder(a, NULL, "zstd",
++ if (__archive_read_register_bidder(a, NULL,
+ &zstd_bidder_vtable) != ARCHIVE_OK)
+ return (ARCHIVE_FATAL);
+
diff --git a/meta/recipes-extended/libarchive/libarchive_3.8.9.bb b/meta/recipes-extended/libarchive/libarchive_3.8.9.bb
index 63c66eea81..9d7bfef231 100644
--- a/meta/recipes-extended/libarchive/libarchive_3.8.9.bb
+++ b/meta/recipes-extended/libarchive/libarchive_3.8.9.bb
@@ -32,6 +32,9 @@ EXTRA_OECONF += "--enable-largefile --without-iconv"
SRC_URI = "https://libarchive.org/downloads/libarchive-${PV}.tar.gz \
file://run-ptest \
file://0001-test-skip-ppmd8-aes256-streaming-test-when-no-crypto.patch \
+ file://0001-append_filter-Verify-that-bidder-and-filter-match.patch \
+ file://0002-append_filter-Use-last-bidder-for-filter.patch \
+ file://0003-Remove-bidder-name.patch \
"
UPSTREAM_CHECK_URI = "https://www.libarchive.org/"
^ permalink raw reply related [flat|nested] 12+ messages in thread* [PATCH v12 8/8] rpm: filter /usr/bin/pkg-config from RPM auto-generated Requires
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (6 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 7/8] libarchive: Make it work with rpm 6.0.2 Sumanth Gavini
@ 2026-08-04 4:08 ` Sumanth Gavini
2026-08-04 14:18 ` [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Mathieu Dubois-Briand
8 siblings, 0 replies; 12+ messages in thread
From: Sumanth Gavini @ 2026-08-04 4:08 UTC (permalink / raw)
To: openembedded-core
Cc: alex.kanavin, mathieu.dubois-briand, mattware, esparlin,
peter.marko, randy.macleod
* Added 0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch
- pkgconfigdeps.sh unconditionally emits /usr/bin/pkg-config as a hard
Requires for packages shipping .pc files. In OE/Yocto cross-compilation,
pkg-config is a host-only build tool not needed on the target rootfs,
causing do_rootfs and do_populate_sdk failures with -dev packages.
Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
---
...-Do-not-emit-usr-bin-pkg-config-as-a.patch | 59 +++++++++++++++++++
meta/recipes-devtools/rpm/rpm_6.0.2.bb | 1 +
2 files changed, 60 insertions(+)
create mode 100644 meta/recipes-devtools/rpm/files/0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch
diff --git a/meta/recipes-devtools/rpm/files/0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch b/meta/recipes-devtools/rpm/files/0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch
new file mode 100644
index 0000000000..4b9f1e1dac
--- /dev/null
+++ b/meta/recipes-devtools/rpm/files/0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch
@@ -0,0 +1,59 @@
+From f7d33d39e48d8b8c99af1e97bcb4740a9ba6204a Mon Sep 17 00:00:00 2001
+From: Sumanth Gavini <sumanth.gavini@windriver.com>
+Date: Wed, 29 Jul 2026 09:10:47 -0700
+Subject: [PATCH] pkgconfigdeps.sh: Do not emit /usr/bin/pkg-config as a
+ Requires dependency
+
+RPM upstream commit 67b68cbeb978 ("pkgconfig dependency script fixes")
+changed the --requires output to unconditionally emit
+/usr/bin/pkg-config
+as a hard Requires for every package that ships .pc files.
+
+This is appropriate for native RPM-based distributions (e.g., Fedora,
+RHEL) where pkg-config is a target package installed alongside -devel
+packages on the same development machine. In those environments,
+requiring
+pkg-config at runtime makes sense.
+
+However, in cross-compilation environments such as OpenEmbedded/Yocto,
+pkg-config is a host-side build tool used only at compile time to locate
+libraries and their compiler/linker flags via .pc files. The target
+rootfs
+is a cross-compiled embedded image where pkg-config is not installed and
+not needed - the software is already compiled, and the .pc files in -dev
+packages are intended for SDK/sysroot use on the build host, not for
+running pkg-config on the target device.
+
+With rpm 6 using its internal dependency generator (rpm 4.x allowed
+disabling it via _use_internal_dependency_generator=0, but rpm 6 makes
+that a hard failure for v6 format packages), this file-path dependency
+ends up in every -dev package's RPM metadata, causing do_rootfs and
+do_populate_sdk failures:
+
+ Error: nothing provides /usr/bin/pkg-config needed by
+ acl-dev-2.4.0-r0.x86_64_v3 from oe-repo
+
+Remove the emission of the /usr/bin/pkg-config file path from the
+--requires output. The pkgconfig(foo) virtual provides/requires
+(e.g., pkgconfig(glib-2.0)) are not affected and continue to work
+correctly for build-time dependency resolution between recipes.
+
+Upstream-Status: Inappropriate [OE specific]
+Signed-off-by: Sumanth Gavini <sumanth.gavini@windriver.com>
+---
+ scripts/pkgconfigdeps.sh | 2 --
+ 1 file changed, 2 deletions(-)
+
+diff --git a/scripts/pkgconfigdeps.sh b/scripts/pkgconfigdeps.sh
+index ef4581856..1cab58169 100755
+--- a/scripts/pkgconfigdeps.sh
++++ b/scripts/pkgconfigdeps.sh
+@@ -43,8 +43,6 @@ case $1 in
+ while read filename ; do
+ case "${filename}" in
+ *.pc)
+- i="`expr $i + 1`"
+- [ $i -eq 1 ] && echo "$pkgconfig"
+ DIR="`dirname ${filename}`"
+ export PKG_CONFIG_PATH="$DIR:$DIR/../../share/pkgconfig"
+ $pkgconfig --print-requires --print-requires-private "$filename" 2> /dev/null | while read n r v ; do
diff --git a/meta/recipes-devtools/rpm/rpm_6.0.2.bb b/meta/recipes-devtools/rpm/rpm_6.0.2.bb
index e8977aa31a..32ddebe407 100644
--- a/meta/recipes-devtools/rpm/rpm_6.0.2.bb
+++ b/meta/recipes-devtools/rpm/rpm_6.0.2.bb
@@ -39,6 +39,7 @@ SRC_URI = "git://github.com/rpm-software-management/rpm;branch=rpm-6.0.x;protoco
file://0002-rpmio-rpmglob.c-avoid-using-GLOB_BRACE-if-undefined-.patch \
file://0001-tools-elfdeps.cc-Remove-format-module.patch \
file://0001-macros.in-Set-_pkgverify_level-to-digest-as-RCPM-4.2.patch \
+ file://0001-pkgconfigdeps.sh-Do-not-emit-usr-bin-pkg-config-as-a.patch \
"
PE = "1"
^ permalink raw reply related [flat|nested] 12+ messages in thread* Re: [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2
2026-08-04 4:08 [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Sumanth Gavini
` (7 preceding siblings ...)
2026-08-04 4:08 ` [PATCH v12 8/8] rpm: filter /usr/bin/pkg-config from RPM auto-generated Requires Sumanth Gavini
@ 2026-08-04 14:18 ` Mathieu Dubois-Briand
2026-08-04 17:18 ` Alexander Kanavin
8 siblings, 1 reply; 12+ messages in thread
From: Mathieu Dubois-Briand @ 2026-08-04 14:18 UTC (permalink / raw)
To: Sumanth Gavini, openembedded-core
Cc: alex.kanavin, mattware, esparlin, peter.marko, randy.macleod
On Tue Aug 4, 2026 at 6:08 AM CEST, Sumanth Gavini wrote:
> * V12:
> - The previous libarchive-related changes for 3.8.8 are no longer
> applicable because libarchive has been upgraded to 3.8.9. Updated the
> implementation to work with libarchive 3.8.9 and applied the upstream
> fix for "attach filter to correct bidder".
> Upstream patch: Upstream patch:
> https://github.com/libarchive/libarchive/pull/3346/
>
> - Dropped the following changes:
> rpm: lib/oe/package.py: Filter out /usr/bin/pkg-config file dependency
> rpm: Filter /usr/bin/pkg-config from RPM auto-generated Requires
>
> Why drop the old change:
> The filedeprunner() fix runs at OE's external scanning stage
> (do_package), but RPM 6's internal dependency generator runs later,
> inside rpmbuild itself. It re-adds Requires:
> /usr/bin/pkg-config regardless of what OE filtered. The old fix simply
> operates at the wrong layer it's like closing a door that RPM 6 walks
> around.
>
> Why the new changes:
> It operates at the same layer where the problem originates, inside
> rpmbuild. By setting __pkgconfig_provides and __pkgconfig_requires to
> %{nil}, we tell RPM 6's internal
> scanner to skip pkgconfigdeps.sh entirely. This is the RPM 6
> equivalent of what _use_internal_dependency_generator 0 did in RPM 4
> just scoped to pkgconfig specifically rather than globally.
>
> With these changes, the previously observed test failures have been resolved:
> - bitbake core-image-sato:do_populate_sdk
> - bitbake core-image-sato-sdk: do_rootfs
> - bitbake core-image-ptest-glib-2.0
> - bitbake core-image-ptest-libarchive
> - bitbake core-image-ptest-libarchive:do_testimage
>
Hi Sumanth,
Thanks for going further with this series.
It looks like we still have errors here. Fore reference, here is a full
build of master + this series: https://autobuilder.yoctoproject.org/valkyrie/#/builders/29/builds/4386
Basically we have again two kind of errors: some dnf issues, and some
failed selftests.
The first kind of errors:
ERROR: core-image-sato-sdk-1.0-r0 do_rootfs: Could not invoke dnf.
...
--> Starting dependency resolution
--> Finished dependency resolution
Error:
Problem 1: conflicting requests
- nothing provides pkgconfig(ogg) needed by flac-dev-1.5.0-r0.core2_64 from oe-repo
Problem 2: conflicting requests
- nothing provides pkgconfig(libxml-2.0) needed by libcomps-dev-0.1.24-r0.core2_64 from oe-repo
Problem 3: conflicting requests
- nothing provides pkgconfig(ncurses) needed by libreadline-dev-8.3-r0.core2_64 from oe-repo
Problem 4: package libsndfile-dev-1.2.2-r0.core2_64 from oe-repo requires flac-dev, but none of the providers can be installed
- conflicting requests
- nothing provides pkgconfig(ogg) needed by flac-dev-1.5.0-r0.core2_64 from oe-repo
(try to add '--skip-broken' to skip uninstallable packages)
https://autobuilder.yoctoproject.org/valkyrie/#/builders/4/builds/4318
https://autobuilder.yoctoproject.org/valkyrie/#/builders/6/builds/4327
https://autobuilder.yoctoproject.org/valkyrie/#/builders/8/builds/4337
https://autobuilder.yoctoproject.org/valkyrie/#/builders/16/builds/4336
https://autobuilder.yoctoproject.org/valkyrie/#/builders/19/builds/4299
https://autobuilder.yoctoproject.org/valkyrie/#/builders/30/builds/4279
https://autobuilder.yoctoproject.org/valkyrie/#/builders/36/builds/4293
https://autobuilder.yoctoproject.org/valkyrie/#/builders/40/builds/4280
https://autobuilder.yoctoproject.org/valkyrie/#/builders/60/builds/4297
https://autobuilder.yoctoproject.org/valkyrie/#/builders/80/builds/4138
I do note sometimes we have an error a little bit different:
ERROR: core-image-sato-1.0-r0 do_populate_sdk: Could not invoke dnf.
...
--> Starting dependency resolution
--> Finished dependency resolution
Error:
Problem 1: conflicting requests
- nothing provides pkgconfig(dbus-1) needed by connman-dev-2.0-r0.cortexa8t2hf_neon from oe-repo
Problem 2: conflicting requests
- nothing provides pkgconfig(ogg) needed by flac-dev-1.5.0-r0.cortexa8t2hf_neon from oe-repo
Problem 3: conflicting requests
- nothing provides pkgconfig(vulkan) needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(xkbcommon) needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(xkbcommon-x11) needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-allocators-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-app-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-audio-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-base-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-gl-prototypes-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-pbutils-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-sdp-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-tag-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gstreamer-video-1.0) >= 1.28.0 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(libdrm) >= 2.4.50 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(wayland-client) >= 1.4 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(xcb) >= 1.10 needed by gstreamer1.0-plugins-bad-dev-1.28.5-r0.cortexa8t2hf_neon from oe-repo
Problem 4: conflicting requests
- nothing provides pkgconfig(libxml-2.0) needed by libcomps-dev-0.1.24-r0.cortexa8t2hf_neon from oe-repo
Problem 5: conflicting requests
- nothing provides pkgconfig(ncurses) needed by libreadline-dev-8.3-r0.cortexa8t2hf_neon from oe-repo
Problem 6: conflicting requests
- nothing provides pkgconfig(cairo) >= 1.18.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(cairo-gobject) >= 1.18.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(cairo-png) >= 1.18.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(freetype2) >= 20.0.14 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(gdk-pixbuf-2.0) >= 2.20 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(harfbuzz) >= 2.0.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(libxml-2.0) >= 2.9.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(pangocairo) >= 1.50.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
- nothing provides pkgconfig(pangoft2) >= 1.50.0 needed by librsvg-2-dev-2.62.3-r0.cortexa8t2hf_neon from oe-repo
Problem 7: conflicting requests
- nothing provides pkgconfig(dbus-1) needed by ofono-dev-2.19-r0.cortexa8t2hf_neon from oe-repo
Problem 8: package libsndfile-dev-1.2.2-r0.cortexa8t2hf_neon from oe-repo requires flac-dev, but none of the providers can be installed
- conflicting requests
- nothing provides pkgconfig(ogg) needed by flac-dev-1.5.0-r0.cortexa8t2hf_neon from oe-repo
(try to add '--skip-broken' to skip uninstallable packages)
https://autobuilder.yoctoproject.org/valkyrie/#/builders/2/builds/4310
https://autobuilder.yoctoproject.org/valkyrie/#/builders/3/builds/4363
https://autobuilder.yoctoproject.org/valkyrie/#/builders/45/builds/2030
https://autobuilder.yoctoproject.org/valkyrie/#/builders/67/builds/4321
The second kind of errors. One during the
debuginfod.Debuginfod.test_debuginfod_qemu selftest:
2026-08-04 10:31:42,489 - oe-selftest - INFO - debuginfod.Debuginfod.test_debuginfod_qemu (subunit.RemotedTestCase)
2026-08-04 10:31:42,490 - oe-selftest - INFO - ... FAIL
...
2026-08-04 10:31:42,643 - oe-selftest - INFO - 6: 15/69 123/758 (134.48s) (0 failed) (debuginfod.Debuginfod.test_debuginfod_qemu)
2026-08-04 10:31:42,664 - oe-selftest - INFO - testtools.testresult.real._StringException: Traceback (most recent call last):
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/layers/openembedded-core/meta/lib/oeqa/selftest/cases/debuginfod.py", line 158, in test_debuginfod_qemu
self.assertIn("/.cache/debuginfod_client/", output)
~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/buildtools/sysroots/x86_64-pokysdk-linux/usr/lib/python3.13/unittest/case.py", line 1174, in assertIn
self.fail(self._formatMessage(msg, standardMsg))
~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/buildtools/sysroots/x86_64-pokysdk-linux/usr/lib/python3.13/unittest/case.py", line 732, in fail
raise self.failureException(msg)
AssertionError: '/.cache/debuginfod_client/' not found in 'Server query failed: No such file or directory'
And another one during runtime_test.Postinst.test_failing_postinst:
2026-08-04 10:42:26,209 - oe-selftest - INFO - runtime_test.Postinst.test_failing_postinst (subunit.RemotedTestCase)
2026-08-04 10:42:26,212 - oe-selftest - INFO - ... FAIL
...
2026-08-04 10:42:26,212 - oe-selftest - INFO - 5: 27/36 237/758 (99.84s) (0 failed) (runtime_test.Postinst.test_failing_postinst)
2026-08-04 10:42:26,213 - oe-selftest - INFO - testtools.testresult.real._StringException: Traceback (most recent call last):
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/layers/openembedded-core/meta/lib/oeqa/selftest/cases/runtime_test.py", line 409, in test_failing_postinst
self.assertGreaterEqual(bb_result.output.find("Postinstall scriptlets of ['postinst-rootfs-failing'] have failed."), 0,
~~~~~~~~~~~~~~~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
"Warning about a failed scriptlet not found in bitbake output: %s" %(bb_result.output))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/buildtools/sysroots/x86_64-pokysdk-linux/usr/lib/python3.13/unittest/case.py", line 1297, in assertGreaterEqual
self.fail(self._formatMessage(msg, standardMsg))
~~~~~~~~~^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/srv/pokybuild/yocto-worker/oe-selftest-fedora/build/buildtools/sysroots/x86_64-pokysdk-linux/usr/lib/python3.13/unittest/case.py", line 732, in fail
raise self.failureException(msg)
AssertionError: -1 not greater than or equal to 0 : Warning about a failed scriptlet not found in bitbake output: NOTE: Reconnecting to bitbake server...
Loading cache...done.
Loaded 0 entries from dependency cache.
Parsing recipes...done.
Parsing of 1039 .bb files complete (0 cached, 1039 parsed). 2089 targets, 53 skipped, 0 masked, 0 errors.
NOTE: Resolving any missing task queue dependencies
https://autobuilder.yoctoproject.org/valkyrie/#/builders/48/builds/4283
https://autobuilder.yoctoproject.org/valkyrie/#/builders/35/builds/4465
https://autobuilder.yoctoproject.org/valkyrie/#/builders/23/builds/4529
Thanks,
Mathieu
--
Mathieu Dubois-Briand, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com
^ permalink raw reply [flat|nested] 12+ messages in thread* Re: [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2
2026-08-04 14:18 ` [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2 Mathieu Dubois-Briand
@ 2026-08-04 17:18 ` Alexander Kanavin
2026-08-10 5:07 ` Gavini, Sumanth
0 siblings, 1 reply; 12+ messages in thread
From: Alexander Kanavin @ 2026-08-04 17:18 UTC (permalink / raw)
To: Mathieu Dubois-Briand
Cc: Sumanth Gavini, openembedded-core, mattware, esparlin,
peter.marko, randy.macleod
On Tue, 4 Aug 2026 at 16:18, Mathieu Dubois-Briand
<mathieu.dubois-briand@bootlin.com> wrote:
> Problem 2: conflicting requests
> - nothing provides pkgconfig(libxml-2.0) needed by libcomps-dev-0.1.24-r0.core2_64 from oe-repo
I looked into this a bit. First of all, this is easily reproducible
locally. Set up qemux86-64 poky, run 'bitbake core-image-sato-sdk' and
it will trigger.
Second, some observations:
1. Looking at tmp/work/x86-64-v3-poky-linux/libcomps/0.1.24/temp/log.do_package_write_rpm
I see:
Processing files: libcomps-dev-0.1.24-r0.x86_64_v3
...
Requires: pkgconfig(expat) pkgconfig(libxml-2.0)
So why does libcomps-dev rpm require both of these, but only
libxml-2.0 is mentioned in the error?
2. Let's first look at
tmp/work/x86-64-v3-poky-linux/expat/2.8.2/temp/log.do_package_write_rpm
Processing files: libexpat-dev-2.8.2-r0.x86_64_v3
...
Provides: expat-dev = 2.8.2 libexpat-dev = 2.8.2-r0
libexpat-dev(x86-64) = 2.8.2-r0 pkgconfig(expat) = 2.8.2
3. Then let's look at
tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/temp/log.do_package_write_rpm
Processing files: libxml2-dev-2.15.3-r0.x86_64_v3
...
Provides: libxml2-dev = 2.15.3-r0 libxml2-dev(x86-64) = 2.15.3-r0
4. So it seems that for expat rpm does write the needed pkgconfig()
provides entry, and for libxml2 it does not. Both recipes however do
install and package those files into their respective -dev packages:
$ find tmp/work/x86-64-v3-poky-linux/expat/2.8.2/packages-split/ |grep pc
tmp/work/x86-64-v3-poky-linux/expat/2.8.2/packages-split/expat-dev/usr/lib/pkgconfig/expat.pc
$ find tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/packages-split/ |grep \\.pc
tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/packages-split/libxml2-dev/usr/lib/pkgconfig/libxml-2.0.pc
5. So the next question is why is rpm picking up one as a provides
entry, but not the other. This is where I stopped, but I hope you
Sumanth can take it from here.
Cheers,
Alex
^ permalink raw reply [flat|nested] 12+ messages in thread
* Re: [PATCH v12 0/8] rpm: 4.20.1 -> 6.0.2
2026-08-04 17:18 ` Alexander Kanavin
@ 2026-08-10 5:07 ` Gavini, Sumanth
0 siblings, 0 replies; 12+ messages in thread
From: Gavini, Sumanth @ 2026-08-10 5:07 UTC (permalink / raw)
To: Alexander Kanavin, Mathieu Dubois-Briand
Cc: openembedded-core@lists.openembedded.org, mattware@cisco.com,
esparlin@cisco.com, peter.marko@siemens.com, MacLeod, Randy
On 8/4/2026 12:18 PM, Alexander Kanavin wrote:
> CAUTION: This email comes from a non Wind River email account!
> Do not click links or open attachments unless you recognize the sender and know the content is safe.
>
> On Tue, 4 Aug 2026 at 16:18, Mathieu Dubois-Briand
> <mathieu.dubois-briand@bootlin.com> wrote:
>> Problem 2: conflicting requests
>> - nothing provides pkgconfig(libxml-2.0) needed by libcomps-dev-0.1.24-r0.core2_64 from oe-repo
>
> I looked into this a bit. First of all, this is easily reproducible
> locally. Set up qemux86-64 poky, run 'bitbake core-image-sato-sdk' and
> it will trigger.
>
> Second, some observations:
>
> 1. Looking at tmp/work/x86-64-v3-poky-linux/libcomps/0.1.24/temp/log.do_package_write_rpm
> I see:
>
> Processing files: libcomps-dev-0.1.24-r0.x86_64_v3
> ...
> Requires: pkgconfig(expat) pkgconfig(libxml-2.0)
>
> So why does libcomps-dev rpm require both of these, but only
> libxml-2.0 is mentioned in the error?
>
> 2. Let's first look at
> tmp/work/x86-64-v3-poky-linux/expat/2.8.2/temp/log.do_package_write_rpm
>
> Processing files: libexpat-dev-2.8.2-r0.x86_64_v3
> ...
> Provides: expat-dev = 2.8.2 libexpat-dev = 2.8.2-r0
> libexpat-dev(x86-64) = 2.8.2-r0 pkgconfig(expat) = 2.8.2
>
> 3. Then let's look at
> tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/temp/log.do_package_write_rpm
>
> Processing files: libxml2-dev-2.15.3-r0.x86_64_v3
> ...
> Provides: libxml2-dev = 2.15.3-r0 libxml2-dev(x86-64) = 2.15.3-r0
>
> 4. So it seems that for expat rpm does write the needed pkgconfig()
> provides entry, and for libxml2 it does not. Both recipes however do
> install and package those files into their respective -dev packages:
>
> $ find tmp/work/x86-64-v3-poky-linux/expat/2.8.2/packages-split/ |grep pc
> tmp/work/x86-64-v3-poky-linux/expat/2.8.2/packages-split/expat-dev/usr/lib/pkgconfig/expat.pc
> $ find tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/packages-split/ |grep \\.pc
> tmp/work/x86-64-v3-poky-linux/libxml2/2.15.3/packages-split/libxml2-dev/usr/lib/pkgconfig/libxml-2.0.pc
>
> 5. So the next question is why is rpm picking up one as a provides
> entry, but not the other. This is where I stopped, but I hope you
> Sumanth can take it from here.
>
> Cheers,
> Alex
Hi Mathieu,
I have resolved the reported issues and successfully tested the
following test cases.
If you encounter any failures, please verify them locally and provide
detailed reproduction steps.
For validation, I used the following configuration:
bitbake-setup with poky, without sstate, and qemux86
bitbake core-image-sato -c populate_sdk
bitbake core-image-sato-sdk -c rootfs
oe-selftest -r debuginfod.Debuginfod.test_debuginfod_qemu
Alex, thanks for the quick verification and for providing the
reproduction steps. They were helpful in identifying and resolving the
issue.
--
# Sumanth Gavini
# Wind River Linux
^ permalink raw reply [flat|nested] 12+ messages in thread