From: Randy MacLeod Date: Sat, 30 Aug 2025 17:02:36 +0000 (-0400) Subject: util-linux: include/mount-api-utils: avoid using sys/mount.h X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=67f17867c605bc0e1ca69ab9dec6209e85c38c1e;p=thirdparty%2Fopenembedded%2Fopenembedded-core-contrib.git util-linux: include/mount-api-utils: avoid using sys/mount.h Avoid compile error: | In file included from /usr/include/linux/fs.h:19, | from /usr/include/linux/btrfs.h:29, | from ../sources/util-linux-2.41.1/libmount/src/btrfs.c:18: | /usr/include/x86_64-linux-gnu/sys/mount.h:35:3: \ error: expected identifier before numeric constant | 35 | MS_RDONLY = 1, /* Mount read-only. */ | | ^~~~~~~~~ This is seen on PopOS 22.04, an Ubuntu/Debian-based distro. Signed-off-by: Randy MacLeod Signed-off-by: Mathieu Dubois-Briand Signed-off-by: Richard Purdie --- diff --git a/meta/recipes-core/util-linux/util-linux.inc b/meta/recipes-core/util-linux/util-linux.inc index c5698d9cab8..4c1105b6aec 100644 --- a/meta/recipes-core/util-linux/util-linux.inc +++ b/meta/recipes-core/util-linux/util-linux.inc @@ -21,6 +21,7 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/util-linux/v${MAJOR_VERSION}/util-lin file://0001-lsfd-mkfds-foreign-sockets-skip-when-lacking-sock_di.patch \ file://0001-ts-kill-decode-use-RTMIN-from-kill-L-instead-of-hard.patch \ file://0001-tests-helpers-test_sigstate.c-explicitly-reset-SIGIN.patch \ + file://0001-include-mount-api-utils-avoid-using-sys-mount.h.patch \ " SRC_URI[sha256sum] = "be9ad9a276f4305ab7dd2f5225c8be1ff54352f565ff4dede9628c1aaa7dec57" diff --git a/meta/recipes-core/util-linux/util-linux/0001-include-mount-api-utils-avoid-using-sys-mount.h.patch b/meta/recipes-core/util-linux/util-linux/0001-include-mount-api-utils-avoid-using-sys-mount.h.patch new file mode 100644 index 00000000000..544f45362d4 --- /dev/null +++ b/meta/recipes-core/util-linux/util-linux/0001-include-mount-api-utils-avoid-using-sys-mount.h.patch @@ -0,0 +1,29 @@ +From 2a9b48d20d74f65ac708b3bcee6a7e2a61aadf88 Mon Sep 17 00:00:00 2001 +From: Karel Zak +Date: Thu, 21 Aug 2025 09:59:10 +0200 +Subject: [PATCH] include/mount-api-utils: avoid using sys/mount.h + +The file is unnecessary and introduces duplicate #define of MS_* macros. + +Fixes: https://github.com/util-linux/util-linux/issues/3674 +Signed-off-by: Karel Zak +Upstream-Status: Backport [https://github.com/util-linux/util-linux/commit/2a9b48d20d74f65ac708b3bcee6a7e2a61aadf88] +--- + include/mount-api-utils.h | 1 - + 1 file changed, 1 deletion(-) + +diff --git a/include/mount-api-utils.h b/include/mount-api-utils.h +index 920d6766a..e35524168 100644 +--- a/include/mount-api-utils.h ++++ b/include/mount-api-utils.h +@@ -6,7 +6,6 @@ + #define UTIL_LINUX_MOUNT_API_UTILS + + #ifdef HAVE_LINUX_MOUNT_H +-#include + #include + #include + #include +-- +2.34.1 +