Skip to contentSkip to conversation

configure.ac: Add check for STATMOUNT_MNT_NS_ID

PATCH New Jack Morgan 1 participant 1 message Sep 26, 2025

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 configure.ac: Add check for STATMOUNT_MNT_NS_ID

mnt_ns_id was removed from struct statmount in newer kernels. This check determines whether the headers have this field or not.

---
 configure.ac | 2 ++
 1 file changed, 2 insertions(+)
configure.ac +2 -0
index d4dd13033..0480f46ca 100644
@@ -264,6 +264,8 @@ AC_CHECK_TYPES([struct cachestat],,,[#include <sys/mman.h>])
 # Defined in <linux/mount.h>, but include/lapi/mount.h includes <sys/mount.h> */
 AC_CHECK_TYPES([struct mnt_id_req],,,[#include <sys/mount.h>])
 AC_CHECK_TYPES([struct statmount],,,[#include <sys/mount.h>])
+AC_CHECK_MEMBERS([struct statmount.mnt_ns_id],,,[#include <unistd.h>
+#include <linux/mount.h>])
 
 AC_CHECK_TYPES([struct pidfd_info],,,[#include <sys/pidfd.h>])
 AC_CHECK_TYPES([struct file_attr],,,[#include <linux/fs.h>])
Signature · 6 lines
2.51.0



-- 
Mailing list info: https://lists.linux.it/listinfo/ltp