grub2: disable 'check-macro-version' build rule in 'po' build
[openwrt/staging/yousong.git] / package / boot / grub2 / patches / 100-musl-compat.patch
1 --- a/grub-core/osdep/unix/hostdisk.c
2 +++ b/grub-core/osdep/unix/hostdisk.c
3 @@ -48,11 +48,10 @@
4 #ifdef __linux__
5 # include <sys/ioctl.h> /* ioctl */
6 # include <sys/mount.h>
7 -# if !defined(__GLIBC__) || \
8 - ((__GLIBC__ < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ < 1)))
9 +# if defined(__UCLIBC__)
10 /* Maybe libc doesn't have large file support. */
11 # include <linux/unistd.h> /* _llseek */
12 -# endif /* (GLIBC < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR < 1)) */
13 +# endif /* __UCLIBC__ */
14 #endif /* __linux__ */
15
16 grub_uint64_t
17 @@ -79,8 +78,7 @@ grub_util_get_fd_size (grub_util_fd_t fd
18 return st.st_size;
19 }
20
21 -#if defined(__linux__) && (!defined(__GLIBC__) || \
22 - ((__GLIBC__ < 2) || ((__GLIBC__ == 2) && (__GLIBC_MINOR__ < 1))))
23 +#if defined(__linux__) && defined(__UCLIBC__)
24 /* Maybe libc doesn't have large file support. */
25 int
26 grub_util_fd_seek (grub_util_fd_t fd, grub_uint64_t off)