procps: upgrade from 4.0.5 to 4.0.6
PATCH 1/2 procps: upgrade from 4.0.5 to 4.0.6
Remove patch top_large_pid_fix.patch, already in 4.0.6
---
.../procps/procps/top_large_pid_fix.patch | 52 -------------------
.../{procps_4.0.5.bb => procps_4.0.6.bb} | 3 +-
2 files changed, 1 insertion(+), 54 deletions(-)
delete mode 100644 meta/recipes-extended/procps/procps/top_large_pid_fix.patch
rename meta/recipes-extended/procps/{procps_4.0.5.bb => procps_4.0.6.bb} (97%)meta/recipes-extended/procps/procps/top_large_pid_fix.patch deleted +0 -52
@@ -1,52 +0,0 @@ -From f21fc624d960d12afa399af7333d4f9193fb2ffb Mon Sep 17 00:00:00 2001 -From: Jim Warner <[email protected]> -Date: Tue, 16 Sep 2025 12:00:00 -0500 -Subject: [PATCH] library: avoid possible segmentation fault, <pids> api -Upstream-Status: Backport -[https://gitlab.com/procps-ng/procps/-/commit/5461b50b1a85c5e556c4cd2739ca8ffdbc69399a] - -In the issue referenced below, that SEGV was caused by -passing a '-1' pid to the procps_pids_select function. -That value, in turn, is caused by providing a LONG_MAX -or greater number for what was assigned to an integer. - -So, this commit will help ensure we avoid a match when -we should fail plus skip some unproductive libc calls. - -[ the same problem occurs in that old 3.3.17 library ] - -Reference(s): -https://gitlab.com/procps-ng/procps/-/issues/394 - -Signed-off-by: Jim Warner <[email protected]> -Signed-off-by: Amaury Couderc <[email protected]> - ---- - library/readproc.c | 4 ++-- - 1 file changed, 2 insertions(+), 2 deletions(-) - -diff --git a/library/readproc.c b/library/readproc.c -index 2dfe4c9e..d0e039bf 100644 ---- a/library/readproc.c -+++ b/library/readproc.c -@@ -1434,7 +1434,7 @@ static int listed_nextpid (PROCTAB *PT, proc_t *p) { - pid_t pid = *(PT->pids)++; - char *path = PT->path; - -- if (pid) { -+ if (pid > 0) { - snprintf(path, PROCPATHLEN, "/proc/%d", pid); - p->tid = p->tgid = pid; // this tgid may be a huge fib | - -@@ -1546,7 +1546,7 @@ PROCTAB *openproc(unsigned flags, ...) { - did_stat = 1; - } - PT->taskdir = NULL; -- PT->taskdir_user = -1; -+ PT->taskdir_user = -2; - PT->taskfinder = simple_nexttid; - PT->taskreader = simple_readtask; - --- -2.43.0 -
meta/recipes-extended/procps/procps_4.0.6.bb renamed from meta/recipes-extended/procps/procps_4.0.5.bb +1 -2
@@ -14,9 +14,8 @@ inherit autotools gettext pkgconfig update-alternatives SRC_URI = "git://gitlab.com/procps-ng/procps.git;protocol=https;branch=master;tag=v${PV} \ file://sysctl.conf \ - file://top_large_pid_fix.patch \ " -SRCREV = "f46b2f7929cdfe2913ed0a7f585b09d6adbf994e" +SRCREV = "4dafddf4c3f4646caa517f039a2307e92657ec93" # Upstream has a custom autogen.sh which invokes po/update-potfiles as they # don't ship a po/POTFILES.in (which is silly). Without that file gettext
Signature · 1 line
2.34.1
PATCH 2/2 procps: support ptest when TCLIBC is glibc
* support ptest for procps TCLIBC is glibc. The configure.ac only match LINUX as "linux-gnu", we can patch it to make test can run on musl lib
system, but the upstream testsuite should only run on gnu libc host, some test cases only suitable for glibc, eg: Some of the error messages for free command on musl system is not the same as glibc system, which will make test failed. In order to avoid some other unexpected failure, just support ptest for glibc.
* procps's testsuite use DejaGnu test framework. The testsuite is expected to run during build time, this implementation create the same
folder structure as the testsuite expected to make it can work well.
--- .../distro/include/ptest-packagelists.inc | 2 + ...sts-Disable-twice-total-pmap-X-tests.patch | 55 ++++++++++++++++++ meta/recipes-extended/procps/procps/run-ptest | 24 ++++++++ meta/recipes-extended/procps/procps_4.0.6.bb | 57 ++++++++++++++++++- 4 files changed, 137 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch create mode 100644 meta/recipes-extended/procps/procps/run-ptest
meta/conf/distro/include/ptest-packagelists.inc +2 -0
@@ -59,6 +59,7 @@ PTESTS_FAST = "\ nettle \ opkg \ popt \ + procps \ python3-atomicwrites \ python3-attrs \ python3-bcrypt \
@@ -99,6 +100,7 @@ PTESTS_FAST:remove:mips64 = "qemu" PTESTS_PROBLEMS:append:mips64 = " qemu" PTESTS_FAST:remove:riscv32 = "qemu" PTESTS_PROBLEMS:append:riscv32 = " qemu" +PTESTS_FAST:remove:libc-musl = "procps" PTESTS_SLOW = "\ apr \
meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch new file +55 -0
55 lines not on this page · raw message
meta/recipes-extended/procps/procps/run-ptest new file +24 -0
@@ -0,0 +1,24 @@ +#!/bin/sh + +# Run testsuite which use dejagnu +cd ./testsuite +for tool in @DEJATOOL@; do + runtest -a --tool $tool --outdir ../log +done +cd - + +# Run test programs not used by dejagnu but run directly +for p in @TESTS@; do + ./src/tests/"$p" > ./log/"$p".log 2>&1 + case "$?" in + 0) + echo "PASS: $p" + ;; + 77) + echo "SKIP: $p" + ;; + *) + echo "FAIL: $p" + ;; + esac +done
meta/recipes-extended/procps/procps_4.0.6.bb +56 -1
78 lines not on this page · raw message
Signature · 1 line
2.34.1
Re: [OE-core] [PATCH 2/2] procps: support ptest when TCLIBC is glibc
Hi,
Quoted 9 lines · Changqing Li via lists.openembedded.org
* support ptest for procps TCLIBC is glibc. The configure.ac only match LINUX as "linux-gnu", we can patch it to make test can run on musl lib
system, but the upstream testsuite should only run on gnu libc host, some test cases only suitable for glibc, eg: Some of the error messages for free command on musl system is not the same as glibc system, which will make test failed. In order to avoid some other unexpected failure, just support ptest for glibc.
Quoted 3 lines
* procps's testsuite use DejaGnu test framework. The testsuite is expected to run during build time, this implementation create the same
folder structure as the testsuite expected to make it can work well.
I filed a bug for musl support just now, https://gitlab.com/procps-ng/procps/-/issues/420. Please link to this in your changes.
I think we should build the tests for everything, and skip the few tests which break. In my testing in an alpine container there are five failing tests, but it seems that two of them are busybox related so we can resolve that with dependencies to pull in the proper tools.
Ross
Re: [OE-core] [PATCH 2/2] procps: support ptest when TCLIBC is glibc
Quoted 14 lines · Ross Burton
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.Hi,
Quoted 8 lines · Changqing Li via lists.openembedded.org
* support ptest for procps TCLIBC is glibc. The configure.ac only match LINUX as "linux-gnu", we can patch it to make test can run on musl lib
system, but the upstream testsuite should only run on gnu libc host, some test cases only suitable for glibc, eg: Some of the error messages for free command on musl system is not the same as glibc system, which will make test failed. In order to avoid some other unexpected failure, just support ptest for glibc.
Quoted 4 lines
Quoted 3 lines
* procps's testsuite use DejaGnu test framework. The testsuite is expected to run during build time, this implementation create the same
folder structure as the testsuite expected to make it can work well.I filed a bug for musl support just now, https://gitlab.com/procps-ng/procps/-/issues/420. Please link to this in your changes.
OK. I will update the commit message in V2.
Quoted 2 lines
I think we should build the tests for everything, and skip the few tests which break. In my testing in an alpine container there are five failing tests, but it seems that two of them are busybox related so we can resolve that with dependencies to pull in the proper tools.
Maybe we can add musl support later after upstream add musl support.
//Changqing
Quoted 1 line
Ross
PATCH v2 1/1 procps: support ptest when TCLIBC is glibc
In reply to Ross Burton* Support ptest for procps TCLIBC is glibc. The configure.ac only match LINUX as "linux-gnu", we can patch it to make test can run on musl lib
system, but the upstream testsuite should only run on gnu libc host, some test cases only suitable for glibc, eg: Some of the error messages for free command on musl system is not the same as glibc system, which will make test failed. In order to avoid some other unexpected failure, just support ptest for glibc.
* Bug [1] is filed for musl support, we may can add support for musl libc later when upstream add the musl support
* procps's testsuite use DejaGnu test framework. The testsuite is expected to run during build time, this implementation create the same
folder structure as the testsuite expected to make it can work well.
[1] https://gitlab.com/procps-ng/procps/-/issues/420
--- .../distro/include/ptest-packagelists.inc | 2 + ...sts-Disable-twice-total-pmap-X-tests.patch | 55 ++++++++++++++++++ meta/recipes-extended/procps/procps/run-ptest | 24 ++++++++ meta/recipes-extended/procps/procps_4.0.6.bb | 57 ++++++++++++++++++- 4 files changed, 137 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch create mode 100644 meta/recipes-extended/procps/procps/run-ptest
meta/conf/distro/include/ptest-packagelists.inc +2 -0
@@ -59,6 +59,7 @@ PTESTS_FAST = "\ nettle \ opkg \ popt \ + procps \ python3-atomicwrites \ python3-attrs \ python3-bcrypt \
@@ -99,6 +100,7 @@ PTESTS_FAST:remove:mips64 = "qemu" PTESTS_PROBLEMS:append:mips64 = " qemu" PTESTS_FAST:remove:riscv32 = "qemu" PTESTS_PROBLEMS:append:riscv32 = " qemu" +PTESTS_FAST:remove:libc-musl = "procps" PTESTS_SLOW = "\ apr \
meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch new file +55 -0
55 lines not on this page · raw message
meta/recipes-extended/procps/procps/run-ptest new file +24 -0
@@ -0,0 +1,24 @@ +#!/bin/sh + +# Run testsuite which use dejagnu +cd ./testsuite +for tool in @DEJATOOL@; do + runtest -a --tool $tool --outdir ../log +done +cd - + +# Run test programs not used by dejagnu but run directly +for p in @TESTS@; do + ./src/tests/"$p" > ./log/"$p".log 2>&1 + case "$?" in + 0) + echo "PASS: $p" + ;; + 77) + echo "SKIP: $p" + ;; + *) + echo "FAIL: $p" + ;; + esac +done
meta/recipes-extended/procps/procps_4.0.6.bb +56 -1
78 lines not on this page · raw message
Signature · 1 line
2.34.1
Re: [OE-core] [PATCH V2] procps: support ptest when TCLIBC is glibc
meta/recipes-extended/procps/procps_4.0.6.bb LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \ · line 13
Quoted 2 lines · Changqing Li via lists.openembedded.org
meta/recipes-extended/procps/procps_4.0.6.bb +1
-1-inherit autotools gettext pkgconfig update-alternatives +inherit autotools gettext pkgconfig update-alternatives ${@bb.utils.contains('TCLIBC', 'glibc', 'ptest', '', d)}
To match the logic in the ptest image where the test is “disable if musl” not “enable if glibc”, you could always inherit ptest and then simply do PTEST_ENABLED:libc-musl = “0”
meta/recipes-extended/procps/procps_4.0.6.bb do_install:append () { · line 74
Quoted 4 lines
meta/recipes-extended/procps/procps_4.0.6.bb +4
-0+ src/tests/*) + install -m 0755 ${B}/$p ${D}${PTEST_PATH}/src/tests/ ;; + library/tests/*) + install -m 0755 ${B}/library/tests/.libs/$(basename $p) ${D}${PTEST_PATH}/src/tests/ ;;
If libtool build a binary then please always use libtool to install it. You might be able to remove the conditional here and just always do:
${B}/libtool —mode=install install -m 0755 ${B}/$p ${D}${PTEST_PATH}/src/tests/
Ross
PATCH v3 1/1 procps: support ptest when TCLIBC is glibc
From: "Changqing Li via lists.openembedded.org" <[email protected]>
* Support ptest for procps TCLIBC is glibc. The configure.ac only match LINUX as "linux-gnu", we can patch it to make test can run on musl lib
system, but the upstream testsuite should only run on gnu libc host, some test cases only suitable for glibc, eg: Some of the error messages for free command on musl system is not the same as glibc system, which will make test failed. In order to avoid some other unexpected failure, just support ptest for glibc.
* Bug [1] is filed for musl support, we may can add support for musl libc later when upstream add the musl support
* procps's testsuite use DejaGnu test framework. The testsuite is expected to run during build time, this implementation create the same
folder structure as the testsuite expected to make it can work well.
[1] https://gitlab.com/procps-ng/procps/-/issues/420
--- .../distro/include/ptest-packagelists.inc | 2 + ...sts-Disable-twice-total-pmap-X-tests.patch | 55 +++++++++++++++++++ meta/recipes-extended/procps/procps/run-ptest | 24 ++++++++ meta/recipes-extended/procps/procps_4.0.6.bb | 54 +++++++++++++++++- 4 files changed, 134 insertions(+), 1 deletion(-) create mode 100644 meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch create mode 100644 meta/recipes-extended/procps/procps/run-ptest
meta/conf/distro/include/ptest-packagelists.inc +2 -0
@@ -64,6 +64,7 @@ PTESTS_FAST = "\ nettle \ opkg \ popt \ + procps \ python3-atomicwrites \ python3-attrs \ python3-bcrypt \
@@ -104,6 +105,7 @@ PTESTS_FAST:remove:mips64 = "qemu" PTESTS_PROBLEMS:append:mips64 = " qemu" PTESTS_FAST:remove:riscv32 = "qemu" PTESTS_PROBLEMS:append:riscv32 = " qemu" +PTESTS_FAST:remove:libc-musl = "procps" PTESTS_SLOW = "\ apr \
meta/recipes-extended/procps/procps/0001-tests-Disable-twice-total-pmap-X-tests.patch new file +55 -0
55 lines not on this page · raw message
meta/recipes-extended/procps/procps/run-ptest new file +24 -0
@@ -0,0 +1,24 @@ +#!/bin/sh + +# Run testsuite which use dejagnu +cd ./testsuite +for tool in @DEJATOOL@; do + runtest -a --tool $tool --outdir ../log +done +cd - + +# Run test programs not used by dejagnu but run directly +for p in @TESTS@; do + ./src/tests/"$p" > ./log/"$p".log 2>&1 + case "$?" in + 0) + echo "PASS: $p" + ;; + 77) + echo "SKIP: $p" + ;; + *) + echo "FAIL: $p" + ;; + esac +done
meta/recipes-extended/procps/procps_4.0.6.bb +53 -1
81 lines not on this page · raw message
Signature · 1 line
2.34.1