]> git.ipfire.org Git - thirdparty/util-linux.git/commitdiff
meson: test for statx::stx_mnt_id in sys/stat.h
authorThomas Weißschuh <thomas@t-8ch.de>
Fri, 10 Apr 2026 16:04:58 +0000 (18:04 +0200)
committerThomas Weißschuh <thomas@t-8ch.de>
Fri, 10 Apr 2026 16:06:49 +0000 (18:06 +0200)
Both the check for the general availability of 'struct statx' and the
code actual code use sys/stat.h and not linux/stat.h.

The test for stx_mnt_id also needs to test in sys/stat.h as otherwise
the detection result is wrong.

Signed-off-by: Thomas Weißschuh <thomas@t-8ch.de>
meson.build

index 582f2756472b23eec70e3d875d1b5885afb74567..3f5a5131a3e08163ce099004314e3362e308ca68 100644 (file)
@@ -111,7 +111,7 @@ conf.set('HAVE_MOUNTFD_API', have_mountfd_api ? 1 : false)
 have_struct_statx = cc.has_type('struct statx', args : '-D_GNU_SOURCE', prefix : '#include <sys/stat.h>')
 conf.set('HAVE_STRUCT_STATX', have_struct_statx ? 1 : false)
 have = cc.has_member('struct statx', 'stx_mnt_id',
-                     prefix : '#include <linux/stat.h>')
+                     prefix : '#include <sys/stat.h>')
 conf.set('HAVE_STRUCT_STATX_STX_MNT_ID', have ? 1 : false)