Skip to contentSkip to conversation

util-linux/util-linux-libuuid: upgrade from 2.40.4 to 2.41

PATCH Superseded [email protected] 2 participants 3 messages May 16, 2025 – May 24, 2025

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 util-linux/util-linux-libuuid: upgrade from 2.40.4 to 2.41

From: Chen Qi <[email protected]>

License-Update: add EUPL-1.2.
See https://github.com/util-linux/util-linux/commit/74f3265b9a079f9f60ad6e606d77deae0029a43a

The run-ptest script is changed to use --builddir. This is because util-linux upstream does not have much priority on testing the --use-system-commands option. For example, with --use-system-commands, we have two failed test cases: kill/decode and lsfd/mkfds-foreign-sockets. With --builddir, all test cases succeed. I created PR for the kill/decode
issue: https://github.com/util-linux/util-linux/pull/3571. The root cause is obvious for kill/decode. But the root cause for lsfd/mkfds-foreign-sockets is not obvious, at least to me. So instead of spending time fixing test case issues for --use-system-commands, we'd better just use --builddir.

---
 ...d_2.40.4.bb => util-linux-libuuid_2.41.bb} |   3 -
 meta/recipes-core/util-linux/util-linux.inc   |  10 +-
 ...dd-sector-size-commanand-line-option.patch |  90 ---------------
 ...dd-sector-size-commanand-line-option.patch | 105 ------------------
 .../util-linux/avoid_parallel_tests.patch     |   4 +-
 .../util-linux/configure-sbindir.patch        |   4 +-
 .../display_testname_for_subtest.patch        |   6 +-
 .../util-linux/util-linux/ptest.patch         |   6 +-
 .../util-linux/util-linux/run-ptest           |   6 +-
 ...til-linux_2.40.4.bb => util-linux_2.41.bb} |   1 +
 10 files changed, 17 insertions(+), 218 deletions(-)
 rename meta/recipes-core/util-linux/{util-linux-libuuid_2.40.4.bb => util-linux-libuuid_2.41.bb} (74%)
 delete mode 100644 meta/recipes-core/util-linux/util-linux/0001-cfdisk-add-sector-size-commanand-line-option.patch
 delete mode 100644 meta/recipes-core/util-linux/util-linux/0002-sfdisk-add-sector-size-commanand-line-option.patch
 rename meta/recipes-core/util-linux/{util-linux_2.40.4.bb => util-linux_2.41.bb} (99%)
meta/recipes-core/util-linux/util-linux-libuuid_2.41.bb renamed from meta/recipes-core/util-linux/util-linux-libuuid_2.40.4.bb +0 -3
similarity index 74%
rename from meta/recipes-core/util-linux/util-linux-libuuid_2.40.4.bb
rename to meta/recipes-core/util-linux/util-linux-libuuid_2.41.bb
index ec04c1d384..e25f0e47c2 100644
@@ -1,6 +1,3 @@
-# To allow util-linux to optionally build-depend on cryptsetup, libuuid is
-# split out of the main recipe, as it's needed by cryptsetup
-
 require util-linux.inc
 
 inherit autotools gettext pkgconfig
meta/recipes-core/util-linux/util-linux.inc +5 -5
index 4e8701ffdf..50c3ba5c2c 100644
@@ -6,20 +6,22 @@ disk partitioning, kernel message management, filesystem creation, and system lo
 
 SECTION = "base"
 
-LICENSE = "GPL-1.0-or-later & GPL-2.0-only & GPL-2.0-or-later & LGPL-2.1-or-later & BSD-2-Clause & BSD-3-Clause & BSD-4-Clause-UC & MIT"
+LICENSE = "GPL-1.0-or-later & GPL-2.0-only & GPL-2.0-or-later & LGPL-2.1-or-later & BSD-2-Clause & BSD-3-Clause & BSD-4-Clause-UC & MIT & EUPL-1.2"
 LICENSE:${PN}-fcntl-lock = "MIT"
 LICENSE:${PN}-fdisk = "GPL-1.0-or-later"
 LICENSE:${PN}-libblkid = "LGPL-2.1-or-later"
 LICENSE:${PN}-libfdisk = "LGPL-2.1-or-later"
 LICENSE:${PN}-libmount = "LGPL-2.1-or-later"
 LICENSE:${PN}-libsmartcols = "LGPL-2.1-or-later"
+LICENSE:${PN}-coresched = "EUPL-1.2"
 
-LIC_FILES_CHKSUM = "file://README.licensing;md5=ddd58b6c94da86ff4f03e91208eb9cfc \
+LIC_FILES_CHKSUM = "file://README.licensing;md5=55e895a80bdd4ffc65e167a76d2e7569 \
                     file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
                     file://Documentation/licenses/COPYING.GPL-2.0-or-later;md5=b234ee4d69f5fce4486a80fdaf4a4263 \
                     file://Documentation/licenses/COPYING.LGPL-2.1-or-later;md5=4fbd65380cdd255951079008b364516c \
                     file://Documentation/licenses/COPYING.BSD-3-Clause;md5=58dcd8452651fc8b07d1f65ce07ca8af \
                     file://Documentation/licenses/COPYING.BSD-4-Clause-UC;md5=263860f8968d8bafa5392cab74285262 \
+                    file://Documentation/licenses/COPYING.EUPL-1.2;md5=c075d2767167a2355b23392018a1cbbd \
                     file://libuuid/COPYING;md5=6d2cafc999feb2c2de84d4d24b23290c \
                     file://libmount/COPYING;md5=7c7e39fb7d70ffe5d693a643e29987c2 \
                     file://libblkid/COPYING;md5=693bcbbe16d3a4a4b37bc906bc01cc04 \
@@ -38,10 +40,8 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/util-linux/v${MAJOR_VERSION}/util-lin
            file://display_testname_for_subtest.patch \
            file://avoid_parallel_tests.patch \
            file://fcntl-lock.c \
-           file://0001-cfdisk-add-sector-size-commanand-line-option.patch \
-           file://0002-sfdisk-add-sector-size-commanand-line-option.patch \
            "
 
-SRC_URI[sha256sum] = "5c1daf733b04e9859afdc3bd87cc481180ee0f88b5c0946b16fdec931975fb79"
+SRC_URI[sha256sum] = "81ee93b3cfdfeb7d7c4090cedeba1d7bbce9141fd0b501b686b3fe475ddca4c6"
 
 CVE_PRODUCT = "util-linux"
meta/recipes-core/util-linux/util-linux/0001-cfdisk-add-sector-size-commanand-line-option.patch deleted +0 -90

90 lines not on this page · raw message

meta/recipes-core/util-linux/util-linux/0002-sfdisk-add-sector-size-commanand-line-option.patch deleted +0 -105

105 lines not on this page · raw message

meta/recipes-core/util-linux/util-linux/avoid_parallel_tests.patch +2 -2
index 8ea00dbb95..fe92afbc53 100644
@@ -1,4 +1,4 @@
-From da58b4150f6932de36c962ea657713bcf4ea44be Mon Sep 17 00:00:00 2001
+From 43030388e831642d36cb7b9d4b63755e9696714a Mon Sep 17 00:00:00 2001
 From: Tudor Florea <[email protected]>
 Date: Mon, 14 Jun 2021 14:00:31 +0200
 Subject: [PATCH] util-linux: Add ptest
@@ -14,7 +14,7 @@ Upstream-Status: Inappropriate
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index 651ef2b..2a8012e 100644
+index 43a23a5..4a84531 100644
 --- a/configure.ac
 +++ b/configure.ac
 @@ -11,7 +11,7 @@ AC_CONFIG_MACRO_DIR([m4])
meta/recipes-core/util-linux/util-linux/configure-sbindir.patch +2 -2
index 74abdc2038..ebb32a6845 100644
@@ -1,4 +1,4 @@
-From 0387d71516c978899cfd556ca512f530a212b4a9 Mon Sep 17 00:00:00 2001
+From 378998bf82e3b6ff46569077b29f95e72b734681 Mon Sep 17 00:00:00 2001
 From: Phil Blundell <[email protected]>
 Date: Mon, 24 Sep 2012 07:24:51 +0100
 Subject: [PATCH] util-linux: Ensure that ${sbindir} is respected
@@ -14,7 +14,7 @@ Upstream-Status: Inappropriate [configuration]
  1 file changed, 4 insertions(+), 1 deletion(-)
 
 diff --git a/configure.ac b/configure.ac
-index 23594ff..651ef2b 100644
+index a5d9102..43a23a5 100644
 --- a/configure.ac
 +++ b/configure.ac
 @@ -110,7 +110,10 @@ AC_SUBST([runstatedir])
meta/recipes-core/util-linux/util-linux/display_testname_for_subtest.patch +3 -3
index 871b0b2d30..fa4ae02bc3 100644
@@ -1,4 +1,4 @@
-From 45450d0339cd7ee27f53c0f2fac1cc74ed9bbfb8 Mon Sep 17 00:00:00 2001
+From 728c2abd889d225535008c3e7a1eef4b8a0aeea2 Mon Sep 17 00:00:00 2001
 From: Tudor Florea <[email protected]>
 Date: Thu, 3 Dec 2015 04:08:00 +0100
 Subject: [PATCH] Display testname for subtest
@@ -10,10 +10,10 @@ Upstream-Status: Pending
  1 file changed, 1 insertion(+), 1 deletion(-)
 
 diff --git a/tests/functions.sh b/tests/functions.sh
-index 5fe5ba0..a6c703e 100644
+index 1d7a425..b1f0986 100644
 --- a/tests/functions.sh
 +++ b/tests/functions.sh
-@@ -450,7 +450,7 @@ function ts_init_subtest {
+@@ -455,7 +455,7 @@ function ts_init_subtest {
  
  	if [ "$TS_PARSABLE" != "yes" ]; then
  		[ $TS_NSUBTESTS -eq 1 ] && echo
meta/recipes-core/util-linux/util-linux/ptest.patch +3 -3
index 7345926b88..ad23001cfa 100644
@@ -1,4 +1,4 @@
-From f9be73c3e2b0a4f0923950dcb058be85d3ee8ed7 Mon Sep 17 00:00:00 2001
+From 18bf6aded9b2a75185ae4b23a41cd2e4322c5e31 Mon Sep 17 00:00:00 2001
 From: Tudor Florea <[email protected]>
 Date: Thu, 3 Dec 2015 04:08:00 +0100
 Subject: [PATCH] Define TESTS variable
@@ -10,10 +10,10 @@ Upstream-Status: Pending
  1 file changed, 1 insertion(+)
 
 diff --git a/Makefile.am b/Makefile.am
-index 50ab8d0..7e2340d 100644
+index 01e9970..c3313ff 100644
 --- a/Makefile.am
 +++ b/Makefile.am
-@@ -64,6 +64,7 @@ tmpfiles_DATA =
+@@ -66,6 +66,7 @@ sysusers_DATA =
  dist_bashcompletion_DATA =
  check_PROGRAMS =
  dist_check_SCRIPTS =
meta/recipes-core/util-linux/util-linux/run-ptest +1 -5
index 6886b66c49..59a14aedfd 100644
@@ -9,10 +9,6 @@ if [ "x$UDEV_PID" != "x" ]; then
     /etc/init.d/udev stop
 fi
 
-current_path=$(readlink -f $0)
-export bindir=$(dirname $current_path)
-export PATH=$bindir/bin:$PATH
-
 # losetup tests will be skipped and/or fail otherwise
 modprobe loop
 
@@ -25,7 +21,7 @@ mount --make-shared /
 # lsfd/option-inet has races in the test script:
 # https://github.com/util-linux/util-linux/issues/2399
 # lsfd/mkfds-bpf* have issues with the gcc 15 upgrade
-./tests/run.sh --use-system-commands --parsable --show-diff --exclude='lsfd/option-inet lsfd/mkfds-bpf-map lsfd/mkfds-bpf-prog' | sed -u '{
+./tests/run.sh --builddir=@PTEST_PATH@ --parsable --show-diff --exclude='lsfd/option-inet lsfd/mkfds-bpf-map lsfd/mkfds-bpf-prog' | sed -u '{
       s/^\(.*\):\(.*\) \.\.\. OK$/PASS: \1:\2/                              
       s/^\(.*\):\(.*\) \.\.\. FAILED \(.*\)$/FAIL: \1:\2 \3/                
       s/^\(.*\):\(.*\) \.\.\. SKIPPED \(.*\)$/SKIP: \1:\2 \3/               
meta/recipes-core/util-linux/util-linux_2.41.bb renamed from meta/recipes-core/util-linux/util-linux_2.40.4.bb +1 -0
similarity index 99%
rename from meta/recipes-core/util-linux/util-linux_2.40.4.bb
rename to meta/recipes-core/util-linux/util-linux_2.41.bb
index 81bd298dd9..28bed9e584 100644
@@ -355,6 +355,7 @@ do_install_ptest() {
     cp ${B}/config.h ${D}${PTEST_PATH}
 
     sed -i 's|@base_sbindir@|${base_sbindir}|g' ${D}${PTEST_PATH}/run-ptest
+    sed -i 's|@PTEST_PATH@|${PTEST_PATH}|g' ${D}${PTEST_PATH}/run-ptest
 
     # chfn needs PAM
     if ! ${@bb.utils.contains('PACKAGECONFIG', 'pam', 'true', 'false', d)}; then
Signature · 1 line
2.34.1
#1 lore raw
Quoted 4 lines · Chen Qi via lists.openembedded.org

The run-ptest script is changed to use --builddir. This is because util-linux upstream does not have much priority on testing the --use-system-commands option

We spent about five minutes staring at this in the patch review call, wondering how it would work as --builddir=@PTEST_PATH@ points at /usr/lib/util-linux/ptest but the binary symlinks are in /usr/lib/util-linux/ptest/bin.

And indeed, it doesn’t:

SKIP:            su: environ                                       (su not found)
SKIP:        swapon: by devname                                    (mkswap not found)
SKIP:        swapon: fix page size                                 (mkswap not found)
SKIP:        swapon: fix signature                                 (mkswap not found)
SKIP:        swapon: by label                                      (mkswap not found)
SKIP:        swapon: by uuid                                       (mkswap not found)
SKIP:            ul: basic tests                                   (ul not found)
SKIP:            ul: ul                                            (ul not found)
SKIP:          utmp: last                                          (last not found)
SKIP:          utmp: last ipv6                                     (last not found)
SKIP:          utmp: circle                                        (utmpdump not found)
SKIP:          utmp: subsecond                                     (utmpdump not found)
SKIP:          utmp: to binary                                     (utmpdump not found)
SKIP:          utmp: IPv6 to binary                                (utmpdump not found)
SKIP:          utmp: to text                                       (utmpdump not found)
SKIP:          utmp: IPv6 to text                                  (utmpdump not found)

I think it would be best to switch back to using —system-commands and fixing that last failure.

Ross

author
#2 lore raw

Thanks for spotting this. I saw some "PASS" in test result, so I thought things worked. I'll re-work on this ASAP.

Regards,
Qi

-----Original Message-----
From: Ross Burton <[email protected]>
Sent: Thursday, May 22, 2025 9:22 PM
To: Chen, Qi <[email protected]>
Cc: [email protected]
Subject: Re: [OE-core][PATCH] util-linux/util-linux-libuuid: upgrade from 2.40.4 to 2.41

Quoted 4 lines · Chen Qi via lists.openembedded.org

The run-ptest script is changed to use --builddir. This is because util-linux upstream does not have much priority on testing the --use-system-commands option

We spent about five minutes staring at this in the patch review call, wondering how it would work as --builddir=@PTEST_PATH@ points at /usr/lib/util-linux/ptest but the binary symlinks are in /usr/lib/util-linux/ptest/bin.

And indeed, it doesn’t:

SKIP:            su: environ                                       (su not found)
SKIP:        swapon: by devname                                    (mkswap not found)
SKIP:        swapon: fix page size                                 (mkswap not found)
SKIP:        swapon: fix signature                                 (mkswap not found)
SKIP:        swapon: by label                                      (mkswap not found)
SKIP:        swapon: by uuid                                       (mkswap not found)
SKIP:            ul: basic tests                                   (ul not found)
SKIP:            ul: ul                                            (ul not found)
SKIP:          utmp: last                                          (last not found)
SKIP:          utmp: last ipv6                                     (last not found)
SKIP:          utmp: circle                                        (utmpdump not found)
SKIP:          utmp: subsecond                                     (utmpdump not found)
SKIP:          utmp: to binary                                     (utmpdump not found)
SKIP:          utmp: IPv6 to binary                                (utmpdump not found)
SKIP:          utmp: to text                                       (utmpdump not found)
SKIP:          utmp: IPv6 to text                                  (utmpdump not found)

I think it would be best to switch back to using —system-commands and fixing that last failure.

Ross