diff options
-rw-r--r-- | src/stat.c | 2 | ||||
-rw-r--r-- | src/util.h | 6 |
2 files changed, 7 insertions, 1 deletions
@@ -310,7 +310,7 @@ int bfs_stat(int at_fd, const char *at_path, enum bfs_stat_flags flags, struct b at_flags |= AT_SYMLINK_NOFOLLOW; } -#ifdef AT_NO_AUTOMOUNT +#if defined(AT_NO_AUTOMOUNT) && (!__GNU__ || BFS_GLIBC_PREREQ(2, 35)) at_flags |= AT_NO_AUTOMOUNT; #endif @@ -90,6 +90,12 @@ # define BFS_HAS_UTIL BFS_HAS_INCLUDE(<util.h>, __NetBSD__) #endif +#ifdef __GLIBC_PREREQ +# define BFS_GLIBC_PREREQ(maj, min) __GLIBC_PREREQ(maj, min) +#else +# define BFS_GLIBC_PREREQ(maj, min) false +#endif + #if !defined(FNM_CASEFOLD) && defined(FNM_IGNORECASE) # define FNM_CASEFOLD FNM_IGNORECASE #endif |