diff options
Diffstat (limited to 'poky/meta/recipes-extended/ltp/ltp/0005-getdents-define-getdents-getdents64-only-for-glibc.patch')
-rw-r--r-- | poky/meta/recipes-extended/ltp/ltp/0005-getdents-define-getdents-getdents64-only-for-glibc.patch | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/poky/meta/recipes-extended/ltp/ltp/0005-getdents-define-getdents-getdents64-only-for-glibc.patch b/poky/meta/recipes-extended/ltp/ltp/0005-getdents-define-getdents-getdents64-only-for-glibc.patch new file mode 100644 index 000000000..d1f7b0746 --- /dev/null +++ b/poky/meta/recipes-extended/ltp/ltp/0005-getdents-define-getdents-getdents64-only-for-glibc.patch @@ -0,0 +1,50 @@ +From b996b2480fe3a800ffbdc4a0fdc5e8775c575449 Mon Sep 17 00:00:00 2001 +From: Khem Raj <raj.khem@gmail.com> +Date: Fri, 8 Jan 2016 06:57:04 +0000 +Subject: [PATCH] getdents: define getdents/getdents64 only for glibc + +getdents/getdents64 are implemented in musl and when we define static +functions with same name, it errors out. + +Upstream-Status: Pending + +Signed-off-by: Khem Raj <raj.khem@gmail.com> +--- + testcases/kernel/syscalls/getdents/getdents.h | 6 ++++-- + 1 file changed, 4 insertions(+), 2 deletions(-) + +diff --git a/testcases/kernel/syscalls/getdents/getdents.h b/testcases/kernel/syscalls/getdents/getdents.h +index 702b0bd..860b22e 100644 +--- a/testcases/kernel/syscalls/getdents/getdents.h ++++ b/testcases/kernel/syscalls/getdents/getdents.h +@@ -34,12 +34,13 @@ struct linux_dirent { + char d_name[]; + }; + ++#ifdef __GLIBC__ + static inline int + getdents(unsigned int fd, struct linux_dirent *dirp, unsigned int size) + { + return ltp_syscall(__NR_getdents, fd, dirp, size); + } +- ++#endif + struct linux_dirent64 { + uint64_t d_ino; + int64_t d_off; +@@ -48,10 +49,11 @@ struct linux_dirent64 { + char d_name[]; + }; + ++#ifdef __GLIBC__ + static inline int + getdents64(unsigned int fd, struct linux_dirent64 *dirp64, unsigned int size) + { + return ltp_syscall(__NR_getdents64, fd, dirp64, size); + } +- ++#endif + #endif /* GETDENTS_H */ +-- +2.7.4 + |