diff --git a/libc/Android.mk b/libc/Android.mk index 5baf38113..c3ee617e5 100644 --- a/libc/Android.mk +++ b/libc/Android.mk @@ -107,11 +107,9 @@ libc_common_src_files := \ bionic/name_mem.c \ bionic/pathconf.c \ bionic/perror.c \ - bionic/pread.c \ bionic/ptsname.c \ bionic/ptsname_r.c \ bionic/pututline.c \ - bionic/pwrite.c \ bionic/reboot.c \ bionic/recv.c \ bionic/sched_cpualloc.c \ @@ -181,6 +179,8 @@ libc_common_src_files += \ bionic/__get_tls.cpp \ bionic/lseek64.c \ bionic/ndk_cruft.cpp \ + bionic/pread.c \ + bionic/pwrite.c \ bionic/statfs.c \ endif diff --git a/libc/SYSCALLS.TXT b/libc/SYSCALLS.TXT index f31073f88..ce79e9ccc 100644 --- a/libc/SYSCALLS.TXT +++ b/libc/SYSCALLS.TXT @@ -88,8 +88,10 @@ int acct(const char* filepath) all # file descriptors ssize_t read(int, void*, size_t) all ssize_t write(int, const void*, size_t) all -ssize_t pread64(int, void*, size_t, off64_t) all -ssize_t pwrite64(int, void*, size_t, off64_t) all +ssize_t pread64(int, void*, size_t, off64_t) arm,mips,x86 +ssize_t pread64|pread(int, void*, size_t, off_t) aarch64,x86_64 +ssize_t pwrite64(int, void*, size_t, off64_t) arm,mips,x86 +ssize_t pwrite64|pwrite(int, void*, size_t, off_t) aarch64,x86_64 int close(int) all pid_t getpid() all void* mmap(void*, size_t, int, int, int, long) aarch64,x86_64 diff --git a/libc/arch-aarch64/syscalls/pread64.S b/libc/arch-aarch64/syscalls/pread64.S index 82a2fb213..941e55ff6 100644 --- a/libc/arch-aarch64/syscalls/pread64.S +++ b/libc/arch-aarch64/syscalls/pread64.S @@ -21,3 +21,6 @@ ENTRY(pread64) ret END(pread64) + + .globl _C_LABEL(pread) + .equ _C_LABEL(pread), _C_LABEL(pread64) diff --git a/libc/arch-aarch64/syscalls/pwrite64.S b/libc/arch-aarch64/syscalls/pwrite64.S index ab4b502dc..9700aa3f9 100644 --- a/libc/arch-aarch64/syscalls/pwrite64.S +++ b/libc/arch-aarch64/syscalls/pwrite64.S @@ -21,3 +21,6 @@ ENTRY(pwrite64) ret END(pwrite64) + + .globl _C_LABEL(pwrite) + .equ _C_LABEL(pwrite), _C_LABEL(pwrite64) diff --git a/libc/arch-x86_64/syscalls/pread64.S b/libc/arch-x86_64/syscalls/pread64.S index 25378c81d..05dc02142 100644 --- a/libc/arch-x86_64/syscalls/pread64.S +++ b/libc/arch-x86_64/syscalls/pread64.S @@ -17,3 +17,6 @@ ENTRY(pread64) 1: ret END(pread64) + + .globl _C_LABEL(pread) + .equ _C_LABEL(pread), _C_LABEL(pread64) diff --git a/libc/arch-x86_64/syscalls/pwrite64.S b/libc/arch-x86_64/syscalls/pwrite64.S index c3692e978..a1e0ea121 100644 --- a/libc/arch-x86_64/syscalls/pwrite64.S +++ b/libc/arch-x86_64/syscalls/pwrite64.S @@ -17,3 +17,6 @@ ENTRY(pwrite64) 1: ret END(pwrite64) + + .globl _C_LABEL(pwrite) + .equ _C_LABEL(pwrite), _C_LABEL(pwrite64)