From 07956672b784af598dc5604db8fafd0702b8fe13 Mon Sep 17 00:00:00 2001 From: Johannes Nixdorf Date: Sat, 9 Aug 2025 19:13:08 +0200 Subject: [PATCH] libfrog: Define STATX__RESERVED if not provided by the system MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit This define is not provided by musl libc. Use the fallback that is already provided if statx and its types (tested on STATX_TYPE) are not defined in the general case. This fixes one cause for failing to compile against musl libc. Signed-off-by: Johannes Nixdorf Reviewed-by: Christoph Hellwig Reviewed-by: Petr Vaněk --- libfrog/statx.h | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/libfrog/statx.h b/libfrog/statx.h index e11e2d8f..9fb15adc 100644 --- a/libfrog/statx.h +++ b/libfrog/statx.h @@ -191,7 +191,6 @@ statx( #define STATX_BLOCKS 0x00000400U /* Want/got stx_blocks */ #define STATX_BASIC_STATS 0x000007ffU /* The stuff in the normal stat struct */ #define STATX_BTIME 0x00000800U /* Want/got stx_btime */ -#define STATX__RESERVED 0x80000000U /* Reserved for future struct statx expansion */ /* * This is deprecated, and shall remain the same value in the future. To avoid @@ -221,6 +220,10 @@ statx( #endif /* STATX_TYPE */ +#ifndef STATX__RESERVED +#define STATX__RESERVED 0x80000000U /* Reserved for future struct statx expansion */ +#endif + #ifndef STATX_MNT_ID #define STATX_MNT_ID 0x00001000U /* Got stx_mnt_id */ #endif -- 2.47.3