From 8a04c4d84c8a1a1297ec0c5cec5522112981e0c0 Mon Sep 17 00:00:00 2001 From: Waldemar Brodkorb Date: Wed, 23 Oct 2019 13:57:27 +0200 Subject: csky: add statx conditionals Similar to glibc commit https://sourceware.org/git/?p=glibc.git;a=commit;h=6bbfc5c09fc5b5e3d4a0cddbbd4e2e457767dae7 we need to handle Linux kernel change, which removed stat64 family from default syscall set. Signed-off-by: Waldemar Brodkorb Signed-off-by: Waldemar Brodkorb --- libc/sysdeps/linux/csky/Makefile.arch | 2 +- libc/sysdeps/linux/csky/bits/fcntl.h | 6 +++--- libc/sysdeps/linux/csky/bits/uClibc_arch_features.h | 3 +++ 3 files changed, 7 insertions(+), 4 deletions(-) (limited to 'libc/sysdeps/linux/csky') diff --git a/libc/sysdeps/linux/csky/Makefile.arch b/libc/sysdeps/linux/csky/Makefile.arch index 704b36aff..a3157c265 100644 --- a/libc/sysdeps/linux/csky/Makefile.arch +++ b/libc/sysdeps/linux/csky/Makefile.arch @@ -1,6 +1,6 @@ CSRC-y := clone.c __syscall_error.c cacheflush.c SSRC-y := __longjmp.S setjmp.S -SSRC-y += libc-read_tp.S vfork.S csky_clone.S +SSRC-y += libc-read_tp.S csky_clone.S diff --git a/libc/sysdeps/linux/csky/bits/fcntl.h b/libc/sysdeps/linux/csky/bits/fcntl.h index b434badd6..de8a8a0bc 100644 --- a/libc/sysdeps/linux/csky/bits/fcntl.h +++ b/libc/sysdeps/linux/csky/bits/fcntl.h @@ -33,13 +33,13 @@ #define O_ASYNC 020000 #ifdef __USE_XOPEN2K8 -# define O_DIRECTORY 040000 /* Must be a directory. */ -# define O_NOFOLLOW 0100000 /* Do not follow links. */ +# define O_DIRECTORY 00200000 /* must be a directory */ +# define O_NOFOLLOW 00400000 /* don't follow links */ # define O_CLOEXEC 02000000 /* Set close_on_exec. */ #endif #ifdef __USE_GNU -# define O_DIRECT 0200000 /* Direct disk access. */ +# define O_DIRECT 00040000 /* direct disk access hint */ # define O_NOATIME 01000000 /* Do not set atime. */ # define O_PATH 010000000 /* Resolve pathname but do not open file. */ #endif diff --git a/libc/sysdeps/linux/csky/bits/uClibc_arch_features.h b/libc/sysdeps/linux/csky/bits/uClibc_arch_features.h index 1b866cb90..3f5dab80c 100644 --- a/libc/sysdeps/linux/csky/bits/uClibc_arch_features.h +++ b/libc/sysdeps/linux/csky/bits/uClibc_arch_features.h @@ -17,6 +17,9 @@ /* can your target use syscall6() for mmap ? */ #undef __UCLIBC_MMAP_HAS_6_ARGS__ +/* does your target use statx */ +#define __UCLIBC_HAVE_STATX__ + #ifdef __CSKYABIV2__ #undef __UCLIBC_SYSCALL_ALIGN_64BIT__ #else -- cgit v1.2.3