ChangeLog: https://www.kernel.org/pub/linux/utils/nfs-utils/2.9.2/2.9.2-Changelog
Drop 0001-fh_key_file.c-Fix-build-error-for-musl.patch (fixed upstream). Add patches to fix build failures: - Fix link error with --disable-nfsdctl (undefined reference to nfsd_nl_cmd_str) - Fix musl build (missing stddef.h for offsetof in getport.c) Both reported to [email protected]. Signed-off-by: Jaipaul Cheernam <[email protected]> --- Changes in v2: - Drop 0001-fh_key_file.c patch (fixed upstream in 2.9.2) - Add patch to fix musl build (missing stddef.h for offsetof in getport.c) ..._key_file.c-Fix-build-error-for-musl.patch | 31 ------------ ...tport-fix-missing-stddef.h-inclusion.patch | 27 +++++++++++ .../0004-Use-nogroup-for-nobody-group.patch | 6 +-- .../0005-find-OE-provided-Kerberos.patch | 4 +- ...e-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch | 47 +++++++++++++++++++ ...{nfs-utils_2.9.1.bb => nfs-utils_2.9.2.bb} | 5 +- 6 files changed, 82 insertions(+), 38 deletions(-) delete mode 100644 meta/recipes-connectivity/nfs-utils/nfs-utils/0001-fh_key_file.c-Fix-build-error-for-musl.patch create mode 100644 meta/recipes-connectivity/nfs-utils/nfs-utils/0001-getport-fix-missing-stddef.h-inclusion.patch create mode 100644 meta/recipes-connectivity/nfs-utils/nfs-utils/0006-configure.ac-gate-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch rename meta/recipes-connectivity/nfs-utils/{nfs-utils_2.9.1.bb => nfs-utils_2.9.2.bb} (96%) diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-fh_key_file.c-Fix-build-error-for-musl.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-fh_key_file.c-Fix-build-error-for-musl.patch deleted file mode 100644 index d6db1fe0c0..0000000000 --- a/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-fh_key_file.c-Fix-build-error-for-musl.patch +++ /dev/null @@ -1,31 +0,0 @@ -From 98048fd9262b3e4e024248ebd07d5ff66175e4ec Mon Sep 17 00:00:00 2001 -From: Robert Yang <[email protected]> -Date: Thu, 7 May 2026 03:32:57 -0700 -Subject: [PATCH] fh_key_file.c: Fix build error with musl - -Fixed: -error: implicit declaration of function 'strerror' - -Upstream-Status: Backport [https://lore.kernel.org/linux-nfs/[email protected]/] - -Signed-off-by: Robert Yang <[email protected]> ---- - support/nfs/fh_key_file.c | 2 ++ - 1 file changed, 2 insertions(+) - -diff --git a/support/nfs/fh_key_file.c b/support/nfs/fh_key_file.c -index 5f5eafc..89555ce 100644 ---- a/support/nfs/fh_key_file.c -+++ b/support/nfs/fh_key_file.c -@@ -30,6 +30,8 @@ - - #include "nfslib.h" - -+#include <string.h> -+ - #define HASH_BLOCKSIZE 256 - int hash_fh_key_file(const char *fh_key_file, uuid_t uuid) - { --- -2.49.0 - diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-getport-fix-missing-stddef.h-inclusion.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-getport-fix-missing-stddef.h-inclusion.patch new file mode 100644 index 0000000000..1683e9692b --- /dev/null +++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-getport-fix-missing-stddef.h-inclusion.patch @@ -0,0 +1,27 @@ +From: Jaipaul Cheernam <[email protected]> +Date: Thu, 6 Aug 2026 10:55:00 +0000 +Subject: [PATCH] getport: fix missing stddef.h inclusion + +getport.c uses offsetof() but does not include <stddef.h>. On glibc +this works because offsetof is pulled in transitively, but on musl it +is not available without the explicit include, causing: + + getport.c:459:41: error: implicit declaration of function 'offsetof' + +Upstream-Status: Submitted [https://lore.kernel.org/linux-nfs/[email protected]/] +Signed-off-by: Jaipaul Cheernam <[email protected]> +--- + support/nfs/getport.c | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/support/nfs/getport.c b/support/nfs/getport.c +--- a/support/nfs/getport.c ++++ b/support/nfs/getport.c +@@ -27,6 +27,7 @@ + #include <config.h> + #endif + ++#include <stddef.h> + #include <sys/types.h> + #include <sys/time.h> + #include <unistd.h> diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0004-Use-nogroup-for-nobody-group.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0004-Use-nogroup-for-nobody-group.patch index bbf44d5977..7e63cb6282 100644 --- a/meta/recipes-connectivity/nfs-utils/nfs-utils/0004-Use-nogroup-for-nobody-group.patch +++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/0004-Use-nogroup-for-nobody-group.patch @@ -1,4 +1,4 @@ -From 001913c5eb0aad933a93ee966252905cd46d776b Mon Sep 17 00:00:00 2001 +From 5f4739475f3c01145174734ed8a3b31b3da99b77 Mon Sep 17 00:00:00 2001 From: Daniel McGregor <[email protected]> Date: Tue, 6 Jun 2023 16:07:53 -0600 Subject: [PATCH] Use "nogroup" for nobody group @@ -11,7 +11,7 @@ Signed-off-by: Daniel McGregor <[email protected]> 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/support/nfsidmap/idmapd.conf b/support/nfsidmap/idmapd.conf -index 2a2f79a1..e6f3724f 100644 +index 2a2f79a..e6f3724 100644 --- a/support/nfsidmap/idmapd.conf +++ b/support/nfsidmap/idmapd.conf @@ -41,7 +41,7 @@ @@ -24,7 +24,7 @@ index 2a2f79a1..e6f3724f 100644 [Translation] diff --git a/utils/idmapd/idmapd.c b/utils/idmapd/idmapd.c -index cd9a965f..3be805e9 100644 +index 5231f56..e1aa8a5 100644 --- a/utils/idmapd/idmapd.c +++ b/utils/idmapd/idmapd.c @@ -89,7 +89,7 @@ diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0005-find-OE-provided-Kerberos.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0005-find-OE-provided-Kerberos.patch index 3241e8e859..bb152c2754 100644 --- a/meta/recipes-connectivity/nfs-utils/nfs-utils/0005-find-OE-provided-Kerberos.patch +++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/0005-find-OE-provided-Kerberos.patch @@ -1,4 +1,4 @@ -From a2af266f013722a64c5d04e0fe097cd711393a53 Mon Sep 17 00:00:00 2001 +From a1759d9079a436096be5ce44622a3a5a85ec9faa Mon Sep 17 00:00:00 2001 From: Daniel McGregor <[email protected]> Date: Wed, 8 Nov 2023 16:24:20 -0600 Subject: [PATCH] find OE provided Kerberos @@ -10,7 +10,7 @@ Signed-off-by: Daniel McGregor <[email protected]> 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/aclocal/kerberos5.m4 b/aclocal/kerberos5.m4 -index f96f0fd4..ad85fdf2 100644 +index f96f0fd..ad85fdf 100644 --- a/aclocal/kerberos5.m4 +++ b/aclocal/kerberos5.m4 @@ -22,8 +22,8 @@ AC_DEFUN([AC_KERBEROS_V5],[ diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0006-configure.ac-gate-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0006-configure.ac-gate-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch new file mode 100644 index 0000000000..d15ea1ac5d --- /dev/null +++ b/meta/recipes-connectivity/nfs-utils/nfs-utils/0006-configure.ac-gate-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch @@ -0,0 +1,47 @@ +From: Jaipaul Cheernam <[email protected]> +Date: Wed, 5 Aug 2026 06:55:00 +0000 +Subject: [PATCH] configure.ac: gate HAVE_NFSD_NETLINK on --enable-nfsdctl + +HAVE_NFSD_NETLINK is currently defined unconditionally, but the +implementation of nfsd_nl_cmd_str() in support/nfs/nfsdnl.c is only +compiled into libnfs when CONFIG_NFSDCTL is true (--enable-nfsdctl). + +This causes a link failure when building with --disable-nfsdctl: + + ld: exportfs-exportfs.o: in function `unexportfs_parsed': + exportfs.c:491: undefined reference to `nfsd_nl_cmd_str' + +The callers (exportfs.c) guard their usage with #ifdef HAVE_NFSD_NETLINK, +and nfsdnl.h provides a static inline stub returning -ENOSYS when the +macro is not defined. So the correct fix is to only define +HAVE_NFSD_NETLINK when --enable-nfsdctl is in effect, keeping netlink +support as an opt-in feature consistent with the CONFIG_NFSDCTL guard +on nfsdnl.c. + +Upstream-Status: Submitted [https://lore.kernel.org/linux-nfs/[email protected]/T/#u] +Signed-off-by: Jaipaul Cheernam <[email protected]> +--- + configure.ac | 4 ++-- + 1 file changed, 2 insertions(+), 2 deletions(-) + +diff --git a/configure.ac b/configure.ac +--- a/configure.ac ++++ b/configure.ac +@@ -256,8 +256,6 @@ + PKG_CHECK_MODULES(LIBNLGENL3, libnl-genl-3.0 >= 3.1) + + AC_CHECK_HEADERS(linux/nfsd_netlink.h) +-AC_DEFINE([HAVE_NFSD_NETLINK], 1, +- [Define to 1 if nfsd generic netlink support is available]) + + # ensure the system netlink headers have the latest features + AC_COMPILE_IFELSE([AC_LANG_PROGRAM([[#include <linux/nfsd_netlink.h>]], +@@ -279,6 +277,8 @@ + enable_nfsdctl="yes") + AM_CONDITIONAL(CONFIG_NFSDCTL, [test "$enable_nfsdctl" = "yes" ]) + if test "$enable_nfsdctl" = yes; then ++ AC_DEFINE([HAVE_NFSD_NETLINK], 1, ++ [Define to 1 if nfsd generic netlink support is available]) + PKG_CHECK_MODULES(LIBREADLINE, readline) + fi + diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.1.bb b/meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.2.bb similarity index 96% rename from meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.1.bb rename to meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.2.bb index 06e4fcb6e0..e60011ff9f 100644 --- a/meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.1.bb +++ b/meta/recipes-connectivity/nfs-utils/nfs-utils_2.9.2.bb @@ -23,10 +23,11 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/nfs-utils/${PV}/nfs-utils-${PV}.tar.x file://nfscommon \ file://0004-Use-nogroup-for-nobody-group.patch \ file://0005-find-OE-provided-Kerberos.patch \ - file://0001-fh_key_file.c-Fix-build-error-for-musl.patch \ + file://0006-configure.ac-gate-HAVE_NFSD_NETLINK-on-enable-nfsdct.patch \ + file://0001-getport-fix-missing-stddef.h-inclusion.patch \ " -SRC_URI[sha256sum] = "302846343bf509f8f884c23bdbd0fe853b7f7cbb6572060a9082279d13b21a2c" +SRC_URI[sha256sum] = "e1dd8a9c95af15492065942cc3b52b1339ffd586baa2280ed86c9d3dc4097e8c" # Only kernel-module-nfsd is required here (but can be built-in) - the nfsd module will # pull in the remainder of the dependencies.
-=-=-=-=-=-=-=-=-=-=-=- Links: You receive all messages sent to this group. View/Reply Online (#242933): https://lists.openembedded.org/g/openembedded-core/message/242933 Mute This Topic: https://lists.openembedded.org/mt/120624852/21656 Group Owner: [email protected] Unsubscribe: https://lists.openembedded.org/g/openembedded-core/unsub [[email protected]] -=-=-=-=-=-=-=-=-=-=-=-
