am e365f284: am f27cc051: am 806f3bd7: Upgrade to tzdata2013i.
authorElliott Hughes <enh@google.com>
Tue, 4 Mar 2014 18:29:22 +0000 (18:29 +0000)
committerAndroid Git Automerger <android-git-automerger@android.com>
Tue, 4 Mar 2014 18:29:22 +0000 (18:29 +0000)
* commit 'e365f2840f20bb6b7fdd044c9515018b2d4cd309':
  Upgrade to tzdata2013i.

972 files changed:
HACKING.txt [new file with mode: 0644]
libc/Android.mk
libc/SYSCALLS.TXT
libc/arch-arm/arm.mk
libc/arch-arm/bionic/__get_sp.S
libc/arch-arm/bionic/_setjmp.S
libc/arch-arm/bionic/abort_arm.S
libc/arch-arm/bionic/libgcc_compat.c
libc/arch-arm/bionic/memcmp.S
libc/arch-arm/bionic/memcmp16.S
libc/arch-arm/bionic/memcpy.S
libc/arch-arm/bionic/memcpy.a9.S
libc/arch-arm/bionic/setjmp.S
libc/arch-arm/bionic/sigsetjmp.S
libc/arch-arm/bionic/strcmp.S
libc/arch-arm/cortex-a15/bionic/__strcat_chk.S
libc/arch-arm/cortex-a15/bionic/__strcpy_chk.S
libc/arch-arm/cortex-a15/bionic/memcpy.S
libc/arch-arm/cortex-a15/bionic/memset.S
libc/arch-arm/cortex-a15/bionic/strcat.S
libc/arch-arm/cortex-a15/bionic/strcmp.S
libc/arch-arm/cortex-a15/bionic/strcpy.S
libc/arch-arm/cortex-a15/bionic/strlen.S
libc/arch-arm/cortex-a15/cortex-a15.mk
libc/arch-arm/cortex-a9/bionic/__strcat_chk.S
libc/arch-arm/cortex-a9/bionic/__strcpy_chk.S
libc/arch-arm/cortex-a9/bionic/memcpy.S
libc/arch-arm/cortex-a9/bionic/memset.S
libc/arch-arm/cortex-a9/bionic/strcat.S
libc/arch-arm/cortex-a9/bionic/strcmp.S
libc/arch-arm/cortex-a9/bionic/strcpy.S
libc/arch-arm/cortex-a9/bionic/strlen.S
libc/arch-arm/cortex-a9/cortex-a9.mk
libc/arch-arm/generic/bionic/memcpy.S
libc/arch-arm/generic/bionic/memset.S
libc/arch-arm/generic/bionic/strcmp.S
libc/arch-arm/generic/bionic/strcpy.S
libc/arch-arm/generic/generic.mk
libc/arch-arm/include/machine/_types.h [deleted file]
libc/arch-arm/include/machine/asm.h
libc/arch-arm/krait/bionic/__strcat_chk.S
libc/arch-arm/krait/bionic/__strcpy_chk.S
libc/arch-arm/krait/bionic/memcpy.S
libc/arch-arm/krait/bionic/memset.S
libc/arch-arm/krait/bionic/strcmp.S
libc/arch-arm/krait/krait.mk
libc/arch-arm/syscalls.mk [deleted file]
libc/arch-arm/syscalls/fallocate64.S [new file with mode: 0644]
libc/arch-arm/syscalls/fstat64.S [new file with mode: 0644]
libc/arch-arm/syscalls/fstatat64.S [moved from libc/arch-arm/syscalls/fstatat.S with 76% similarity]
libc/arch-arm/syscalls/recvmmsg.S [new file with mode: 0644]
libc/arch-arm/syscalls/sendmmsg.S [moved from libc/arch-arm/syscalls/fstat.S with 78% similarity]
libc/arch-arm64/arm64.mk
libc/arch-arm64/bionic/__get_sp.S
libc/arch-arm64/bionic/__rt_sigreturn.S
libc/arch-arm64/bionic/_setjmp.S
libc/arch-arm64/bionic/setjmp.S
libc/arch-arm64/bionic/sigsetjmp.S
libc/arch-arm64/include/machine/_types.h [deleted file]
libc/arch-arm64/include/machine/asm.h
libc/arch-arm64/syscalls.mk [deleted file]
libc/arch-arm64/syscalls/__brk.S
libc/arch-arm64/syscalls/__epoll_pwait.S
libc/arch-arm64/syscalls/__exit.S
libc/arch-arm64/syscalls/__getcpu.S
libc/arch-arm64/syscalls/__getcwd.S
libc/arch-arm64/syscalls/__getpriority.S
libc/arch-arm64/syscalls/__ioctl.S
libc/arch-arm64/syscalls/__openat.S
libc/arch-arm64/syscalls/__ppoll.S
libc/arch-arm64/syscalls/__pselect6.S
libc/arch-arm64/syscalls/__ptrace.S
libc/arch-arm64/syscalls/__reboot.S
libc/arch-arm64/syscalls/__rt_sigaction.S
libc/arch-arm64/syscalls/__rt_sigpending.S
libc/arch-arm64/syscalls/__rt_sigprocmask.S
libc/arch-arm64/syscalls/__rt_sigsuspend.S
libc/arch-arm64/syscalls/__rt_sigtimedwait.S
libc/arch-arm64/syscalls/__sched_getaffinity.S
libc/arch-arm64/syscalls/__set_tid_address.S
libc/arch-arm64/syscalls/__syslog.S
libc/arch-arm64/syscalls/__timer_create.S
libc/arch-arm64/syscalls/__timer_delete.S
libc/arch-arm64/syscalls/__timer_getoverrun.S
libc/arch-arm64/syscalls/__timer_gettime.S
libc/arch-arm64/syscalls/__timer_settime.S
libc/arch-arm64/syscalls/__waitid.S
libc/arch-arm64/syscalls/fallocate.S [new file with mode: 0644]
libc/arch-arm64/syscalls/fstat64.S [new file with mode: 0644]
libc/arch-arm64/syscalls/fstatat64.S [new file with mode: 0644]
libc/arch-arm64/syscalls/fstatfs64.S [moved from libc/arch-arm64/syscalls/fstatfs.S with 82% similarity]
libc/arch-arm64/syscalls/ftruncate.S
libc/arch-arm64/syscalls/getrlimit.S
libc/arch-arm64/syscalls/lseek.S
libc/arch-arm64/syscalls/mmap.S
libc/arch-arm64/syscalls/pread64.S
libc/arch-arm64/syscalls/prlimit64.S
libc/arch-arm64/syscalls/pwrite64.S
libc/arch-arm64/syscalls/recvmmsg.S [moved from libc/arch-arm64/syscalls/fstat.S with 85% similarity]
libc/arch-arm64/syscalls/sendfile.S
libc/arch-arm64/syscalls/sendmmsg.S [moved from libc/arch-arm64/syscalls/fstatat.S with 85% similarity]
libc/arch-arm64/syscalls/setrlimit.S
libc/arch-arm64/syscalls/statfs64.S [moved from libc/arch-arm64/syscalls/statfs.S with 83% similarity]
libc/arch-arm64/syscalls/truncate.S
libc/arch-mips/bionic/__bionic_clone.S
libc/arch-mips/bionic/__get_sp.S
libc/arch-mips/bionic/_exit_with_stack_teardown.S
libc/arch-mips/bionic/_setjmp.S
libc/arch-mips/bionic/bzero.S
libc/arch-mips/bionic/cacheflush.cpp
libc/arch-mips/bionic/futex_mips.S
libc/arch-mips/bionic/memcmp16.S
libc/arch-mips/bionic/setjmp.S
libc/arch-mips/bionic/sigsetjmp.S
libc/arch-mips/bionic/syscall.S
libc/arch-mips/bionic/vfork.S
libc/arch-mips/include/machine/_types.h [deleted file]
libc/arch-mips/include/machine/asm.h
libc/arch-mips/include/machine/signal.h
libc/arch-mips/mips.mk
libc/arch-mips/string/memcpy.S
libc/arch-mips/string/memset.S
libc/arch-mips/syscalls.mk [deleted file]
libc/arch-mips/syscalls/__brk.S
libc/arch-mips/syscalls/__epoll_pwait.S
libc/arch-mips/syscalls/__exit.S
libc/arch-mips/syscalls/__fcntl64.S
libc/arch-mips/syscalls/__fstatfs64.S
libc/arch-mips/syscalls/__getcpu.S
libc/arch-mips/syscalls/__getcwd.S
libc/arch-mips/syscalls/__getpriority.S
libc/arch-mips/syscalls/__ioctl.S
libc/arch-mips/syscalls/__llseek.S
libc/arch-mips/syscalls/__mmap2.S
libc/arch-mips/syscalls/__openat.S
libc/arch-mips/syscalls/__ppoll.S
libc/arch-mips/syscalls/__pselect6.S
libc/arch-mips/syscalls/__ptrace.S
libc/arch-mips/syscalls/__reboot.S
libc/arch-mips/syscalls/__rt_sigaction.S
libc/arch-mips/syscalls/__rt_sigpending.S
libc/arch-mips/syscalls/__rt_sigprocmask.S
libc/arch-mips/syscalls/__rt_sigsuspend.S
libc/arch-mips/syscalls/__rt_sigtimedwait.S
libc/arch-mips/syscalls/__sched_getaffinity.S
libc/arch-mips/syscalls/__set_thread_area.S
libc/arch-mips/syscalls/__set_tid_address.S
libc/arch-mips/syscalls/__sigaction.S
libc/arch-mips/syscalls/__statfs64.S
libc/arch-mips/syscalls/__syslog.S
libc/arch-mips/syscalls/__timer_create.S
libc/arch-mips/syscalls/__timer_delete.S
libc/arch-mips/syscalls/__timer_getoverrun.S
libc/arch-mips/syscalls/__timer_gettime.S
libc/arch-mips/syscalls/__timer_settime.S
libc/arch-mips/syscalls/__waitid.S
libc/arch-mips/syscalls/_exit.S
libc/arch-mips/syscalls/_flush_cache.S
libc/arch-mips/syscalls/accept.S
libc/arch-mips/syscalls/acct.S
libc/arch-mips/syscalls/bind.S
libc/arch-mips/syscalls/capget.S
libc/arch-mips/syscalls/capset.S
libc/arch-mips/syscalls/chdir.S
libc/arch-mips/syscalls/chroot.S
libc/arch-mips/syscalls/clock_getres.S
libc/arch-mips/syscalls/clock_gettime.S
libc/arch-mips/syscalls/clock_nanosleep.S
libc/arch-mips/syscalls/clock_settime.S
libc/arch-mips/syscalls/close.S
libc/arch-mips/syscalls/connect.S
libc/arch-mips/syscalls/delete_module.S
libc/arch-mips/syscalls/dup.S
libc/arch-mips/syscalls/dup3.S
libc/arch-mips/syscalls/epoll_create1.S
libc/arch-mips/syscalls/epoll_ctl.S
libc/arch-mips/syscalls/eventfd.S
libc/arch-mips/syscalls/execve.S
libc/arch-mips/syscalls/faccessat.S
libc/arch-mips/syscalls/fallocate64.S [new file with mode: 0644]
libc/arch-mips/syscalls/fchdir.S
libc/arch-mips/syscalls/fchmod.S
libc/arch-mips/syscalls/fchmodat.S
libc/arch-mips/syscalls/fchown.S
libc/arch-mips/syscalls/fchownat.S
libc/arch-mips/syscalls/fdatasync.S
libc/arch-mips/syscalls/fgetxattr.S
libc/arch-mips/syscalls/flistxattr.S
libc/arch-mips/syscalls/flock.S
libc/arch-mips/syscalls/fremovexattr.S
libc/arch-mips/syscalls/fsetxattr.S
libc/arch-mips/syscalls/fstat.S [deleted file]
libc/arch-mips/syscalls/fstat64.S [new file with mode: 0644]
libc/arch-mips/syscalls/fstatat.S [deleted file]
libc/arch-mips/syscalls/fstatat64.S [new file with mode: 0644]
libc/arch-mips/syscalls/fsync.S
libc/arch-mips/syscalls/ftruncate.S
libc/arch-mips/syscalls/ftruncate64.S
libc/arch-mips/syscalls/futex.S
libc/arch-mips/syscalls/getdents.S
libc/arch-mips/syscalls/getegid.S
libc/arch-mips/syscalls/geteuid.S
libc/arch-mips/syscalls/getgid.S
libc/arch-mips/syscalls/getgroups.S
libc/arch-mips/syscalls/getitimer.S
libc/arch-mips/syscalls/getpeername.S
libc/arch-mips/syscalls/getpgid.S
libc/arch-mips/syscalls/getpid.S
libc/arch-mips/syscalls/getppid.S
libc/arch-mips/syscalls/getresgid.S
libc/arch-mips/syscalls/getresuid.S
libc/arch-mips/syscalls/getrlimit.S
libc/arch-mips/syscalls/getrusage.S
libc/arch-mips/syscalls/getsid.S
libc/arch-mips/syscalls/getsockname.S
libc/arch-mips/syscalls/getsockopt.S
libc/arch-mips/syscalls/gettid.S
libc/arch-mips/syscalls/gettimeofday.S
libc/arch-mips/syscalls/getuid.S
libc/arch-mips/syscalls/getxattr.S
libc/arch-mips/syscalls/init_module.S
libc/arch-mips/syscalls/inotify_add_watch.S
libc/arch-mips/syscalls/inotify_init1.S
libc/arch-mips/syscalls/inotify_rm_watch.S
libc/arch-mips/syscalls/ioprio_get.S
libc/arch-mips/syscalls/ioprio_set.S
libc/arch-mips/syscalls/kill.S
libc/arch-mips/syscalls/klogctl.S
libc/arch-mips/syscalls/lgetxattr.S
libc/arch-mips/syscalls/linkat.S
libc/arch-mips/syscalls/listen.S
libc/arch-mips/syscalls/listxattr.S
libc/arch-mips/syscalls/llistxattr.S
libc/arch-mips/syscalls/lremovexattr.S
libc/arch-mips/syscalls/lseek.S
libc/arch-mips/syscalls/lsetxattr.S
libc/arch-mips/syscalls/madvise.S
libc/arch-mips/syscalls/mincore.S
libc/arch-mips/syscalls/mkdirat.S
libc/arch-mips/syscalls/mknodat.S
libc/arch-mips/syscalls/mlock.S
libc/arch-mips/syscalls/mlockall.S
libc/arch-mips/syscalls/mount.S
libc/arch-mips/syscalls/mprotect.S
libc/arch-mips/syscalls/mremap.S
libc/arch-mips/syscalls/msync.S
libc/arch-mips/syscalls/munlock.S
libc/arch-mips/syscalls/munlockall.S
libc/arch-mips/syscalls/munmap.S
libc/arch-mips/syscalls/nanosleep.S
libc/arch-mips/syscalls/perf_event_open.S
libc/arch-mips/syscalls/personality.S
libc/arch-mips/syscalls/pipe2.S
libc/arch-mips/syscalls/prctl.S
libc/arch-mips/syscalls/pread64.S
libc/arch-mips/syscalls/prlimit64.S
libc/arch-mips/syscalls/pwrite64.S
libc/arch-mips/syscalls/read.S
libc/arch-mips/syscalls/readahead.S
libc/arch-mips/syscalls/readlinkat.S
libc/arch-mips/syscalls/readv.S
libc/arch-mips/syscalls/recvfrom.S
libc/arch-mips/syscalls/recvmmsg.S [new file with mode: 0644]
libc/arch-mips/syscalls/recvmsg.S
libc/arch-mips/syscalls/removexattr.S
libc/arch-mips/syscalls/renameat.S
libc/arch-mips/syscalls/sched_get_priority_max.S
libc/arch-mips/syscalls/sched_get_priority_min.S
libc/arch-mips/syscalls/sched_getparam.S
libc/arch-mips/syscalls/sched_getscheduler.S
libc/arch-mips/syscalls/sched_rr_get_interval.S
libc/arch-mips/syscalls/sched_setaffinity.S
libc/arch-mips/syscalls/sched_setparam.S
libc/arch-mips/syscalls/sched_setscheduler.S
libc/arch-mips/syscalls/sched_yield.S
libc/arch-mips/syscalls/sendfile.S
libc/arch-mips/syscalls/sendfile64.S
libc/arch-mips/syscalls/sendmmsg.S [new file with mode: 0644]
libc/arch-mips/syscalls/sendmsg.S
libc/arch-mips/syscalls/sendto.S
libc/arch-mips/syscalls/setgid.S
libc/arch-mips/syscalls/setgroups.S
libc/arch-mips/syscalls/setitimer.S
libc/arch-mips/syscalls/setns.S
libc/arch-mips/syscalls/setpgid.S
libc/arch-mips/syscalls/setpriority.S
libc/arch-mips/syscalls/setregid.S
libc/arch-mips/syscalls/setresgid.S
libc/arch-mips/syscalls/setresuid.S
libc/arch-mips/syscalls/setreuid.S
libc/arch-mips/syscalls/setrlimit.S
libc/arch-mips/syscalls/setsid.S
libc/arch-mips/syscalls/setsockopt.S
libc/arch-mips/syscalls/settimeofday.S
libc/arch-mips/syscalls/setuid.S
libc/arch-mips/syscalls/setxattr.S
libc/arch-mips/syscalls/shutdown.S
libc/arch-mips/syscalls/sigaltstack.S
libc/arch-mips/syscalls/signalfd4.S
libc/arch-mips/syscalls/socket.S
libc/arch-mips/syscalls/socketpair.S
libc/arch-mips/syscalls/swapoff.S
libc/arch-mips/syscalls/swapon.S
libc/arch-mips/syscalls/symlinkat.S
libc/arch-mips/syscalls/sync.S
libc/arch-mips/syscalls/sysinfo.S
libc/arch-mips/syscalls/tgkill.S
libc/arch-mips/syscalls/timerfd_create.S
libc/arch-mips/syscalls/timerfd_gettime.S
libc/arch-mips/syscalls/timerfd_settime.S
libc/arch-mips/syscalls/times.S
libc/arch-mips/syscalls/tkill.S
libc/arch-mips/syscalls/truncate.S
libc/arch-mips/syscalls/truncate64.S
libc/arch-mips/syscalls/umask.S
libc/arch-mips/syscalls/umount2.S
libc/arch-mips/syscalls/uname.S
libc/arch-mips/syscalls/unlinkat.S
libc/arch-mips/syscalls/unshare.S
libc/arch-mips/syscalls/utimensat.S
libc/arch-mips/syscalls/wait4.S
libc/arch-mips/syscalls/write.S
libc/arch-mips/syscalls/writev.S
libc/arch-mips64/bionic/__bionic_clone.S [new file with mode: 0644]
libc/arch-mips64/bionic/__get_sp.S [moved from libc/bionic/memcpy.c with 94% similarity]
libc/arch-mips64/bionic/__set_tls.c [moved from libc/bionic/atoll.c with 91% similarity]
libc/arch-mips64/bionic/_exit_with_stack_teardown.S [moved from libc/bionic/ftok.c with 80% similarity]
libc/arch-mips64/bionic/_setjmp.S [new file with mode: 0644]
libc/arch-mips64/bionic/atexit.h [new file with mode: 0644]
libc/arch-mips64/bionic/bzero.S [moved from libc/bionic/atol.c with 88% similarity]
libc/arch-mips64/bionic/crtbegin.c [new file with mode: 0644]
libc/arch-mips64/bionic/crtbegin_so.c [moved from libc/arch-arm64/bionic/cacheflush_arm64.c with 85% similarity]
libc/arch-mips64/bionic/futex_mips.S [new file with mode: 0644]
libc/arch-mips64/bionic/getdents.cpp [new file with mode: 0644]
libc/arch-mips64/bionic/memcmp16.S [moved from libc/bionic/perror.c with 77% similarity]
libc/arch-mips64/bionic/setjmp.S [new file with mode: 0644]
libc/arch-mips64/bionic/sigsetjmp.S [moved from libc/upstream-freebsd/lib/libc/stdio/getchar.c with 63% similarity]
libc/arch-mips64/bionic/syscall.S [new file with mode: 0644]
libc/arch-mips64/bionic/vfork.S [new file with mode: 0644]
libc/arch-mips64/include/machine/asm.h [new file with mode: 0644]
libc/arch-mips64/include/machine/elf_machdep.h [new file with mode: 0644]
libc/arch-mips64/include/machine/endian.h [new file with mode: 0644]
libc/arch-mips64/include/machine/exec.h [new file with mode: 0644]
libc/arch-mips64/include/machine/ieee.h [new file with mode: 0644]
libc/arch-mips64/include/machine/limits.h [new file with mode: 0644]
libc/arch-mips64/include/machine/regdef.h [new file with mode: 0644]
libc/arch-mips64/include/machine/regnum.h [new file with mode: 0644]
libc/arch-mips64/include/machine/setjmp.h [new file with mode: 0644]
libc/arch-mips64/include/machine/signal.h [moved from libc/upstream-freebsd/lib/libc/stdio/feof.c with 75% similarity]
libc/arch-mips64/mips64.mk [new file with mode: 0644]
libc/arch-mips64/string/memcpy.S [new file with mode: 0644]
libc/arch-mips64/string/memset.S [new file with mode: 0644]
libc/arch-mips64/string/mips-string-ops.h [new file with mode: 0644]
libc/arch-mips64/string/mips_strlen.c [new file with mode: 0644]
libc/arch-mips64/syscalls/__brk.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__epoll_pwait.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__exit.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__getcpu.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__getcwd.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__getdents.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__getdents64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__getpriority.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__ioctl.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__openat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__ppoll.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__pselect6.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__ptrace.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__reboot.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__rt_sigaction.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__rt_sigpending.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__rt_sigprocmask.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__rt_sigsuspend.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__rt_sigtimedwait.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__sched_getaffinity.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__set_thread_area.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__set_tid_address.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__syslog.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__timer_create.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__timer_delete.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__timer_getoverrun.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__timer_gettime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__timer_settime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/__waitid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/_exit.S [new file with mode: 0644]
libc/arch-mips64/syscalls/_flush_cache.S [new file with mode: 0644]
libc/arch-mips64/syscalls/accept.S [new file with mode: 0644]
libc/arch-mips64/syscalls/acct.S [new file with mode: 0644]
libc/arch-mips64/syscalls/bind.S [new file with mode: 0644]
libc/arch-mips64/syscalls/capget.S [new file with mode: 0644]
libc/arch-mips64/syscalls/capset.S [new file with mode: 0644]
libc/arch-mips64/syscalls/chdir.S [new file with mode: 0644]
libc/arch-mips64/syscalls/chroot.S [new file with mode: 0644]
libc/arch-mips64/syscalls/clock_getres.S [new file with mode: 0644]
libc/arch-mips64/syscalls/clock_gettime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/clock_nanosleep.S [new file with mode: 0644]
libc/arch-mips64/syscalls/clock_settime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/close.S [new file with mode: 0644]
libc/arch-mips64/syscalls/connect.S [new file with mode: 0644]
libc/arch-mips64/syscalls/delete_module.S [new file with mode: 0644]
libc/arch-mips64/syscalls/dup.S [new file with mode: 0644]
libc/arch-mips64/syscalls/dup3.S [new file with mode: 0644]
libc/arch-mips64/syscalls/epoll_create1.S [new file with mode: 0644]
libc/arch-mips64/syscalls/epoll_ctl.S [new file with mode: 0644]
libc/arch-mips64/syscalls/eventfd.S [new file with mode: 0644]
libc/arch-mips64/syscalls/execve.S [new file with mode: 0644]
libc/arch-mips64/syscalls/faccessat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fallocate.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fchdir.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fchmod.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fchmodat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fchown.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fchownat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fcntl.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fdatasync.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fgetxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/flistxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/flock.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fremovexattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fsetxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fstat64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fstatat64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fstatfs64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/fsync.S [new file with mode: 0644]
libc/arch-mips64/syscalls/ftruncate.S [new file with mode: 0644]
libc/arch-mips64/syscalls/futex.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getegid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/geteuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getgroups.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getitimer.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getpeername.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getpgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getpid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getppid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getresgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getresuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getrlimit.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getrusage.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getsid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getsockname.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getsockopt.S [new file with mode: 0644]
libc/arch-mips64/syscalls/gettid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/gettimeofday.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/getxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/init_module.S [new file with mode: 0644]
libc/arch-mips64/syscalls/inotify_add_watch.S [new file with mode: 0644]
libc/arch-mips64/syscalls/inotify_init1.S [new file with mode: 0644]
libc/arch-mips64/syscalls/inotify_rm_watch.S [new file with mode: 0644]
libc/arch-mips64/syscalls/ioprio_get.S [new file with mode: 0644]
libc/arch-mips64/syscalls/ioprio_set.S [new file with mode: 0644]
libc/arch-mips64/syscalls/kill.S [new file with mode: 0644]
libc/arch-mips64/syscalls/klogctl.S [new file with mode: 0644]
libc/arch-mips64/syscalls/lgetxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/linkat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/listen.S [new file with mode: 0644]
libc/arch-mips64/syscalls/listxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/llistxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/lremovexattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/lseek.S [new file with mode: 0644]
libc/arch-mips64/syscalls/lsetxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/madvise.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mincore.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mkdirat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mknodat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mlock.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mlockall.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mmap.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mount.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mprotect.S [new file with mode: 0644]
libc/arch-mips64/syscalls/mremap.S [new file with mode: 0644]
libc/arch-mips64/syscalls/msync.S [new file with mode: 0644]
libc/arch-mips64/syscalls/munlock.S [new file with mode: 0644]
libc/arch-mips64/syscalls/munlockall.S [new file with mode: 0644]
libc/arch-mips64/syscalls/munmap.S [new file with mode: 0644]
libc/arch-mips64/syscalls/nanosleep.S [new file with mode: 0644]
libc/arch-mips64/syscalls/perf_event_open.S [new file with mode: 0644]
libc/arch-mips64/syscalls/personality.S [new file with mode: 0644]
libc/arch-mips64/syscalls/pipe2.S [new file with mode: 0644]
libc/arch-mips64/syscalls/prctl.S [new file with mode: 0644]
libc/arch-mips64/syscalls/pread64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/prlimit64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/pwrite64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/read.S [new file with mode: 0644]
libc/arch-mips64/syscalls/readahead.S [new file with mode: 0644]
libc/arch-mips64/syscalls/readlinkat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/readv.S [new file with mode: 0644]
libc/arch-mips64/syscalls/recvfrom.S [new file with mode: 0644]
libc/arch-mips64/syscalls/recvmmsg.S [new file with mode: 0644]
libc/arch-mips64/syscalls/recvmsg.S [new file with mode: 0644]
libc/arch-mips64/syscalls/removexattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/renameat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_get_priority_max.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_get_priority_min.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_getparam.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_getscheduler.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_rr_get_interval.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_setaffinity.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_setparam.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_setscheduler.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sched_yield.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sendfile.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sendmmsg.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sendmsg.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sendto.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setgroups.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setitimer.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setns.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setpgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setpriority.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setregid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setresgid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setresuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setreuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setrlimit.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setsid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setsockopt.S [new file with mode: 0644]
libc/arch-mips64/syscalls/settimeofday.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setuid.S [new file with mode: 0644]
libc/arch-mips64/syscalls/setxattr.S [new file with mode: 0644]
libc/arch-mips64/syscalls/shutdown.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sigaltstack.S [new file with mode: 0644]
libc/arch-mips64/syscalls/signalfd4.S [new file with mode: 0644]
libc/arch-mips64/syscalls/socket.S [new file with mode: 0644]
libc/arch-mips64/syscalls/socketpair.S [new file with mode: 0644]
libc/arch-mips64/syscalls/statfs64.S [new file with mode: 0644]
libc/arch-mips64/syscalls/swapoff.S [new file with mode: 0644]
libc/arch-mips64/syscalls/swapon.S [new file with mode: 0644]
libc/arch-mips64/syscalls/symlinkat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sync.S [new file with mode: 0644]
libc/arch-mips64/syscalls/sysinfo.S [new file with mode: 0644]
libc/arch-mips64/syscalls/tgkill.S [new file with mode: 0644]
libc/arch-mips64/syscalls/timerfd_create.S [new file with mode: 0644]
libc/arch-mips64/syscalls/timerfd_gettime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/timerfd_settime.S [new file with mode: 0644]
libc/arch-mips64/syscalls/times.S [new file with mode: 0644]
libc/arch-mips64/syscalls/tkill.S [new file with mode: 0644]
libc/arch-mips64/syscalls/truncate.S [new file with mode: 0644]
libc/arch-mips64/syscalls/umask.S [new file with mode: 0644]
libc/arch-mips64/syscalls/umount2.S [new file with mode: 0644]
libc/arch-mips64/syscalls/uname.S [new file with mode: 0644]
libc/arch-mips64/syscalls/unlinkat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/unshare.S [new file with mode: 0644]
libc/arch-mips64/syscalls/utimensat.S [new file with mode: 0644]
libc/arch-mips64/syscalls/wait4.S [new file with mode: 0644]
libc/arch-mips64/syscalls/write.S [new file with mode: 0644]
libc/arch-mips64/syscalls/writev.S [new file with mode: 0644]
libc/arch-x86/bionic/__bionic_clone.S
libc/arch-x86/bionic/__get_sp.S
libc/arch-x86/bionic/_setjmp.S
libc/arch-x86/bionic/setjmp.S
libc/arch-x86/bionic/sigsetjmp.S
libc/arch-x86/include/machine/_types.h [deleted file]
libc/arch-x86/include/machine/asm.h
libc/arch-x86/string/bcopy.S
libc/arch-x86/string/memcmp.S
libc/arch-x86/string/strcat.S
libc/arch-x86/string/strcmp.S
libc/arch-x86/string/strncmp.S
libc/arch-x86/string/swab.S
libc/arch-x86/syscalls.mk [deleted file]
libc/arch-x86/syscalls/fallocate64.S [new file with mode: 0644]
libc/arch-x86/syscalls/fstat64.S [moved from libc/arch-x86/syscalls/fstat.S with 87% similarity]
libc/arch-x86/syscalls/fstatat64.S [moved from libc/arch-x86/syscalls/fstatat.S with 89% similarity]
libc/arch-x86/syscalls/recvmmsg.S [new file with mode: 0644]
libc/arch-x86/syscalls/sendmmsg.S [new file with mode: 0644]
libc/arch-x86/x86.mk
libc/arch-x86_64/bionic/__bionic_clone.S
libc/arch-x86_64/bionic/__get_sp.S
libc/arch-x86_64/bionic/__rt_sigreturn.S
libc/arch-x86_64/bionic/_setjmp.S
libc/arch-x86_64/bionic/setjmp.S
libc/arch-x86_64/bionic/sigsetjmp.S
libc/arch-x86_64/include/machine/_types.h [deleted file]
libc/arch-x86_64/include/machine/asm.h
libc/arch-x86_64/syscalls.mk [deleted file]
libc/arch-x86_64/syscalls/__arch_prctl.S
libc/arch-x86_64/syscalls/__brk.S
libc/arch-x86_64/syscalls/__epoll_pwait.S
libc/arch-x86_64/syscalls/__exit.S
libc/arch-x86_64/syscalls/__getcpu.S
libc/arch-x86_64/syscalls/__getcwd.S
libc/arch-x86_64/syscalls/__getpriority.S
libc/arch-x86_64/syscalls/__ioctl.S
libc/arch-x86_64/syscalls/__openat.S
libc/arch-x86_64/syscalls/__ppoll.S
libc/arch-x86_64/syscalls/__pselect6.S
libc/arch-x86_64/syscalls/__ptrace.S
libc/arch-x86_64/syscalls/__reboot.S
libc/arch-x86_64/syscalls/__rt_sigaction.S
libc/arch-x86_64/syscalls/__rt_sigpending.S
libc/arch-x86_64/syscalls/__rt_sigprocmask.S
libc/arch-x86_64/syscalls/__rt_sigsuspend.S
libc/arch-x86_64/syscalls/__rt_sigtimedwait.S
libc/arch-x86_64/syscalls/__sched_getaffinity.S
libc/arch-x86_64/syscalls/__set_tid_address.S
libc/arch-x86_64/syscalls/__syslog.S
libc/arch-x86_64/syscalls/__timer_create.S
libc/arch-x86_64/syscalls/__timer_delete.S
libc/arch-x86_64/syscalls/__timer_getoverrun.S
libc/arch-x86_64/syscalls/__timer_gettime.S
libc/arch-x86_64/syscalls/__timer_settime.S
libc/arch-x86_64/syscalls/__waitid.S
libc/arch-x86_64/syscalls/fallocate.S [new file with mode: 0644]
libc/arch-x86_64/syscalls/fstat64.S [moved from libc/arch-x86_64/syscalls/fstat.S with 79% similarity]
libc/arch-x86_64/syscalls/fstatat64.S [new file with mode: 0644]
libc/arch-x86_64/syscalls/fstatfs64.S [moved from libc/arch-x86_64/syscalls/fstatfs.S with 77% similarity]
libc/arch-x86_64/syscalls/ftruncate.S
libc/arch-x86_64/syscalls/getrlimit.S
libc/arch-x86_64/syscalls/lseek.S
libc/arch-x86_64/syscalls/mmap.S
libc/arch-x86_64/syscalls/pread64.S
libc/arch-x86_64/syscalls/prlimit64.S
libc/arch-x86_64/syscalls/pwrite64.S
libc/arch-x86_64/syscalls/recvmmsg.S [moved from libc/arch-x86_64/syscalls/fstatat.S with 80% similarity]
libc/arch-x86_64/syscalls/sendfile.S
libc/arch-x86_64/syscalls/sendmmsg.S [new file with mode: 0644]
libc/arch-x86_64/syscalls/setrlimit.S
libc/arch-x86_64/syscalls/statfs64.S [moved from libc/arch-x86_64/syscalls/statfs.S with 78% similarity]
libc/arch-x86_64/syscalls/truncate.S
libc/arch-x86_64/x86_64.mk
libc/bionic/__bionic_name_mem.cpp [moved from libc/bionic/name_mem.c with 68% similarity]
libc/bionic/__memcmp16.cpp [moved from libc/string/memcmp16.c with 86% similarity]
libc/bionic/__set_errno.cpp
libc/bionic/__strrchr_chk.cpp
libc/bionic/debug_stacktrace.cpp
libc/bionic/dirent.cpp
libc/bionic/dl_iterate_phdr_static.c [deleted file]
libc/bionic/dl_iterate_phdr_static.cpp [new file with mode: 0644]
libc/bionic/flockfile.c [deleted file]
libc/bionic/flockfile.cpp [moved from libc/arch-mips/bionic/memmove.c with 67% similarity]
libc/bionic/fts.c
libc/bionic/getauxval.cpp
libc/bionic/index.cpp [moved from libc/string/index.c with 88% similarity]
libc/bionic/legacy_32_bit_support.cpp
libc/bionic/lfs64_support.cpp [new file with mode: 0644]
libc/bionic/libc_init_static.cpp
libc/bionic/libc_logging.cpp
libc/bionic/lstat.cpp
libc/bionic/memcpy.cpp [moved from libc/bionic/strndup.c with 83% similarity]
libc/bionic/mmap.cpp
libc/bionic/ndk_cruft.cpp
libc/bionic/open.cpp
libc/bionic/posix_fallocate.cpp [new file with mode: 0644]
libc/bionic/pthread_cond.cpp
libc/bionic/reboot.cpp [moved from libc/bionic/reboot.c with 90% similarity]
libc/bionic/scandir.cpp
libc/bionic/sigaction.cpp
libc/bionic/stat.cpp
libc/bionic/statvfs.cpp
libc/bionic/strchr.cpp
libc/bionic/strerror_r.cpp
libc/bionic/strrchr.cpp [moved from libc/string/strrchr.c with 90% similarity]
libc/bionic/stubs.cpp
libc/bionic/sys_siglist.c [moved from libc/bionic/siglist.c with 91% similarity]
libc/bionic/sys_signame.c [moved from libc/bionic/signame.c with 91% similarity]
libc/bionic/sysconf.cpp
libc/bionic/system_properties.cpp [moved from libc/bionic/system_properties.c with 58% similarity]
libc/crt.mk [new file with mode: 0644]
libc/dns/gethnamaddr.c [moved from libc/netbsd/gethnamaddr.c with 99% similarity]
libc/dns/include/nsswitch.h [moved from libc/private/nsswitch.h with 100% similarity]
libc/dns/include/resolv_cache.h [moved from libc/private/resolv_cache.h with 100% similarity]
libc/dns/include/resolv_iface.h [moved from libc/private/resolv_iface.h with 100% similarity]
libc/dns/include/resolv_private.h [moved from libc/private/resolv_private.h with 100% similarity]
libc/dns/include/resolv_static.h [moved from libc/private/resolv_static.h with 100% similarity]
libc/dns/inet/nsap_addr.c [moved from libc/netbsd/inet/nsap_addr.c with 99% similarity]
libc/dns/nameser/ns_name.c [moved from libc/netbsd/nameser/ns_name.c with 99% similarity]
libc/dns/nameser/ns_netint.c [moved from libc/netbsd/nameser/ns_netint.c with 98% similarity]
libc/dns/nameser/ns_parse.c [moved from libc/netbsd/nameser/ns_parse.c with 99% similarity]
libc/dns/nameser/ns_print.c [moved from libc/netbsd/nameser/ns_print.c with 99% similarity]
libc/dns/nameser/ns_samedomain.c [moved from libc/netbsd/nameser/ns_samedomain.c with 99% similarity]
libc/dns/nameser/ns_ttl.c [moved from libc/netbsd/nameser/ns_ttl.c with 99% similarity]
libc/dns/net/base64.c [moved from libc/netbsd/net/base64.c with 99% similarity]
libc/dns/net/getaddrinfo.c [moved from libc/netbsd/net/getaddrinfo.c with 99% similarity]
libc/dns/net/getnameinfo.c [moved from libc/netbsd/net/getnameinfo.c with 99% similarity]
libc/dns/net/getservbyname.c [moved from libc/netbsd/net/getservbyname.c with 100% similarity]
libc/dns/net/getservbyport.c [moved from libc/netbsd/net/getservbyport.c with 100% similarity]
libc/dns/net/getservent.c [moved from libc/netbsd/net/getservent.c with 100% similarity]
libc/dns/net/nsdispatch.c [moved from libc/netbsd/net/nsdispatch.c with 100% similarity]
libc/dns/net/reentrant.h [moved from libc/netbsd/net/reentrant.h with 100% similarity]
libc/dns/net/servent.h [moved from libc/netbsd/net/servent.h with 100% similarity]
libc/dns/net/services.h [moved from libc/netbsd/net/services.h with 100% similarity]
libc/dns/resolv/__dn_comp.c [moved from libc/netbsd/resolv/__dn_comp.c with 100% similarity]
libc/dns/resolv/__res_close.c [moved from libc/netbsd/resolv/__res_close.c with 100% similarity]
libc/dns/resolv/__res_send.c [moved from libc/netbsd/resolv/__res_send.c with 100% similarity]
libc/dns/resolv/herror.c [moved from libc/netbsd/resolv/herror.c with 99% similarity]
libc/dns/resolv/res_cache.c [moved from libc/netbsd/resolv/res_cache.c with 99% similarity]
libc/dns/resolv/res_comp.c [moved from libc/netbsd/resolv/res_comp.c with 99% similarity]
libc/dns/resolv/res_data.c [moved from libc/netbsd/resolv/res_data.c with 99% similarity]
libc/dns/resolv/res_debug.c [moved from libc/netbsd/resolv/res_debug.c with 99% similarity]
libc/dns/resolv/res_debug.h [moved from libc/netbsd/resolv/res_debug.h with 100% similarity]
libc/dns/resolv/res_init.c [moved from libc/netbsd/resolv/res_init.c with 99% similarity]
libc/dns/resolv/res_mkquery.c [moved from libc/netbsd/resolv/res_mkquery.c with 99% similarity]
libc/dns/resolv/res_private.h [moved from libc/netbsd/resolv/res_private.h with 100% similarity]
libc/dns/resolv/res_query.c [moved from libc/netbsd/resolv/res_query.c with 99% similarity]
libc/dns/resolv/res_send.c [moved from libc/netbsd/resolv/res_send.c with 99% similarity]
libc/dns/resolv/res_state.c [moved from libc/netbsd/resolv/res_state.c with 99% similarity]
libc/include/arpa/nameser.h
libc/include/arpa/nameser_compat.h [moved from libc/private/arpa_nameser_compat.h with 100% similarity]
libc/include/dirent.h
libc/include/elf.h
libc/include/err.h
libc/include/fcntl.h
libc/include/ftw.h
libc/include/limits.h
libc/include/link.h
libc/include/pthread.h
libc/include/search.h
libc/include/signal.h
libc/include/stdint.h
libc/include/stdlib.h
libc/include/string.h
libc/include/sys/_sigdefs.h
libc/include/sys/_system_properties.h
libc/include/sys/_types.h [deleted file]
libc/include/sys/cdefs.h
libc/include/sys/endian.h
libc/include/sys/exec_elf.h [deleted file]
libc/include/sys/klog.h
libc/include/sys/mman.h
libc/include/sys/socket.h
libc/include/sys/stat.h
libc/include/sys/statvfs.h
libc/include/sys/types.h
libc/include/sys/ucontext.h [new file with mode: 0644]
libc/include/sys/un.h
libc/include/sys/user.h
libc/include/sys/vfs.h
libc/include/ucontext.h [moved from libc/bionic/atoi.c with 89% similarity]
libc/include/unistd.h
libc/include/wchar.h
libc/kernel/tools/cpp.py
libc/kernel/tools/defaults.py
libc/kernel/uapi/asm-arm/asm/signal.h
libc/kernel/uapi/asm-generic/signal.h
libc/kernel/uapi/asm-mips/asm/signal.h
libc/kernel/uapi/asm-x86/asm/signal.h
libc/kernel/uapi/asm-x86/asm/stat.h
libc/kernel/uapi/linux/binder.h
libc/netbsd/resolv/res_compat.c [deleted file]
libc/netbsd/resolv/res_random.c [deleted file]
libc/private/KernelArgumentBlock.h
libc/private/arpa_nameser.h [deleted file]
libc/private/bionic_asm.h
libc/private/bionic_auxv.h
libc/private/bionic_name_mem.h
libc/private/libc_logging.h
libc/stdio/fileext.h
libc/tools/bionic_utils.py
libc/tools/genlibgcc_compat.py [new file with mode: 0755]
libc/tools/gensyscalls.py
libc/tzcode/localtime.c
libc/tzcode/private.h
libc/tzcode/tzfile.h
libc/upstream-freebsd/freebsd-compat.h
libc/upstream-freebsd/lib/libc/stdio/clrerr.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/ferror.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/fgetpos.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/fileno.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/fwalk.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/getc.c [deleted file]
libc/upstream-freebsd/lib/libc/stdio/putchar.c [deleted file]
libc/upstream-freebsd/lib/libc/string/wcslcpy.c [deleted file]
libc/upstream-netbsd/lib/libc/gen/ftw.c [moved from libc/upstream-netbsd/libc/gen/ftw.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/nftw.c [moved from libc/upstream-netbsd/libc/gen/nftw.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/nice.c [moved from libc/upstream-netbsd/libc/gen/nice.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/popen.c [moved from libc/upstream-netbsd/libc/gen/popen.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/psignal.c [moved from libc/upstream-netbsd/libc/gen/psignal.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/setjmperr.c [moved from libc/upstream-netbsd/libc/gen/setjmperr.c with 100% similarity]
libc/upstream-netbsd/lib/libc/gen/utime.c [moved from libc/upstream-netbsd/libc/gen/utime.c with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/assertions.h [moved from libc/upstream-netbsd/libc/include/isc/assertions.h with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/dst.h [moved from libc/upstream-netbsd/libc/include/isc/dst.h with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/eventlib.h [moved from libc/upstream-netbsd/libc/include/isc/eventlib.h with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/heap.h [moved from libc/upstream-netbsd/libc/include/isc/heap.h with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/list.h [moved from libc/upstream-netbsd/libc/include/isc/list.h with 100% similarity]
libc/upstream-netbsd/lib/libc/include/isc/memcluster.h [moved from libc/upstream-netbsd/libc/include/isc/memcluster.h with 100% similarity]
libc/upstream-netbsd/lib/libc/inet/inet_ntoa.c [moved from libc/upstream-netbsd/libc/inet/inet_ntoa.c with 100% similarity]
libc/upstream-netbsd/lib/libc/inet/inet_ntop.c [moved from libc/upstream-netbsd/libc/inet/inet_ntop.c with 100% similarity]
libc/upstream-netbsd/lib/libc/inet/inet_pton.c [moved from libc/upstream-netbsd/libc/inet/inet_pton.c with 100% similarity]
libc/upstream-netbsd/lib/libc/isc/ev_streams.c [moved from libc/upstream-netbsd/libc/isc/ev_streams.c with 100% similarity]
libc/upstream-netbsd/lib/libc/isc/ev_timers.c [moved from libc/upstream-netbsd/libc/isc/ev_timers.c with 100% similarity]
libc/upstream-netbsd/lib/libc/isc/eventlib_p.h [moved from libc/upstream-netbsd/libc/isc/eventlib_p.h with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/cclass.h [moved from libc/upstream-netbsd/libc/regex/cclass.h with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/cname.h [moved from libc/upstream-netbsd/libc/regex/cname.h with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/engine.c [moved from libc/upstream-netbsd/libc/regex/engine.c with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/regcomp.c [moved from libc/upstream-netbsd/libc/regex/regcomp.c with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/regerror.c [moved from libc/upstream-netbsd/libc/regex/regerror.c with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/regex2.h [moved from libc/upstream-netbsd/libc/regex/regex2.h with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/regexec.c [moved from libc/upstream-netbsd/libc/regex/regexec.c with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/regfree.c [moved from libc/upstream-netbsd/libc/regex/regfree.c with 100% similarity]
libc/upstream-netbsd/lib/libc/regex/utils.h [moved from libc/upstream-netbsd/libc/regex/utils.h with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/_rand48.c [moved from libc/upstream-netbsd/libc/stdlib/_rand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/bsearch.c [moved from libc/upstream-netbsd/libc/stdlib/bsearch.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/div.c [moved from libc/upstream-netbsd/libc/stdlib/div.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/drand48.c [moved from libc/upstream-netbsd/libc/stdlib/drand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/erand48.c [moved from libc/upstream-netbsd/libc/stdlib/erand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/exit.c [moved from libc/upstream-netbsd/libc/stdlib/exit.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/jrand48.c [moved from libc/upstream-netbsd/libc/stdlib/jrand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/ldiv.c [moved from libc/upstream-netbsd/libc/stdlib/ldiv.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/lldiv.c [moved from libc/upstream-netbsd/libc/stdlib/lldiv.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/lrand48.c [moved from libc/upstream-netbsd/libc/stdlib/lrand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/mrand48.c [moved from libc/upstream-netbsd/libc/stdlib/mrand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/nrand48.c [moved from libc/upstream-netbsd/libc/stdlib/nrand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/seed48.c [moved from libc/upstream-netbsd/libc/stdlib/seed48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/srand48.c [moved from libc/upstream-netbsd/libc/stdlib/srand48.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/tdelete.c [moved from libc/upstream-netbsd/libc/stdlib/tdelete.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/tfind.c [moved from libc/upstream-netbsd/libc/stdlib/tfind.c with 100% similarity]
libc/upstream-netbsd/lib/libc/stdlib/tsearch.c [moved from libc/upstream-netbsd/libc/stdlib/tsearch.c with 100% similarity]
libc/upstream-netbsd/lib/libc/string/memccpy.c [moved from libc/upstream-netbsd/libc/string/memccpy.c with 100% similarity]
libc/upstream-netbsd/lib/libc/string/strcasestr.c [moved from libc/upstream-netbsd/libc/string/strcasestr.c with 100% similarity]
libc/upstream-netbsd/lib/libc/string/strcoll.c [moved from libc/upstream-netbsd/libc/string/strcoll.c with 100% similarity]
libc/upstream-netbsd/lib/libc/string/strxfrm.c [moved from libc/upstream-netbsd/libc/string/strxfrm.c with 100% similarity]
libc/upstream-netbsd/lib/libc/thread-stub/__isthreaded.c [moved from libc/upstream-netbsd/libc/thread-stub/__isthreaded.c with 100% similarity]
libc/upstream-netbsd/lib/libc/unistd/killpg.c [moved from libc/upstream-netbsd/libc/unistd/killpg.c with 100% similarity]
libc/upstream-netbsd/libc/compat-43/creat.c [deleted file]
libc/upstream-netbsd/port_before.h
libc/upstream-openbsd/lib/libc/gen/alarm.c [moved from libc/unistd/alarm.c with 78% similarity]
libc/upstream-openbsd/lib/libc/gen/charclass.h [moved from libc/unistd/charclass.h with 100% similarity]
libc/upstream-openbsd/lib/libc/gen/exec.c [moved from libc/unistd/exec.c with 90% similarity]
libc/upstream-openbsd/lib/libc/gen/fnmatch.c [moved from libc/unistd/fnmatch.c with 100% similarity]
libc/upstream-openbsd/lib/libc/gen/ftok.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/gen/getprogname.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/gen/setprogname.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/gen/tolower_.c [moved from libc/stdlib/tolower_.c with 100% similarity]
libc/upstream-openbsd/lib/libc/gen/toupper_.c [moved from libc/stdlib/toupper_.c with 100% similarity]
libc/upstream-openbsd/lib/libc/locale/wcsxfrm.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/clrerr.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/fdopen.c [moved from libc/upstream-freebsd/lib/libc/stdio/fdopen.c with 77% similarity]
libc/upstream-openbsd/lib/libc/stdio/feof.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/ferror.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/fflush.c [moved from libc/stdio/fflush.c with 97% similarity]
libc/upstream-openbsd/lib/libc/stdio/fgetc.c [moved from libc/stdio/fgetc.c with 96% similarity]
libc/upstream-openbsd/lib/libc/stdio/fgetln.c [moved from libc/upstream-freebsd/lib/libc/stdio/fgetln.c with 86% similarity]
libc/upstream-openbsd/lib/libc/stdio/fgetpos.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/fgets.c [moved from libc/upstream-freebsd/lib/libc/stdio/fgets.c with 86% similarity]
libc/upstream-openbsd/lib/libc/stdio/fileno.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/fpurge.c [moved from libc/upstream-freebsd/lib/libc/stdio/fpurge.c with 80% similarity]
libc/upstream-openbsd/lib/libc/stdio/fputc.c [moved from libc/stdio/fputc.c with 96% similarity]
libc/upstream-openbsd/lib/libc/stdio/fputs.c [moved from libc/upstream-freebsd/lib/libc/stdio/fputs.c with 83% similarity]
libc/upstream-openbsd/lib/libc/stdio/fscanf.c [moved from libc/stdio/fscanf.c with 95% similarity]
libc/upstream-openbsd/lib/libc/stdio/fseek.c [moved from libc/stdio/fseek.c with 93% similarity]
libc/upstream-openbsd/lib/libc/stdio/fsetpos.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/ftell.c [moved from libc/stdio/ftell.c with 88% similarity]
libc/upstream-openbsd/lib/libc/stdio/funopen.c [moved from libc/upstream-freebsd/lib/libc/stdio/funopen.c with 86% similarity]
libc/upstream-openbsd/lib/libc/stdio/fwalk.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/getc.c [moved from libc/upstream-freebsd/lib/libc/stdio/setbuf.c with 83% similarity]
libc/upstream-openbsd/lib/libc/stdio/getchar.c [moved from libc/upstream-freebsd/lib/libc/stdio/fsetpos.c with 84% similarity]
libc/upstream-openbsd/lib/libc/stdio/getdelim.c [moved from libc/upstream-netbsd/libc/stdio/getdelim.c with 88% similarity]
libc/upstream-openbsd/lib/libc/stdio/getline.c [moved from libc/upstream-netbsd/libc/stdio/getline.c with 90% similarity]
libc/upstream-openbsd/lib/libc/stdio/gets.c [moved from libc/stdio/gets.c with 97% similarity]
libc/upstream-openbsd/lib/libc/stdio/perror.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/printf.c [moved from libc/stdio/printf.c with 95% similarity]
libc/upstream-openbsd/lib/libc/stdio/putc.c [moved from libc/upstream-freebsd/lib/libc/stdio/putc.c with 80% similarity]
libc/upstream-openbsd/lib/libc/stdio/putchar.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/puts.c [moved from libc/upstream-freebsd/lib/libc/stdio/puts.c with 84% similarity]
libc/upstream-openbsd/lib/libc/stdio/refill.c [moved from libc/stdio/refill.c with 96% similarity]
libc/upstream-openbsd/lib/libc/stdio/remove.c [moved from libc/upstream-freebsd/lib/libc/stdio/remove.c with 86% similarity]
libc/upstream-openbsd/lib/libc/stdio/rewind.c [moved from libc/stdio/rewind.c with 100% similarity]
libc/upstream-openbsd/lib/libc/stdio/rget.c [moved from libc/upstream-freebsd/lib/libc/stdio/rget.c with 91% similarity]
libc/upstream-openbsd/lib/libc/stdio/scanf.c [moved from libc/stdio/scanf.c with 95% similarity]
libc/upstream-openbsd/lib/libc/stdio/setbuf.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdio/setbuffer.c [moved from libc/upstream-freebsd/lib/libc/stdio/setbuffer.c with 88% similarity]
libc/upstream-openbsd/lib/libc/stdio/stdio.c [moved from libc/stdio/stdio.c with 99% similarity]
libc/upstream-openbsd/lib/libc/stdio/tempnam.c [moved from libc/upstream-freebsd/lib/libc/stdio/tempnam.c with 71% similarity]
libc/upstream-openbsd/lib/libc/stdio/tmpnam.c [moved from libc/upstream-freebsd/lib/libc/stdio/tmpnam.c with 88% similarity]
libc/upstream-openbsd/lib/libc/stdio/ungetc.c [moved from libc/stdio/ungetc.c with 98% similarity]
libc/upstream-openbsd/lib/libc/stdio/vasprintf.c [moved from libc/stdio/vasprintf.c with 91% similarity]
libc/upstream-openbsd/lib/libc/stdio/vprintf.c [moved from libc/stdio/vprintf.c with 100% similarity]
libc/upstream-openbsd/lib/libc/stdio/vscanf.c [moved from libc/stdio/vscanf.c with 100% similarity]
libc/upstream-openbsd/lib/libc/stdio/vsnprintf.c [moved from libc/stdio/vsnprintf.c with 97% similarity]
libc/upstream-openbsd/lib/libc/stdio/vsprintf.c [moved from libc/stdio/vsprintf.c with 96% similarity]
libc/upstream-openbsd/lib/libc/stdio/wbuf.c [moved from libc/stdio/wbuf.c with 98% similarity]
libc/upstream-openbsd/lib/libc/stdlib/atoi.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdlib/atol.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdlib/atoll.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdlib/strtoimax.c [moved from libc/stdlib/strtoimax.c with 82% similarity]
libc/upstream-openbsd/lib/libc/stdlib/strtol.c [moved from libc/stdlib/strtol.c with 93% similarity]
libc/upstream-openbsd/lib/libc/stdlib/strtoll.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/stdlib/strtoul.c [moved from libc/stdlib/strtoul.c with 97% similarity]
libc/upstream-openbsd/lib/libc/stdlib/strtoull.c [moved from libc/stdlib/strtoull.c with 62% similarity]
libc/upstream-openbsd/lib/libc/stdlib/strtoumax.c [moved from libc/stdlib/strtoumax.c with 88% similarity]
libc/upstream-openbsd/lib/libc/stdlib/system.c [moved from libc/unistd/system.c with 92% similarity]
libc/upstream-openbsd/lib/libc/string/bcopy.c [moved from libc/string/bcopy.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strcasecmp.c [moved from libc/string/strcasecmp.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strcat.c [moved from libc/string/strcat.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strcmp.c [moved from libc/string/strcmp.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strcpy.c [moved from libc/string/strcpy.c with 89% similarity]
libc/upstream-openbsd/lib/libc/string/strcspn.c [moved from libc/string/strcspn.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strdup.c [moved from libc/string/strdup.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strlcat.c [moved from libc/string/strlcat.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strlcpy.c [moved from libc/string/strlcpy.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strlen.c [moved from libc/string/strlen.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strncat.c [moved from libc/string/strncat.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strncmp.c [moved from libc/string/strncmp.c with 99% similarity]
libc/upstream-openbsd/lib/libc/string/strncpy.c [moved from libc/string/strncpy.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strndup.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/string/strpbrk.c [moved from libc/string/strpbrk.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strsep.c [moved from libc/string/strsep.c with 98% similarity]
libc/upstream-openbsd/lib/libc/string/strspn.c [moved from libc/string/strspn.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strstr.c [moved from libc/string/strstr.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/strtok.c [moved from libc/string/strtok.c with 100% similarity]
libc/upstream-openbsd/lib/libc/string/wcslcpy.c [new file with mode: 0644]
libc/upstream-openbsd/lib/libc/string/wcswidth.c [new file with mode: 0644]
libc/upstream-openbsd/openbsd-compat.h [moved from libc/include/asm/page.h with 69% similarity]
libc/wchar/wcswidth.c [deleted file]
libc/wchar/wcsxfrm.c [deleted file]
libm/Android.mk
libm/amd64/fenv.c
libm/arm/fenv.c
libm/arm64/fenv.c
libm/freebsd-compat.h
libm/i387/fenv.c
libm/include/amd64/machine/fenv.h [moved from libm/include/amd64/fenv.h with 54% similarity]
libm/include/arm/fenv.h [deleted file]
libm/include/arm/machine/fenv.h [moved from libc/stdlib/strtoll.c with 51% similarity]
libm/include/arm64/machine/fenv.h [moved from libm/include/arm64/fenv.h with 56% similarity]
libm/include/fenv.h [new file with mode: 0644]
libm/include/i387/machine/fenv.h [moved from libm/include/i387/fenv.h with 51% similarity]
libm/include/math.h
libm/include/mips/fenv.h [deleted file]
libm/include/mips/machine/fenv.h [new file with mode: 0644]
libm/mips/_fpmath.h
libm/mips/fenv.c
libstdc++/Android.mk
libstdc++/src/typeinfo.cpp
linker/Android.mk
linker/arch/arm64/begin.S
linker/arch/mips64/begin.S [new file with mode: 0644]
linker/arch/x86_64/begin.S
linker/debugger.cpp
linker/dlfcn.cpp
linker/linker.cpp
linker/linker.h
linker/linker.mk [new file with mode: 0644]
linker/linker_debug.h
linker/linker_executable.mk [new file with mode: 0644]
linker/linker_phdr.cpp
linker/linker_phdr.h
tests/Android.build.mk [new file with mode: 0644]
tests/Android.mk
tests/TemporaryFile.h
tests/dirent_test.cpp
tests/eventfd_test.cpp
tests/fcntl_test.cpp
tests/fortify_test.cpp
tests/ftw_test.cpp [new file with mode: 0644]
tests/getauxval_test.cpp
tests/inttypes_test.cpp
tests/libc_logging_test.cpp
tests/libgen_test.cpp
tests/math_test.cpp
tests/pthread_test.cpp
tests/signal_test.cpp
tests/stack_protector_test.cpp
tests/stack_unwinding_test.cpp
tests/stdint_test.cpp [new file with mode: 0644]
tests/stdio_test.cpp
tests/stdlib_test.cpp
tests/string_test.cpp
tests/stubs_test.cpp
tests/sys_epoll_test.cpp
tests/sys_mman_test.cpp
tests/sys_select_test.cpp
tests/sys_sendfile_test.cpp
tests/sys_socket_test.cpp [new file with mode: 0644]
tests/sys_stat_test.cpp
tests/sys_statvfs_test.cpp [moved from tests/statvfs_test.cpp with 72% similarity]
tests/sys_vfs_test.cpp [new file with mode: 0644]
tests/system_properties_test.cpp
tests/time_test.cpp
tests/unistd_test.cpp

diff --git a/HACKING.txt b/HACKING.txt
new file mode 100644 (file)
index 0000000..9f45903
--- /dev/null
@@ -0,0 +1,159 @@
+Working on bionic
+=================
+
+What are the big pieces of bionic?
+----------------------------------
+
+libc/ --- libc.so, libc.a
+  The C library. Stuff like fopen(3) and kill(2).
+libm/ --- libm.so, libm.a
+  The math library. Traditionally Unix systems kept stuff like sin(3) and
+  cos(3) in a separate library to save space in the days before shared
+  libraries.
+libdl/ --- libdl.so
+  The dynamic linker interface library. This is actually just a bunch of
+  stubs that the dynamic linker replaces with pointers to its own
+  implementation at runtime. This is where stuff like dlopen(3) lives.
+libstdc++/ --- libstdc++.so
+  The C++ ABI support functions. The C++ compiler doesn't know how to
+  implement thread-safe static initialization and the like, so it just calls
+  functions that are supplied by the system. Stuff like __cxa_guard_acquire
+  and __cxa_pure_virtual live here.
+
+linker/ --- /system/bin/linker and /system/bin/linker64
+  The dynamic linker. When you run a dynamically-linked executable, its ELF
+  file has a DT_INTERP entry that says "use the following program to start me".
+  On Android, that's either linker or linker64 (depending on whether it's a
+  32-bit or 64-bit executable). It's responsible for loading the ELF executable
+  into memory and resolving references to symbols (so that when your code tries
+  to jump to fopen(3), say, it lands in the right place).
+
+tests/ --- unit tests
+  The tests/ directory contains unit tests. Roughly arranged as one file per
+  publicly-exported header file.
+benchmarks/ --- benchmarks
+  The benchmarks/ directory contains benchmarks.
+
+
+What's in libc/?
+----------------
+
+libc/
+  arch-arm/
+  arch-arm64/
+  arch-common/
+  arch-mips/
+  arch-mips64/
+  arch-x86/
+  arch-x86_64/
+    # Each architecture has its own subdirectory for stuff that isn't shared
+    # because it's architecture-specific. There will be a .mk file in here that
+    # drags in all the architecture-specific files.
+    bionic/
+      # Every architecture needs a handful of machine-specific assembler files.
+      # They live here.
+    include/
+      machine/
+        # The majority of header files are actually in libc/include/, but many
+        # of them pull in a <machine/something.h> for things like limits,
+        # endianness, and how floating point numbers are represented. Those
+        # headers live here.
+    string/
+      # Most architectures have a handful of optional assembler files
+      # implementing optimized versions of various routines. The <string.h>
+      # functions are particular favorites.
+    syscalls/
+      # The syscalls directories contain script-generated assembler files.
+      # See 'Adding system calls' later.
+
+  include/
+    # The public header files on everyone's include path. These are a mixture of
+    # files written by us and files taken from BSD.
+
+  kernel/
+    # The kernel uapi header files. These are scrubbed copies of the originals
+    # in external/kernel-headers/. These files must not be edited directly. The
+    # generate_uapi_headers.sh script should be used to go from a kernel tree to
+    # external/kernel-headers/ --- this takes care of the architecture-specific
+    # details. The update_all.py script should be used to regenerate bionic's
+    # scrubbed headers from external/kernel-headers/.
+
+  private/
+    # These are private header files meant for use within bionic itself.
+
+  stdio/
+  stdlib/
+  unistd/
+    # These are legacy files of unknown provenance. In the past, bionic was a
+    # mess of random versions of random files from all three of FreeBSD, NetBSD,
+    # and OpenBSD! We've been working to clean that up, but these directories
+    # are basically where all the stuff we haven't got to yet lives.
+  dns/
+    # Contains the DNS resolver (originates from NetBSD code).
+
+  upstream-dlmalloc/
+  upstream-freebsd/
+  upstream-netbsd/
+  upstream-openbsd/
+    # These directories contain unmolested upstream source. Any time we can
+    # just use a BSD implementation of something unmodified, we should.
+    # See files like netbsd-compat.h for various ways in which we manage to
+    # build BSD source in bionic.
+
+  bionic/
+    # This is the biggest mess. The C++ files are files we own, typically
+    # because the Linux kernel interface is sufficiently different that we
+    # can't use any of the BSD implementations. The C files are usually
+    # legacy mess that needs to be sorted out, either by replacing it with
+    # current upstream source in one of the upstream directories or by
+    # switching the file to C++ and cleaning it up.
+
+  tools/
+    # Various tools used to maintain bionic.
+
+  tzcode/
+    # A modified superset of the IANA tzcode. Most of the modifications relate
+    # to Android's use of a single file (with corresponding index) to contain
+    # time zone data.
+  zoneinfo/
+    # Android-format time zone data.
+    # See 'Updating tzdata' later.
+
+
+Adding system calls
+-------------------
+
+Adding a system call usually involves:
+
+  1. Add entries to SYSCALLS.TXT.
+     See SYSCALLS.TXT itself for documentation on the format.
+  2. Run the gensyscalls.py script.
+  3. Add constants (and perhaps types) to the appropriate header file.
+     Note that you should check to see whether the constants are already in
+     kernel uapi header files, in which case you just need to make sure that
+     the appropriate POSIX header file in libc/include/ includes the
+     relevant file or files.
+  4. Add function declarations to the appropriate header file.
+  5. Add at least basic tests. Even a test that deliberately supplies
+     an invalid argument helps check that we're generating the right symbol
+     and have the right declaration in the header file. (And strace(1) can
+     confirm that the correct system call is being made.)
+
+
+Updating kernel header files
+----------------------------
+
+As mentioned above, this is currently a two-step process:
+
+  1. Use generate_uapi_headers.sh to go from a Linux source tree to appropriate
+     contents for external/kernel-headers/.
+  2. Run update_all.py to scrub those headers and import them into bionic.
+
+
+Updating tzdata
+---------------
+
+This is fully automated:
+
+  1. Run update-tzdata.py.
+
index ea46bf9955462ea6e30a34e1f2861ce29cf8c7d5..2046beac3414b77034a9840b1873b3369afd1c2e 100644 (file)
 LOCAL_PATH := $(call my-dir)
 
-include $(LOCAL_PATH)/arch-$(TARGET_ARCH)/syscalls.mk
-
 # Make everything depend on any changes to included makefiles.
-libc_common_additional_dependencies := \
-    $(LOCAL_PATH)/arch-$(TARGET_ARCH)/syscalls.mk \
-    $(LOCAL_PATH)/Android.mk \
+libc_common_additional_dependencies := $(LOCAL_PATH)/Android.mk
+
+# Load config for TARGET_ARCH
+my_2nd_arch_prefix :=
+include $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk
+libc_common_additional_dependencies += \
+    $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk
+
+
+ifdef TARGET_2ND_ARCH
+# Load config for TARGET_2ND_ARCH
+my_2nd_arch_prefix := $(TARGET_2ND_ARCH_VAR_PREFIX)
+include $(LOCAL_PATH)/arch-$(TARGET_2ND_ARCH)/$(TARGET_2ND_ARCH).mk
+my_2nd_arch_prefix :=
+libc_common_additional_dependencies += \
+    $(LOCAL_PATH)/arch-$(TARGET_2ND_ARCH)/$(TARGET_2ND_ARCH).mk
+endif
+
+# crt obj files
+# ========================================================
+# crtbrand.c needs <stdint.h> and a #define for the platform SDK version.
+libc_crt_target_cflags := \
+    -I$(LOCAL_PATH)/include \
+    -DPLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION) \
+
+my_2nd_arch_prefix :=
+include $(LOCAL_PATH)/crt.mk
+ifdef TARGET_2ND_ARCH
+my_2nd_arch_prefix := $(TARGET_2ND_ARCH_VAR_PREFIX)
+include $(LOCAL_PATH)/crt.mk
+my_2nd_arch_prefix :=
+endif
 
 # Define the common source files for all the libc instances
 # =========================================================
 libc_common_src_files := \
-       $(syscall_src) \
-       unistd/alarm.c \
-       unistd/exec.c \
-       unistd/fnmatch.c \
-       unistd/syslog.c \
-       unistd/system.c \
-       unistd/time.c \
-       stdio/asprintf.c \
-       stdio/fflush.c \
-       stdio/fgetc.c \
-       stdio/findfp.c \
-       stdio/fprintf.c \
-       stdio/fputc.c \
-       stdio/fread.c \
-       stdio/freopen.c \
-       stdio/fscanf.c \
-       stdio/fseek.c \
-       stdio/ftell.c \
-       stdio/fvwrite.c \
-       stdio/gets.c \
-       stdio/printf.c \
-       stdio/refill.c \
-       stdio/rewind.c \
-       stdio/scanf.c \
-       stdio/snprintf.c\
-       stdio/sprintf.c \
-       stdio/sscanf.c \
-       stdio/stdio.c \
-       stdio/ungetc.c \
-       stdio/vasprintf.c \
-       stdio/vfprintf.c \
-       stdio/vfscanf.c \
-       stdio/vprintf.c \
-       stdio/vsnprintf.c \
-       stdio/vsprintf.c \
-       stdio/vscanf.c \
-       stdio/vsscanf.c \
-       stdio/wbuf.c \
-       stdlib/atexit.c \
-       stdlib/ctype_.c \
-       stdlib/getenv.c \
-       stdlib/putenv.c \
-       stdlib/setenv.c \
-       stdlib/strtod.c \
-       stdlib/strtoimax.c \
-       stdlib/strtol.c \
-       stdlib/strtoll.c \
-       stdlib/strtoul.c \
-       stdlib/strtoull.c \
-       stdlib/strtoumax.c \
-       stdlib/tolower_.c \
-       stdlib/toupper_.c \
-       string/strcasecmp.c \
-       string/strcspn.c \
-       string/strdup.c \
-       string/strpbrk.c \
-       string/strsep.c \
-       string/strspn.c \
-       string/strstr.c \
-       string/strtok.c \
-       wchar/wcswidth.c \
-       wchar/wcsxfrm.c \
-       bionic/arc4random.c \
-       bionic/atoi.c \
-       bionic/atol.c \
-       bionic/atoll.c \
-       bionic/bindresvport.c \
-       bionic/clearenv.c \
-       bionic/daemon.c \
-       bionic/err.c \
-       bionic/ether_aton.c \
-       bionic/ether_ntoa.c \
-       bionic/fdprintf.c \
-       bionic/flockfile.c \
-       bionic/ftime.c \
-       bionic/ftok.c \
-       bionic/fts.c \
-       bionic/getdtablesize.c \
-       bionic/gethostname.c \
-       bionic/getpgrp.c \
-       bionic/getpriority.c \
-       bionic/getpt.c \
-       bionic/if_indextoname.c \
-       bionic/if_nametoindex.c \
-       bionic/initgroups.c \
-       bionic/ioctl.c \
-       bionic/isatty.c \
-       bionic/issetugid.c \
-       bionic/ldexp.c \
-       bionic/md5.c \
-       bionic/memmem.c \
-       bionic/memswap.c \
-       bionic/name_mem.c \
-       bionic/pathconf.c \
-       bionic/perror.c \
-       bionic/ptsname.c \
-       bionic/ptsname_r.c \
-       bionic/pututline.c \
-       bionic/reboot.c \
-       bionic/recv.c \
-       bionic/sched_cpualloc.c \
-       bionic/sched_cpucount.c \
-       bionic/semaphore.c \
-       bionic/send.c \
-       bionic/setpgrp.c \
-       bionic/sigblock.c \
-       bionic/siginterrupt.c \
-       bionic/siglist.c \
-       bionic/signame.c \
-       bionic/sigsetmask.c \
-       bionic/strndup.c \
-       bionic/strntoimax.c \
-       bionic/strntoumax.c \
-       bionic/strtotimeval.c \
-       bionic/system_properties.c \
-       bionic/system_properties_compat.c \
-       bionic/tcgetpgrp.c \
-       bionic/tcsetpgrp.c \
-       bionic/time64.c \
-       bionic/umount.c \
-       bionic/unlockpt.c \
-       bionic/utmp.c \
-       bionic/wcscoll.c \
-
-
-libc_dns_src_files += \
-    netbsd/gethnamaddr.c \
-    netbsd/inet/nsap_addr.c \
-    netbsd/nameser/ns_name.c \
-    netbsd/nameser/ns_netint.c \
-    netbsd/nameser/ns_parse.c \
-    netbsd/nameser/ns_print.c \
-    netbsd/nameser/ns_samedomain.c \
-    netbsd/nameser/ns_ttl.c \
-    netbsd/net/base64.c \
-    netbsd/net/getaddrinfo.c \
-    netbsd/net/getnameinfo.c \
-    netbsd/net/getservbyname.c \
-    netbsd/net/getservbyport.c \
-    netbsd/net/getservent.c \
-    netbsd/net/nsdispatch.c \
-    netbsd/resolv/__dn_comp.c \
-    netbsd/resolv/herror.c \
-    netbsd/resolv/res_cache.c \
-    netbsd/resolv/__res_close.c \
-    netbsd/resolv/res_comp.c \
-    netbsd/resolv/res_data.c \
-    netbsd/resolv/res_debug.c \
-    netbsd/resolv/res_init.c \
-    netbsd/resolv/res_mkquery.c \
-    netbsd/resolv/res_query.c \
-    netbsd/resolv/__res_send.c \
-    netbsd/resolv/res_send.c \
-    netbsd/resolv/res_state.c \
-
-
-# These are used by the 32-bit targets, but not the 64-bit ones.
-ifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),arm mips x86))
-libc_common_src_files += \
-    bionic/legacy_32_bit_support.cpp \
-    bionic/ndk_cruft.cpp \
-
-endif
+    bionic/arc4random.c \
+    bionic/bindresvport.c \
+    bionic/clearenv.c \
+    bionic/daemon.c \
+    bionic/err.c \
+    bionic/ether_aton.c \
+    bionic/ether_ntoa.c \
+    bionic/fdprintf.c \
+    bionic/ftime.c \
+    bionic/fts.c \
+    bionic/getdtablesize.c \
+    bionic/gethostname.c \
+    bionic/getpgrp.c \
+    bionic/getpriority.c \
+    bionic/getpt.c \
+    bionic/if_indextoname.c \
+    bionic/if_nametoindex.c \
+    bionic/initgroups.c \
+    bionic/ioctl.c \
+    bionic/isatty.c \
+    bionic/issetugid.c \
+    bionic/ldexp.c \
+    bionic/md5.c \
+    bionic/memmem.c \
+    bionic/memswap.c \
+    bionic/pathconf.c \
+    bionic/ptsname.c \
+    bionic/ptsname_r.c \
+    bionic/pututline.c \
+    bionic/recv.c \
+    bionic/sched_cpualloc.c \
+    bionic/sched_cpucount.c \
+    bionic/semaphore.c \
+    bionic/send.c \
+    bionic/setpgrp.c \
+    bionic/sigblock.c \
+    bionic/siginterrupt.c \
+    bionic/sigsetmask.c \
+    bionic/strntoimax.c \
+    bionic/strntoumax.c \
+    bionic/strtotimeval.c \
+    bionic/system_properties_compat.c \
+    bionic/tcgetpgrp.c \
+    bionic/tcsetpgrp.c \
+    bionic/time64.c \
+    bionic/umount.c \
+    bionic/unlockpt.c \
+    bionic/utmp.c \
+    bionic/wcscoll.c \
+    stdio/asprintf.c \
+    stdio/findfp.c \
+    stdio/fprintf.c \
+    stdio/fread.c \
+    stdio/freopen.c \
+    stdio/fvwrite.c \
+    stdio/snprintf.c\
+    stdio/sprintf.c \
+    stdio/sscanf.c \
+    stdio/vfprintf.c \
+    stdio/vfscanf.c \
+    stdio/vsscanf.c \
+    stdlib/atexit.c \
+    stdlib/ctype_.c \
+    stdlib/getenv.c \
+    stdlib/putenv.c \
+    stdlib/setenv.c \
+    stdlib/strtod.c \
+    unistd/syslog.c \
+    unistd/time.c \
 
 # Fortify implementations of libc functions.
 libc_common_src_files += \
     bionic/__FD_chk.cpp \
     bionic/__fgets_chk.cpp \
-    bionic/__memcpy_chk.cpp \
     bionic/__memmove_chk.cpp \
-    bionic/__memset_chk.cpp \
     bionic/__read_chk.cpp \
     bionic/__recvfrom_chk.cpp \
-    bionic/__strcat_chk.cpp \
     bionic/__strchr_chk.cpp \
-    bionic/__strcpy_chk.cpp \
     bionic/__strlcat_chk.cpp \
     bionic/__strlcpy_chk.cpp \
     bionic/__strlen_chk.cpp \
@@ -200,6 +129,7 @@ libc_bionic_src_files := \
     bionic/abort.cpp \
     bionic/access.cpp \
     bionic/assert.cpp \
+    bionic/__bionic_name_mem.cpp \
     bionic/bionic_time_conversions.cpp \
     bionic/brk.cpp \
     bionic/chmod.cpp \
@@ -208,18 +138,20 @@ libc_bionic_src_files := \
     bionic/dirent.cpp \
     bionic/dup2.cpp \
     bionic/epoll_create.cpp \
-    bionic/epoll_wait.cpp \
     bionic/epoll_pwait.cpp \
+    bionic/epoll_wait.cpp \
     bionic/__errno.cpp \
     bionic/eventfd_read.cpp \
     bionic/eventfd_write.cpp \
     bionic/ffs.cpp \
+    bionic/flockfile.cpp \
     bionic/fork.cpp \
     bionic/futimens.cpp \
     bionic/getauxval.cpp \
     bionic/getcwd.cpp \
     bionic/inotify_init.cpp \
     bionic/lchown.cpp \
+    bionic/lfs64_support.cpp \
     bionic/libc_init_common.cpp \
     bionic/libc_logging.cpp \
     bionic/libgen.cpp \
@@ -232,6 +164,7 @@ libc_bionic_src_files := \
     bionic/pause.cpp \
     bionic/pipe.cpp \
     bionic/poll.cpp \
+    bionic/posix_fallocate.cpp \
     bionic/pthread_atfork.cpp \
     bionic/pthread_attr.cpp \
     bionic/pthread_cond.cpp \
@@ -255,6 +188,7 @@ libc_bionic_src_files := \
     bionic/ptrace.cpp \
     bionic/raise.cpp \
     bionic/readlink.cpp \
+    bionic/reboot.cpp \
     bionic/rename.cpp \
     bionic/rmdir.cpp \
     bionic/sbrk.cpp \
@@ -265,7 +199,6 @@ libc_bionic_src_files := \
     bionic/__set_errno.cpp \
     bionic/seteuid.cpp \
     bionic/setlocale.cpp \
-    bionic/signalfd.cpp \
     bionic/sigaction.cpp \
     bionic/sigaddset.cpp \
     bionic/sigdelset.cpp \
@@ -273,6 +206,7 @@ libc_bionic_src_files := \
     bionic/sigfillset.cpp \
     bionic/sigismember.cpp \
     bionic/signal.cpp \
+    bionic/signalfd.cpp \
     bionic/sigpending.cpp \
     bionic/sigprocmask.cpp \
     bionic/sigsuspend.cpp \
@@ -285,8 +219,11 @@ libc_bionic_src_files := \
     bionic/stubs.cpp \
     bionic/symlink.cpp \
     bionic/sysconf.cpp \
-    bionic/thread_atexit.cpp \
+    bionic/system_properties.cpp \
+    bionic/sys_siglist.c \
+    bionic/sys_signame.c \
     bionic/tdestroy.cpp \
+    bionic/thread_atexit.cpp \
     bionic/timer.cpp \
     bionic/tmpfile.cpp \
     bionic/unlink.cpp \
@@ -294,55 +231,17 @@ libc_bionic_src_files := \
     bionic/wait.cpp \
     bionic/wchar.cpp \
 
-# These are shared by all the 32-bit targets, but not the 64-bit ones.
-ifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),arm mips x86))
-libc_bionic_src_files += \
-    bionic/mmap.cpp \
-
-endif
-
-libc_tzcode_src_files := \
-    tzcode/asctime.c \
-    tzcode/difftime.c \
-    tzcode/localtime.c \
-    tzcode/strftime.c \
-    tzcode/strptime.c \
-
 libc_upstream_freebsd_src_files := \
     upstream-freebsd/lib/libc/gen/sleep.c \
     upstream-freebsd/lib/libc/gen/usleep.c \
-    upstream-freebsd/lib/libc/stdio/clrerr.c \
     upstream-freebsd/lib/libc/stdio/fclose.c \
-    upstream-freebsd/lib/libc/stdio/fdopen.c \
-    upstream-freebsd/lib/libc/stdio/feof.c \
-    upstream-freebsd/lib/libc/stdio/ferror.c \
-    upstream-freebsd/lib/libc/stdio/fgetln.c \
-    upstream-freebsd/lib/libc/stdio/fgetpos.c \
-    upstream-freebsd/lib/libc/stdio/fgets.c \
-    upstream-freebsd/lib/libc/stdio/fileno.c \
     upstream-freebsd/lib/libc/stdio/flags.c \
     upstream-freebsd/lib/libc/stdio/fopen.c \
-    upstream-freebsd/lib/libc/stdio/fpurge.c \
-    upstream-freebsd/lib/libc/stdio/fputs.c \
-    upstream-freebsd/lib/libc/stdio/fsetpos.c \
-    upstream-freebsd/lib/libc/stdio/funopen.c \
-    upstream-freebsd/lib/libc/stdio/fwalk.c \
     upstream-freebsd/lib/libc/stdio/fwrite.c \
-    upstream-freebsd/lib/libc/stdio/getc.c \
-    upstream-freebsd/lib/libc/stdio/getchar.c \
     upstream-freebsd/lib/libc/stdio/makebuf.c \
     upstream-freebsd/lib/libc/stdio/mktemp.c \
-    upstream-freebsd/lib/libc/stdio/putc.c \
-    upstream-freebsd/lib/libc/stdio/putchar.c \
-    upstream-freebsd/lib/libc/stdio/puts.c \
     upstream-freebsd/lib/libc/stdio/putw.c \
-    upstream-freebsd/lib/libc/stdio/remove.c \
-    upstream-freebsd/lib/libc/stdio/rget.c \
-    upstream-freebsd/lib/libc/stdio/setbuf.c \
-    upstream-freebsd/lib/libc/stdio/setbuffer.c \
     upstream-freebsd/lib/libc/stdio/setvbuf.c \
-    upstream-freebsd/lib/libc/stdio/tempnam.c \
-    upstream-freebsd/lib/libc/stdio/tmpnam.c \
     upstream-freebsd/lib/libc/stdio/wsetup.c \
     upstream-freebsd/lib/libc/stdlib/abs.c \
     upstream-freebsd/lib/libc/stdlib/getopt_long.c \
@@ -358,7 +257,6 @@ libc_upstream_freebsd_src_files := \
     upstream-freebsd/lib/libc/string/wcscspn.c \
     upstream-freebsd/lib/libc/string/wcsdup.c \
     upstream-freebsd/lib/libc/string/wcslcat.c \
-    upstream-freebsd/lib/libc/string/wcslcpy.c \
     upstream-freebsd/lib/libc/string/wcsncasecmp.c \
     upstream-freebsd/lib/libc/string/wcsncat.c \
     upstream-freebsd/lib/libc/string/wcsncmp.c \
@@ -376,210 +274,126 @@ libc_upstream_freebsd_src_files := \
 libc_upstream_netbsd_src_files := \
     upstream-netbsd/common/lib/libc/hash/sha1/sha1.c \
     upstream-netbsd/common/lib/libc/inet/inet_addr.c \
-    upstream-netbsd/libc/compat-43/creat.c \
-    upstream-netbsd/libc/gen/ftw.c \
-    upstream-netbsd/libc/gen/nftw.c \
-    upstream-netbsd/libc/gen/nice.c \
-    upstream-netbsd/libc/gen/popen.c \
-    upstream-netbsd/libc/gen/psignal.c \
-    upstream-netbsd/libc/gen/setjmperr.c \
-    upstream-netbsd/libc/gen/utime.c \
-    upstream-netbsd/libc/inet/inet_ntoa.c \
-    upstream-netbsd/libc/inet/inet_ntop.c \
-    upstream-netbsd/libc/inet/inet_pton.c \
-    upstream-netbsd/libc/isc/ev_streams.c \
-    upstream-netbsd/libc/isc/ev_timers.c \
-    upstream-netbsd/libc/regex/regcomp.c \
-    upstream-netbsd/libc/regex/regerror.c \
-    upstream-netbsd/libc/regex/regexec.c \
-    upstream-netbsd/libc/regex/regfree.c \
-    upstream-netbsd/libc/stdio/getdelim.c \
-    upstream-netbsd/libc/stdio/getline.c \
-    upstream-netbsd/libc/stdlib/bsearch.c \
-    upstream-netbsd/libc/stdlib/div.c \
-    upstream-netbsd/libc/stdlib/drand48.c \
-    upstream-netbsd/libc/stdlib/erand48.c \
-    upstream-netbsd/libc/stdlib/exit.c \
-    upstream-netbsd/libc/stdlib/jrand48.c \
-    upstream-netbsd/libc/stdlib/ldiv.c \
-    upstream-netbsd/libc/stdlib/lldiv.c \
-    upstream-netbsd/libc/stdlib/lrand48.c \
-    upstream-netbsd/libc/stdlib/mrand48.c \
-    upstream-netbsd/libc/stdlib/nrand48.c \
-    upstream-netbsd/libc/stdlib/_rand48.c \
-    upstream-netbsd/libc/stdlib/seed48.c \
-    upstream-netbsd/libc/stdlib/srand48.c \
-    upstream-netbsd/libc/stdlib/tdelete.c \
-    upstream-netbsd/libc/stdlib/tfind.c \
-    upstream-netbsd/libc/stdlib/tsearch.c \
-    upstream-netbsd/libc/string/memccpy.c \
-    upstream-netbsd/libc/string/strcasestr.c \
-    upstream-netbsd/libc/string/strcoll.c \
-    upstream-netbsd/libc/string/strxfrm.c \
-    upstream-netbsd/libc/thread-stub/__isthreaded.c \
-    upstream-netbsd/libc/unistd/killpg.c \
-
-# Architecture specific source files go here
-# =========================================================
-ifeq ($(TARGET_ARCH),arm)
-libc_common_src_files += \
-    bionic/memchr.c \
-    bionic/memmove.c.arm \
-    bionic/memrchr.c \
-    bionic/strchr.cpp \
-    bionic/strnlen.c \
-    string/bcopy.c \
-    string/index.c \
-    string/strlcat.c \
-    string/strlcpy.c \
-    string/strncat.c \
-    string/strncmp.c \
-    string/strncpy.c \
-    string/strrchr.c \
-    upstream-freebsd/lib/libc/string/wcscat.c \
-    upstream-freebsd/lib/libc/string/wcschr.c \
-    upstream-freebsd/lib/libc/string/wcscmp.c \
-    upstream-freebsd/lib/libc/string/wcscpy.c \
-    upstream-freebsd/lib/libc/string/wcslen.c \
-    upstream-freebsd/lib/libc/string/wcsrchr.c \
-    upstream-freebsd/lib/libc/string/wmemcmp.c \
-
-endif # arm
-
-ifeq ($(TARGET_ARCH), arm64)
-#TODO: Replace C stubs with optimised assembly
-libc_common_src_files += \
-    bionic/memchr.c   \
-    bionic/memcmp.c   \
-    bionic/memcpy.c   \
-    bionic/memmove.c  \
-    bionic/memrchr.c  \
-    bionic/memset.c   \
-    bionic/strchr.cpp \
-    bionic/strnlen.c  \
-    string/bcopy.c    \
-    string/index.c    \
-    string/memcmp16.c \
-    string/strcat.c   \
-    string/strcmp.c   \
-    string/strcpy.c   \
-    string/strlcat.c  \
-    string/strlcpy.c  \
-    string/strlen.c   \
-    string/strncat.c  \
-    string/strncmp.c  \
-    string/strncpy.c  \
-    string/strrchr.c  \
-    upstream-freebsd/lib/libc/string/wcscat.c \
-    upstream-freebsd/lib/libc/string/wcschr.c \
-    upstream-freebsd/lib/libc/string/wcscmp.c \
-    upstream-freebsd/lib/libc/string/wcscpy.c \
-    upstream-freebsd/lib/libc/string/wcslen.c \
-    upstream-freebsd/lib/libc/string/wcsrchr.c \
-    upstream-freebsd/lib/libc/string/wmemcmp.c \
-
-endif # arm64
-
-ifeq ($(TARGET_ARCH),mips)
-libc_common_src_files += \
-    bionic/memchr.c \
-    bionic/memcmp.c \
-    bionic/memrchr.c \
-    bionic/strchr.cpp \
-    bionic/strnlen.c \
-    string/bcopy.c \
-    string/index.c \
-    string/strcat.c \
-    string/strcmp.c \
-    string/strcpy.c \
-    string/strlcat.c \
-    string/strlcpy.c \
-    string/strncat.c \
-    string/strncmp.c \
-    string/strncpy.c \
-    string/strrchr.c \
-    upstream-freebsd/lib/libc/string/wcscat.c \
-    upstream-freebsd/lib/libc/string/wcschr.c \
-    upstream-freebsd/lib/libc/string/wcscmp.c \
-    upstream-freebsd/lib/libc/string/wcscpy.c \
-    upstream-freebsd/lib/libc/string/wcslen.c \
-    upstream-freebsd/lib/libc/string/wcsrchr.c \
-    upstream-freebsd/lib/libc/string/wmemcmp.c \
-
-endif # mips
-
-ifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86_64))
-libc_common_src_files += \
-    bionic/memchr.c \
-    bionic/memcmp.c \
-    bionic/memcpy.c \
-    bionic/memmove.c \
-    bionic/memrchr.c \
-    bionic/memset.c \
-    bionic/strchr.cpp \
-    bionic/strnlen.c \
-    string/bcopy.c \
-    string/index.c \
-    string/strcat.c \
-    string/strcmp.c \
-    string/strcpy.c \
-    string/strlcat.c \
-    string/strlcpy.c \
-    string/strlen.c \
-    string/strncat.c \
-    string/strncmp.c \
-    string/strncpy.c \
-    string/strrchr.c \
-    upstream-freebsd/lib/libc/string/wcscat.c \
-    upstream-freebsd/lib/libc/string/wcschr.c \
-    upstream-freebsd/lib/libc/string/wcscmp.c \
-    upstream-freebsd/lib/libc/string/wcscpy.c \
-    upstream-freebsd/lib/libc/string/wcslen.c \
-    upstream-freebsd/lib/libc/string/wcsrchr.c \
-    upstream-freebsd/lib/libc/string/wmemcmp.c \
-
-endif # x86_64
-
-ifeq ($(TARGET_ARCH),arm)
-  ifeq ($(strip $(TARGET_CPU_VARIANT)),)
-    $(warning TARGET_ARCH is arm, but TARGET_CPU_VARIANT is not defined)
-  endif
-endif
-
-###########################################################
-## Add cpu specific source files.
-##
-## This can be called multiple times, but it will only add
-## the first source file for each unique $(1).
-## $(1): Unique identifier to identify the cpu variant
-##       implementation.
-## $(2): Cpu specific source file.
-###########################################################
-
-define libc-add-cpu-variant-src
-$(if $(filter true,$(_LIBC_ARCH_CPU_VARIANT_HAS_$(1))), \
-       , \
-     $(eval _LIBC_ARCH_CPU_VARIANT_HAS_$(1) := true) \
-     $(eval _LIBC_ARCH_CPU_VARIANT_SRC_FILE.$(1) := $(2)) \
-     $(eval _LIBC_ARCH_CPU_VARIANT_SRC_FILES += $(2)) \
-)
-endef
-
-_LIBC_ARCH_COMMON_SRC_FILES :=
-_LIBC_ARCH_CPU_VARIANT_SRC_FILES :=
-_LIBC_ARCH_STATIC_SRC_FILES :=
-_LIBC_ARCH_DYNAMIC_SRC_FILES :=
-_LIBC_ARCH_ADDITIONAL_DEPENDENCIES :=
-
-libc_common_additional_dependencies += \
-    $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk
-include $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk
-
-libc_bionic_src_files += $(_LIBC_ARCH_COMMON_SRC_FILES)
-libc_bionic_src_files += $(_LIBC_ARCH_CPU_VARIANT_SRC_FILES)
-libc_arch_static_src_files := $(_LIBC_ARCH_STATIC_SRC_FILES)
-libc_arch_dynamic_src_files := $(_LIBC_ARCH_DYNAMIC_SRC_FILES)
-libc_common_additional_dependencies += $(_LIBC_ARCH_ADDITIONAL_DEPENDENCIES)
+    upstream-netbsd/lib/libc/gen/ftw.c \
+    upstream-netbsd/lib/libc/gen/nftw.c \
+    upstream-netbsd/lib/libc/gen/nice.c \
+    upstream-netbsd/lib/libc/gen/popen.c \
+    upstream-netbsd/lib/libc/gen/psignal.c \
+    upstream-netbsd/lib/libc/gen/setjmperr.c \
+    upstream-netbsd/lib/libc/gen/utime.c \
+    upstream-netbsd/lib/libc/inet/inet_ntoa.c \
+    upstream-netbsd/lib/libc/inet/inet_ntop.c \
+    upstream-netbsd/lib/libc/inet/inet_pton.c \
+    upstream-netbsd/lib/libc/isc/ev_streams.c \
+    upstream-netbsd/lib/libc/isc/ev_timers.c \
+    upstream-netbsd/lib/libc/regex/regcomp.c \
+    upstream-netbsd/lib/libc/regex/regerror.c \
+    upstream-netbsd/lib/libc/regex/regexec.c \
+    upstream-netbsd/lib/libc/regex/regfree.c \
+    upstream-netbsd/lib/libc/stdlib/bsearch.c \
+    upstream-netbsd/lib/libc/stdlib/div.c \
+    upstream-netbsd/lib/libc/stdlib/drand48.c \
+    upstream-netbsd/lib/libc/stdlib/erand48.c \
+    upstream-netbsd/lib/libc/stdlib/exit.c \
+    upstream-netbsd/lib/libc/stdlib/jrand48.c \
+    upstream-netbsd/lib/libc/stdlib/ldiv.c \
+    upstream-netbsd/lib/libc/stdlib/lldiv.c \
+    upstream-netbsd/lib/libc/stdlib/lrand48.c \
+    upstream-netbsd/lib/libc/stdlib/mrand48.c \
+    upstream-netbsd/lib/libc/stdlib/nrand48.c \
+    upstream-netbsd/lib/libc/stdlib/_rand48.c \
+    upstream-netbsd/lib/libc/stdlib/seed48.c \
+    upstream-netbsd/lib/libc/stdlib/srand48.c \
+    upstream-netbsd/lib/libc/stdlib/tdelete.c \
+    upstream-netbsd/lib/libc/stdlib/tfind.c \
+    upstream-netbsd/lib/libc/stdlib/tsearch.c \
+    upstream-netbsd/lib/libc/string/memccpy.c \
+    upstream-netbsd/lib/libc/string/strcasestr.c \
+    upstream-netbsd/lib/libc/string/strcoll.c \
+    upstream-netbsd/lib/libc/string/strxfrm.c \
+    upstream-netbsd/lib/libc/thread-stub/__isthreaded.c \
+    upstream-netbsd/lib/libc/unistd/killpg.c \
+
+libc_upstream_openbsd_src_files := \
+    upstream-openbsd/lib/libc/gen/alarm.c \
+    upstream-openbsd/lib/libc/gen/exec.c \
+    upstream-openbsd/lib/libc/gen/fnmatch.c \
+    upstream-openbsd/lib/libc/gen/ftok.c \
+    upstream-openbsd/lib/libc/gen/getprogname.c \
+    upstream-openbsd/lib/libc/gen/setprogname.c \
+    upstream-openbsd/lib/libc/gen/tolower_.c \
+    upstream-openbsd/lib/libc/gen/toupper_.c \
+    upstream-openbsd/lib/libc/string/strstr.c \
+    upstream-openbsd/lib/libc/string/strsep.c \
+    upstream-openbsd/lib/libc/string/wcslcpy.c \
+    upstream-openbsd/lib/libc/string/strcasecmp.c \
+    upstream-openbsd/lib/libc/string/strdup.c \
+    upstream-openbsd/lib/libc/string/strcspn.c \
+    upstream-openbsd/lib/libc/string/strtok.c \
+    upstream-openbsd/lib/libc/string/strpbrk.c \
+    upstream-openbsd/lib/libc/string/strspn.c \
+    upstream-openbsd/lib/libc/string/wcswidth.c \
+    upstream-openbsd/lib/libc/string/strndup.c \
+    upstream-openbsd/lib/libc/stdio/ungetc.c \
+    upstream-openbsd/lib/libc/stdio/vsnprintf.c \
+    upstream-openbsd/lib/libc/stdio/tmpnam.c \
+    upstream-openbsd/lib/libc/stdio/setbuffer.c \
+    upstream-openbsd/lib/libc/stdio/fsetpos.c \
+    upstream-openbsd/lib/libc/stdio/setbuf.c \
+    upstream-openbsd/lib/libc/stdio/vprintf.c \
+    upstream-openbsd/lib/libc/stdio/perror.c \
+    upstream-openbsd/lib/libc/stdio/remove.c \
+    upstream-openbsd/lib/libc/stdio/getc.c \
+    upstream-openbsd/lib/libc/stdio/funopen.c \
+    upstream-openbsd/lib/libc/stdio/ferror.c \
+    upstream-openbsd/lib/libc/stdio/putchar.c \
+    upstream-openbsd/lib/libc/stdio/vscanf.c \
+    upstream-openbsd/lib/libc/stdio/fflush.c \
+    upstream-openbsd/lib/libc/stdio/fpurge.c \
+    upstream-openbsd/lib/libc/stdio/fputs.c \
+    upstream-openbsd/lib/libc/stdio/tempnam.c \
+    upstream-openbsd/lib/libc/stdio/printf.c \
+    upstream-openbsd/lib/libc/stdio/fileno.c \
+    upstream-openbsd/lib/libc/stdio/stdio.c \
+    upstream-openbsd/lib/libc/stdio/getdelim.c \
+    upstream-openbsd/lib/libc/stdio/fseek.c \
+    upstream-openbsd/lib/libc/stdio/fputc.c \
+    upstream-openbsd/lib/libc/stdio/fgetln.c \
+    upstream-openbsd/lib/libc/stdio/fdopen.c \
+    upstream-openbsd/lib/libc/stdio/fgets.c \
+    upstream-openbsd/lib/libc/stdio/fgetc.c \
+    upstream-openbsd/lib/libc/stdio/feof.c \
+    upstream-openbsd/lib/libc/stdio/vasprintf.c \
+    upstream-openbsd/lib/libc/stdio/refill.c \
+    upstream-openbsd/lib/libc/stdio/getline.c \
+    upstream-openbsd/lib/libc/stdio/rewind.c \
+    upstream-openbsd/lib/libc/stdio/wbuf.c \
+    upstream-openbsd/lib/libc/stdio/gets.c \
+    upstream-openbsd/lib/libc/stdio/fgetpos.c \
+    upstream-openbsd/lib/libc/stdio/fscanf.c \
+    upstream-openbsd/lib/libc/stdio/putc.c \
+    upstream-openbsd/lib/libc/stdio/vsprintf.c \
+    upstream-openbsd/lib/libc/stdio/rget.c \
+    upstream-openbsd/lib/libc/stdio/clrerr.c \
+    upstream-openbsd/lib/libc/stdio/scanf.c \
+    upstream-openbsd/lib/libc/stdio/puts.c \
+    upstream-openbsd/lib/libc/stdio/getchar.c \
+    upstream-openbsd/lib/libc/stdio/ftell.c \
+    upstream-openbsd/lib/libc/stdio/fwalk.c \
+    upstream-openbsd/lib/libc/stdlib/strtoul.c \
+    upstream-openbsd/lib/libc/stdlib/strtoull.c \
+    upstream-openbsd/lib/libc/stdlib/atoi.c \
+    upstream-openbsd/lib/libc/stdlib/atoll.c \
+    upstream-openbsd/lib/libc/stdlib/atol.c \
+    upstream-openbsd/lib/libc/stdlib/strtoimax.c \
+    upstream-openbsd/lib/libc/stdlib/strtoumax.c \
+    upstream-openbsd/lib/libc/stdlib/strtoll.c \
+    upstream-openbsd/lib/libc/stdlib/strtol.c \
+    upstream-openbsd/lib/libc/stdlib/system.c \
+    upstream-openbsd/lib/libc/locale/wcsxfrm.c \
+
+libc_arch_static_src_files := \
+    bionic/dl_iterate_phdr_static.cpp \
 
 # Define some common cflags
 # ========================================================
@@ -605,36 +419,6 @@ ifneq ($(BOARD_MALLOC_ALIGNMENT),)
   libc_common_cflags += -DMALLOC_ALIGNMENT=$(BOARD_MALLOC_ALIGNMENT)
 endif
 
-# crtbrand.c needs <stdint.h> and a #define for the platform SDK version.
-libc_crt_target_cflags := \
-    -I$(LOCAL_PATH)/include \
-    -I$(LOCAL_PATH)/arch-$(TARGET_ARCH)/include \
-    -DPLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION) \
-
-ifeq ($(TARGET_ARCH),arm)
-  libc_common_cflags += -DSOFTFLOAT
-  libc_common_cflags += -fstrict-aliasing
-  libc_crt_target_cflags += -mthumb-interwork
-endif # arm
-
-ifeq ($(TARGET_ARCH),mips)
-  ifneq ($(ARCH_MIPS_HAS_FPU),true)
-    libc_common_cflags += -DSOFTFLOAT
-  endif
-  libc_common_cflags += -fstrict-aliasing
-  libc_crt_target_cflags += $(TARGET_GLOBAL_CFLAGS)
-endif # mips
-
-ifeq ($(TARGET_ARCH),x86)
-  libc_crt_target_cflags += -m32
-  libc_crt_target_ldflags := -melf_i386
-endif # x86
-
-ifeq ($(TARGET_ARCH),x86_64)
-  libc_crt_target_cflags += -m64
-  libc_crt_target_ldflags := -melf_x86_64
-endif # x86_64
-
 # Define ANDROID_SMP appropriately.
 ifeq ($(TARGET_CPU_SMP),true)
     libc_common_cflags += -DANDROID_SMP=1
@@ -653,137 +437,23 @@ libc_common_cppflags := \
 # Define some common includes
 # ========================================================
 libc_common_c_includes := \
-               $(LOCAL_PATH)/stdlib  \
-               $(LOCAL_PATH)/string  \
-               $(LOCAL_PATH)/stdio   \
-               external/safe-iop/include
-
-# Define the libc run-time (crt) support object files that must be built,
-# which are needed to build all other objects (shared/static libs and
-# executables)
-# ==========================================================================
-# ARM, Arm64, MIPS, and x86 all need crtbegin_so/crtend_so.
-#
-# For x86, the .init section must point to a function that calls all
-# entries in the .ctors section. (on ARM this is done through the
-# .init_array section instead).
-#
-# For all the platforms, the .fini_array section must point to a function
-# that will call __cxa_finalize(&__dso_handle) in order to ensure that
-# static C++ destructors are properly called on dlclose().
-#
-libc_crt_target_crtbegin_file := $(LOCAL_PATH)/arch-common/bionic/crtbegin.c
-libc_crt_target_crtbegin_so_file := $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c
+    $(LOCAL_PATH)/stdlib  \
+    $(LOCAL_PATH)/string  \
+    $(LOCAL_PATH)/stdio   \
+    external/safe-iop/include
 
-ifeq ($(TARGET_ARCH),arm)
-    libc_crt_target_so_cflags :=
-endif
-ifeq ($(TARGET_ARCH),arm64)
-    libc_crt_target_so_cflags :=
-    libc_crt_target_crtbegin_file := $(LOCAL_PATH)/arch-$(TARGET_ARCH)/bionic/crtbegin.c
-endif
-ifeq ($(TARGET_ARCH),mips)
-    libc_crt_target_so_cflags := -fPIC
-    libc_crt_target_crtbegin_file := $(LOCAL_PATH)/arch-$(TARGET_ARCH)/bionic/crtbegin.c
-endif
-ifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86 x86_64))
-    libc_crt_target_so_cflags := -fPIC
+# ========================================================
+# Add in the arch-specific flags.
+# Must be called with $(eval).
+# $(1): the LOCAL_ variable name
+# $(2): the bionic variable name to pull in
+define patch-up-arch-specific-flags
+$(1)_$(TARGET_ARCH) += $($(2)_$(TARGET_ARCH))
+ifdef TARGET_2ND_ARCH
+$(1)_$(TARGET_2ND_ARCH) += $($(2)_$(TARGET_2ND_ARCH))
 endif
-libc_crt_target_so_cflags += $(libc_crt_target_cflags)
-
-# See the comment in crtbrand.c for the reason why we need to generate
-# crtbrand.s before generating crtbrand.o.
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.s
-$(GEN): $(LOCAL_PATH)/bionic/crtbrand.c
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) -S \
-               -MD -MF $(@:%.s=%.d) -o $@ $<
-       $(hide) sed -i -e '/\.note\.ABI-tag/s/progbits/note/' $@
-       $(call transform-d-to-p-args,$(@:%.s=%.d),$(@:%.s=%.P))
--include $(GEN:%.s=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o
-$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.s
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) -o $@ -c $<
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_so.o
-$(GEN): $(libc_crt_target_crtbegin_so_file)
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) \
-               -MD -MF $(@:%.o=%.d) -o $@ -c $<
-       $(transform-d-to-p)
--include $(GEN:%.o=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_so.o
-$(GEN): $(LOCAL_PATH)/arch-common/bionic/crtend_so.S
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) \
-               -MD -MF $(@:%.o=%.d) -o $@ -c $<
-       $(transform-d-to-p)
--include $(GEN:%.o=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-# The following two are installed to device
-GEN := $(TARGET_OUT_SHARED_LIBRARIES)/crtbegin_so.o
-$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_so.o
-       $(hide) mkdir -p $(dir $@) && cp -f $< $@
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_SHARED_LIBRARIES)/crtend_so.o
-$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_so.o
-       $(hide) mkdir -p $(dir $@) && cp -f $< $@
-ALL_GENERATED_SOURCES += $(GEN)
-
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static1.o
-$(GEN): $(libc_crt_target_crtbegin_file)
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \
-               -MD -MF $(@:%.o=%.d) -o $@ -c $<
-       $(transform-d-to-p)
--include $(GEN:%.o=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static.o
-$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static1.o $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_LD) $(libc_crt_target_ldflags) -r -o $@ $^
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic1.o
-$(GEN): $(libc_crt_target_crtbegin_file)
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \
-               -MD -MF $(@:%.o=%.d) -o $@ -c $<
-       $(transform-d-to-p)
--include $(GEN:%.o=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic.o
-$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic1.o $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_LD) $(libc_crt_target_ldflags) -r -o $@ $^
-ALL_GENERATED_SOURCES += $(GEN)
-
-# We rename crtend.o to crtend_android.o to avoid a
-# name clash between gcc and bionic.
-GEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_android.o
-$(GEN): $(LOCAL_PATH)/arch-common/bionic/crtend.S
-       @mkdir -p $(dir $@)
-       $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \
-               -MD -MF $(@:%.o=%.d) -o $@ -c $<
-       $(transform-d-to-p)
--include $(GEN:%.o=%.P)
-ALL_GENERATED_SOURCES += $(GEN)
-
-
-# To enable malloc leak check for statically linked programs, add
-# "WITH_MALLOC_CHECK_LIBC_A := true" to buildspec.mk
-WITH_MALLOC_CHECK_LIBC_A := $(strip $(WITH_MALLOC_CHECK_LIBC_A))
+endef
+
 
 # ========================================================
 # libbionic_ssp.a - stack protector code
@@ -804,6 +474,7 @@ LOCAL_MODULE := libbionic_ssp
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -813,7 +484,7 @@ include $(BUILD_STATIC_LIBRARY)
 
 include $(CLEAR_VARS)
 
-LOCAL_SRC_FILES := $(libc_tzcode_src_files)
+LOCAL_SRC_FILES := $(call all-c-files-under,tzcode)
 LOCAL_CFLAGS := \
     $(libc_common_cflags) \
     -DSTD_INSPIRED=1 \
@@ -827,6 +498,7 @@ LOCAL_MODULE := libc_tzcode
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -836,13 +508,13 @@ include $(BUILD_STATIC_LIBRARY)
 
 include $(CLEAR_VARS)
 
-LOCAL_SRC_FILES := $(libc_dns_src_files)
+LOCAL_SRC_FILES := $(call all-c-files-under,dns)
 LOCAL_CFLAGS := \
     $(libc_common_cflags) \
     -DINET6 \
+    -I$(LOCAL_PATH)/dns/include \
     -I$(LOCAL_PATH)/private \
-    -I$(LOCAL_PATH)/upstream-netbsd/libc/include # for NetBSD private headers
-
+    -I$(LOCAL_PATH)/upstream-netbsd/lib/libc/include # for NetBSD private headers
 LOCAL_CONLYFLAGS := $(libc_common_conlyflags)
 LOCAL_CPPFLAGS := $(libc_common_cppflags)
 LOCAL_C_INCLUDES := $(libc_common_c_includes)
@@ -850,6 +522,7 @@ LOCAL_MODULE := libc_dns
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -875,6 +548,7 @@ LOCAL_MODULE := libc_freebsd
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -892,7 +566,7 @@ LOCAL_CFLAGS := \
     $(libc_common_cflags) \
     -DPOSIX_MISTAKE \
     -I$(LOCAL_PATH)/upstream-netbsd \
-    -I$(LOCAL_PATH)/upstream-netbsd/libc/include \
+    -I$(LOCAL_PATH)/upstream-netbsd/lib/libc/include \
     -include upstream-netbsd/netbsd-compat.h
 LOCAL_CONLYFLAGS := $(libc_common_conlyflags)
 LOCAL_CPPFLAGS := $(libc_common_cppflags)
@@ -901,6 +575,33 @@ LOCAL_MODULE := libc_netbsd
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+include $(BUILD_STATIC_LIBRARY)
+
+
+# ========================================================
+# libc_openbsd.a - upstream OpenBSD C library code
+# ========================================================
+#
+# These files are built with the openbsd-compat.h header file
+# automatically included.
+
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES := $(libc_upstream_openbsd_src_files)
+LOCAL_CFLAGS := \
+    $(libc_common_cflags) \
+    -I$(LOCAL_PATH)/upstream-openbsd \
+    -I$(LOCAL_PATH)/upstream-openbsd/lib/libc/include \
+    -include upstream-openbsd/openbsd-compat.h
+LOCAL_CONLYFLAGS := $(libc_common_conlyflags)
+LOCAL_CPPFLAGS := $(libc_common_cppflags)
+LOCAL_C_INCLUDES := $(libc_common_c_includes)
+LOCAL_MODULE := libc_openbsd
+LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
+LOCAL_SYSTEM_SHARED_LIBRARIES :=
+
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -921,7 +622,30 @@ LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
 # Set -DPTHREAD_DEBUG_ENABLED=true to enable support for pthread deadlock prediction.
 # Since this code is experimental it is disabled by default.
-LOCAL_CFLAGS += $(libc_common_cflags) -DPTHREAD_DEBUG_ENABLED=false
+LOCAL_CFLAGS += -DPTHREAD_DEBUG_ENABLED=false
+
+ifeq ($(TARGET_USES_LOGD),true)
+LOCAL_CFLAGS += -DTARGET_USES_LOGD
+endif
+
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_bionic_src_files))
+include $(BUILD_STATIC_LIBRARY)
+
+
+# ========================================================
+# libc_syscalls.a
+# ========================================================
+
+include $(CLEAR_VARS)
+
+LOCAL_SRC_FILES_$(TARGET_ARCH) := $(call all-S-files-under,arch-$(TARGET_ARCH)/syscalls)
+ifdef TARGET_2ND_ARCH
+LOCAL_SRC_FILES_$(TARGET_2ND_ARCH) := $(call all-S-files-under,arch-$(TARGET_2ND_ARCH)/syscalls)
+endif
+LOCAL_MODULE := libc_syscalls
+LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
+LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
 include $(BUILD_STATIC_LIBRARY)
 
@@ -945,6 +669,8 @@ LOCAL_WHOLE_STATIC_LIBRARIES := \
     libc_dns \
     libc_freebsd \
     libc_netbsd \
+    libc_openbsd \
+    libc_syscalls \
     libc_tzcode \
 
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
@@ -952,6 +678,9 @@ LOCAL_SYSTEM_SHARED_LIBRARIES :=
 # TODO: split out the asflags.
 LOCAL_ASFLAGS := $(LOCAL_CFLAGS)
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_common_src_files))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_ASFLAGS,LOCAL_CFLAGS))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -968,9 +697,9 @@ include $(BUILD_STATIC_LIBRARY)
 include $(CLEAR_VARS)
 
 LOCAL_SRC_FILES := \
-       $(libc_arch_static_src_files) \
-       $(libc_static_common_src_files) \
-       bionic/libc_init_static.cpp
+    $(libc_arch_static_src_files) \
+    $(libc_static_common_src_files) \
+    bionic/libc_init_static.cpp
 
 LOCAL_C_INCLUDES := $(libc_common_c_includes)
 LOCAL_CFLAGS := $(libc_common_cflags) \
@@ -983,6 +712,8 @@ LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_WHOLE_STATIC_LIBRARIES := libc_common
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_arch_static_src_files))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -992,11 +723,11 @@ include $(BUILD_STATIC_LIBRARY)
 include $(CLEAR_VARS)
 
 LOCAL_SRC_FILES := \
-       $(libc_arch_static_src_files) \
-       $(libc_static_common_src_files) \
-       bionic/dlmalloc.c \
-       bionic/malloc_debug_common.cpp \
-       bionic/libc_init_static.cpp
+    $(libc_arch_static_src_files) \
+    $(libc_static_common_src_files) \
+    bionic/dlmalloc.c \
+    bionic/malloc_debug_common.cpp \
+    bionic/libc_init_static.cpp \
 
 LOCAL_CFLAGS := $(libc_common_cflags) \
                 -DLIBC_STATIC
@@ -1008,6 +739,8 @@ LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_WHOLE_STATIC_LIBRARIES := libc_common
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_arch_static_src_files))
 include $(BUILD_STATIC_LIBRARY)
 
 
@@ -1031,17 +764,6 @@ LOCAL_SRC_FILES := \
     bionic/pthread_debug.cpp \
     bionic/libc_init_dynamic.cpp \
 
-ifeq ($(TARGET_ARCH),arm)
-       LOCAL_NO_CRT := true
-       LOCAL_CFLAGS += -DCRT_LEGACY_WORKAROUND
-
-       LOCAL_SRC_FILES := \
-               arch-common/bionic/crtbegin_so.c \
-               arch-arm/bionic/atexit_legacy.c \
-               $(LOCAL_SRC_FILES) \
-               arch-common/bionic/crtend_so.S
-endif
-
 LOCAL_MODULE:= libc
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
 LOCAL_REQUIRED_MODULES := tzdata
@@ -1058,6 +780,17 @@ LOCAL_SHARED_LIBRARIES := libdl
 LOCAL_WHOLE_STATIC_LIBRARIES := libc_common
 LOCAL_SYSTEM_SHARED_LIBRARIES :=
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_arch_dynamic_src_files))
+$(eval $(call patch-up-arch-specific-flags,LOCAL_SRC_FILES,libc_static_common_src_files))
+# special for arm
+LOCAL_NO_CRT_arm := true
+LOCAL_CFLAGS_arm += -DCRT_LEGACY_WORKAROUND
+LOCAL_SRC_FILES_arm += \
+    arch-common/bionic/crtbegin_so.c \
+    arch-arm/bionic/atexit_legacy.c \
+    arch-common/bionic/crtend_so.S
+
 include $(BUILD_SHARED_LIBRARY)
 
 
@@ -1075,18 +808,18 @@ ifneq ($(TARGET_BUILD_VARIANT),user)
 include $(CLEAR_VARS)
 
 LOCAL_CFLAGS := \
-       $(libc_common_cflags) \
-       -DMALLOC_LEAK_CHECK
+    $(libc_common_cflags) \
+    -DMALLOC_LEAK_CHECK
 LOCAL_CONLYFLAGS := $(libc_common_conlyflags)
 LOCAL_CPPFLAGS := $(libc_common_cppflags)
 
 LOCAL_C_INCLUDES := $(libc_common_c_includes)
 
 LOCAL_SRC_FILES := \
-       bionic/debug_mapinfo.cpp \
-       bionic/debug_stacktrace.cpp \
-       bionic/malloc_debug_leak.cpp \
-       bionic/malloc_debug_check.cpp \
+    bionic/debug_mapinfo.cpp \
+    bionic/debug_stacktrace.cpp \
+    bionic/malloc_debug_leak.cpp \
+    bionic/malloc_debug_check.cpp \
 
 LOCAL_MODULE:= libc_malloc_debug_leak
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
@@ -1099,6 +832,7 @@ LOCAL_ALLOW_UNDEFINED_SYMBOLS := true
 # Don't install on release build
 LOCAL_MODULE_TAGS := eng debug
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_SHARED_LIBRARY)
 
 
@@ -1108,15 +842,15 @@ include $(BUILD_SHARED_LIBRARY)
 include $(CLEAR_VARS)
 
 LOCAL_CFLAGS := \
-       $(libc_common_cflags) \
-       -DMALLOC_QEMU_INSTRUMENT
+    $(libc_common_cflags) \
+    -DMALLOC_QEMU_INSTRUMENT
 LOCAL_CONLYFLAGS := $(libc_common_conlyflags)
 LOCAL_CPPFLAGS := $(libc_common_cppflags)
 
 LOCAL_C_INCLUDES := $(libc_common_c_includes)
 
 LOCAL_SRC_FILES := \
-       bionic/malloc_debug_qemu.cpp
+    bionic/malloc_debug_qemu.cpp
 
 LOCAL_MODULE:= libc_malloc_debug_qemu
 LOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies)
@@ -1128,9 +862,10 @@ LOCAL_SYSTEM_SHARED_LIBRARIES :=
 # Don't install on release build
 LOCAL_MODULE_TAGS := eng debug
 
+$(eval $(call patch-up-arch-specific-flags,LOCAL_CFLAGS,libc_common_cflags))
 include $(BUILD_SHARED_LIBRARY)
 
-endif  #!user
+endif  #!user
 
 
 # ========================================================
index 09516480d53bcbab9a88f3f924833ebe6467876e..192816816a2d937d6dce02000ae46058f4c8fe54 100644 (file)
@@ -6,7 +6,7 @@
 #
 # where:
 #       arch_list ::= "all" | arch+
-#       arch      ::= "arm" | "arm64" | "mips" | "x86" | "x86_64"
+#       arch      ::= "arm" | "arm64" | "mips" | "mips64" | "x86" | "x86_64"
 #
 # Note:
 #      - syscall_name corresponds to the name of the syscall, which may differ from
 int     execve(const char*, char* const*, char* const*)  all
 
 uid_t   getuid:getuid32()         arm,x86
-uid_t   getuid:getuid()           arm64,mips,x86_64
+uid_t   getuid:getuid()           arm64,mips,mips64,x86_64
 gid_t   getgid:getgid32()         arm,x86
-gid_t   getgid:getgid()           arm64,mips,x86_64
+gid_t   getgid:getgid()           arm64,mips,mips64,x86_64
 uid_t   geteuid:geteuid32()       arm,x86
-uid_t   geteuid:geteuid()         arm64,mips,x86_64
+uid_t   geteuid:geteuid()         arm64,mips,mips64,x86_64
 gid_t   getegid:getegid32()       arm,x86
-gid_t   getegid:getegid()         arm64,mips,x86_64
+gid_t   getegid:getegid()         arm64,mips,mips64,x86_64
 uid_t   getresuid:getresuid32(uid_t* ruid, uid_t* euid, uid_t* suid)   arm,x86
-uid_t   getresuid:getresuid(uid_t* ruid, uid_t* euid, uid_t* suid)     arm64,mips,x86_64
+uid_t   getresuid:getresuid(uid_t* ruid, uid_t* euid, uid_t* suid)     arm64,mips,mips64,x86_64
 gid_t   getresgid:getresgid32(gid_t* rgid, gid_t* egid, gid_t* sgid)   arm,x86
-gid_t   getresgid:getresgid(gid_t* rgid, gid_t* egid, gid_t* sgid)     arm64,mips,x86_64
+gid_t   getresgid:getresgid(gid_t* rgid, gid_t* egid, gid_t* sgid)     arm64,mips,mips64,x86_64
 pid_t   gettid()                   all
 ssize_t readahead(int, off64_t, size_t)     all
 int     getgroups:getgroups32(int, gid_t*)    arm,x86
-int     getgroups:getgroups(int, gid_t*)      arm64,mips,x86_64
+int     getgroups:getgroups(int, gid_t*)      arm64,mips,mips64,x86_64
 pid_t   getpgid(pid_t)             all
 pid_t   getppid()                  all
 pid_t   getsid(pid_t)              all
 pid_t   setsid()                   all
 int     setgid:setgid32(gid_t)     arm,x86
-int     setgid:setgid(gid_t)       arm64,mips,x86_64
+int     setgid:setgid(gid_t)       arm64,mips,mips64,x86_64
 int     setuid:setuid32(uid_t)    arm,x86
-int     setuid:setuid(uid_t)      arm64,mips,x86_64
+int     setuid:setuid(uid_t)      arm64,mips,mips64,x86_64
 int     setreuid:setreuid32(uid_t, uid_t)   arm,x86
-int     setreuid:setreuid(uid_t, uid_t)     arm64,mips,x86_64
+int     setreuid:setreuid(uid_t, uid_t)     arm64,mips,mips64,x86_64
 int     setresuid:setresuid32(uid_t, uid_t, uid_t)   arm,x86
-int     setresuid:setresuid(uid_t, uid_t, uid_t)     arm64,mips,x86_64
+int     setresuid:setresuid(uid_t, uid_t, uid_t)     arm64,mips,mips64,x86_64
 int     setresgid:setresgid32(gid_t, gid_t, gid_t)   arm,x86
-int     setresgid:setresgid(gid_t, gid_t, gid_t)     arm64,mips,x86_64
+int     setresgid:setresgid(gid_t, gid_t, gid_t)     arm64,mips,mips64,x86_64
 void*   __brk:brk(void*)           all
 int     kill(pid_t, int)           all
 int     tkill(pid_t tid, int sig)  all
 int     tgkill(pid_t tgid, pid_t tid, int sig)  all
 int     __ptrace:ptrace(int request, int pid, void* addr, void* data)  all
-int     __set_thread_area:set_thread_area(void*  user_desc)  mips,x86
+int     __set_thread_area:set_thread_area(void*  user_desc)  mips,mips64,x86
 
 # <sys/resource.h>
 int getrusage(int, struct rusage*)  all
@@ -71,18 +71,18 @@ int setpriority(int, int, int)   all
 # On 32-bit systems we use prlimit64 to implement the rlimit64 functions.
 int getrlimit:ugetrlimit(int, struct rlimit*)  arm,x86
 int getrlimit(int, struct rlimit*)  mips
-int getrlimit|getrlimit64(int, struct rlimit*)  arm64,x86_64
+int getrlimit|getrlimit64(int, struct rlimit*)  arm64,mips64,x86_64
 int setrlimit(int, const struct rlimit*)  arm,mips,x86
-int setrlimit|setrlimit64(int, const struct rlimit*)  arm64,x86_64
-int prlimit64|prlimit(pid_t, int, struct rlimit64*, const struct rlimit64*)  arm64,x86_64
+int setrlimit|setrlimit64(int, const struct rlimit*)  arm64,mips64,x86_64
+int prlimit64|prlimit(pid_t, int, struct rlimit64*, const struct rlimit64*)  arm64,mips64,x86_64
 int prlimit64(pid_t, int, struct rlimit64*, const struct rlimit64*)  arm,mips,x86
 
 int     setgroups:setgroups32(int, const gid_t*)   arm,x86
-int     setgroups:setgroups(int, const gid_t*)     arm64,mips,x86_64
+int     setgroups:setgroups(int, const gid_t*)     arm64,mips,mips64,x86_64
 int     setpgid(pid_t, pid_t)  all
 pid_t   vfork(void)  arm
 int     setregid:setregid32(gid_t, gid_t)  arm,x86
-int     setregid:setregid(gid_t, gid_t)    arm64,mips,x86_64
+int     setregid:setregid(gid_t, gid_t)    arm64,mips,mips64,x86_64
 int     chroot(const char*)  all
 # IMPORTANT: Even though <sys/prctl.h> declares prctl(int, ...), the syscall stub must take 6 arguments
 #            to match the kernel implementation.
@@ -97,9 +97,9 @@ int     acct(const char*  filepath)  all
 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) arm,mips,x86
-ssize_t     pread64|pread(int, void*, size_t, off_t) arm64,x86_64
+ssize_t     pread64|pread(int, void*, size_t, off_t) arm64,mips64,x86_64
 ssize_t     pwrite64(int, void*, size_t, off64_t) arm,mips,x86
-ssize_t     pwrite64|pwrite(int, void*, size_t, off_t) arm64,x86_64
+ssize_t     pwrite64|pwrite(int, void*, size_t, off_t) arm64,mips64,x86_64
 int         close(int)                      all
 pid_t       getpid()    all
 int         munmap(void*, size_t)  all
@@ -116,31 +116,35 @@ int         __ioctl:ioctl(int, int, void*)  all
 int         readv(int, const struct iovec*, int)   all
 int         writev(int, const struct iovec*, int)  all
 int         __fcntl64:fcntl64(int, int, void*)  arm,mips,x86
-int         fcntl(int, int, void*)  arm64,x86_64
+int         fcntl(int, int, void*)  arm64,mips64,x86_64
 int         flock(int, int)   all
 int         fchmod(int, mode_t)  all
 int         dup(int)  all
 int         pipe2(int*, int) all
 int         dup3(int, int, int)   all
-int         getdents:getdents64(unsigned int, struct dirent*, unsigned int)   all
 int         fsync(int)  all
 int         fdatasync(int) all
 int         fchown:fchown32(int, uid_t, gid_t)  arm,x86
-int         fchown:fchown(int, uid_t, gid_t)    arm64,mips,x86_64
+int         fchown:fchown(int, uid_t, gid_t)    arm64,mips,mips64,x86_64
 void        sync(void)  all
-int         __fstatfs64:fstatfs64(int, size_t, struct statfs*)  arm,mips,x86
-int         fstatfs(int, struct statfs*)  arm64,x86_64
 int         fsetxattr(int, const char*, const void*, size_t, int) all
 ssize_t     fgetxattr(int, const char*, void*, size_t) all
 ssize_t     flistxattr(int, char*, size_t) all
 int         fremovexattr(int, const char*) all
 
+# mips64 doesn't have getdents64 until 3.10 kernels.
+# We need this special-case hack as long as we need to support mips64 on older kernels.
+# The currently-available Debian qemu image is on a 3.2 kernel.
+int getdents:getdents64(unsigned int, struct dirent*, unsigned int)   arm,arm64,mips,x86,x86_64
+int __getdents64:getdents64(unsigned int, struct dirent*, unsigned int)   mips64
+int __getdents:getdents(unsigned int, void*, unsigned int)   mips64
+
 int __openat:openat(int, const char*, int, mode_t) all
 int faccessat(int, const char*, int, int)  all
 int fchmodat(int, const char*, mode_t, int)  all
 int fchownat(int, const char*, uid_t, gid_t, int)  all
-int fstatat:fstatat64(int, const char*, struct stat*, int)   arm,mips,x86
-int fstatat:newfstatat(int, const char*, struct stat*, int)  arm64,x86_64
+int fstatat64|fstatat:fstatat64(int, const char*, struct stat*, int)   arm,mips,x86
+int fstatat64|fstatat:newfstatat(int, const char*, struct stat*, int)  arm64,mips64,x86_64
 int linkat(int, const char*, int, const char*, int)  all
 int mkdirat(int, const char*, mode_t)  all
 int mknodat(int, const char*, mode_t, dev_t)  all
@@ -156,26 +160,35 @@ int utimensat(int, const char*, const struct timespec times[2], int)  all
 # That means that every system call in this section should take three lines.
 off_t lseek(int, off_t, int) arm,mips,x86
 int __llseek:_llseek(int, unsigned long, unsigned long, off64_t*, int) arm,mips,x86
-off_t lseek|lseek64(int, off_t, int) arm64,x86_64
+off_t lseek|lseek64(int, off_t, int) arm64,mips64,x86_64
 int ftruncate(int, off_t) arm,mips,x86
 int ftruncate64(int, off64_t) arm,mips,x86
-int ftruncate|ftruncate64(int, off_t) arm64,x86_64
+int ftruncate|ftruncate64(int, off_t) arm64,mips64,x86_64
 ssize_t sendfile(int out_fd, int in_fd, off_t* offset, size_t count) arm,mips,x86
 ssize_t sendfile64(int out_fd, int in_fd, off64_t* offset, size_t count) arm,mips,x86
-ssize_t sendfile|sendfile64(int out_fd, int in_fd, off_t* offset, size_t count) arm64,x86_64
+ssize_t sendfile|sendfile64(int out_fd, int in_fd, off_t* offset, size_t count) arm64,mips64,x86_64
 int truncate(const char*, off_t) arm,mips,x86
 int truncate64(const char*, off64_t) arm,mips,x86
-int truncate|truncate64(const char*, off_t) arm64,x86_64
+int truncate|truncate64(const char*, off_t) arm64,mips64,x86_64
 # (mmap only gets two lines because we only used the 64-bit variant on 32-bit systems.)
 void* __mmap2:mmap2(void*, size_t, int, int, int, long)   arm,mips,x86
-void* mmap|mmap64(void*, size_t, int, int, int, off_t)  arm64,x86_64
+void* mmap|mmap64(void*, size_t, int, int, int, off_t)  arm64,mips64,x86_64
+# (fallocate only gets two lines because there is no 32-bit variant.)
+int fallocate64:fallocate(int, int, off64_t, off64_t) arm,mips,x86
+int fallocate|fallocate64(int, int, off_t, off_t) arm64,mips64,x86_64
+
+int __fstatfs64:fstatfs64(int, size_t, struct statfs*)  arm,mips,x86
+int fstatfs64|fstatfs:fstatfs(int, struct statfs*)  arm64,mips64,x86_64
+int __statfs64:statfs64(const char*, size_t, struct statfs*)  arm,mips,x86
+int statfs64|statfs:statfs(const char*, struct statfs*)  arm64,mips64,x86_64
+
+int     fstat64|fstat:fstat64(int, struct stat*)    arm,mips,x86
+int     fstat64|fstat:fstat(int, struct stat*)    arm64,mips64,x86_64
 
 # file system
 int     chdir(const char*)              all
 int     mount(const char*, const char*, const char*, unsigned long, const void*)  all
 int     umount2(const char*, int)  all
-int     fstat:fstat64(int, struct stat*)    arm,mips,x86
-int     fstat(int, struct stat*)    arm64,x86_64
 int     __getcwd:getcwd(char* buf, size_t size)  all
 int     fchdir(int)    all
 int     setxattr(const char*, const char*, const void*, size_t, int) all
@@ -186,8 +199,6 @@ ssize_t listxattr(const char*, char*, size_t) all
 ssize_t llistxattr(const char*, char*, size_t) all
 int     removexattr(const char*, const char*) all
 int     lremovexattr(const char*, const char*) all
-int     __statfs64:statfs64(const char*, size_t, struct statfs*)  arm,mips,x86
-int     statfs(const char*, struct statfs*)  arm64,x86_64
 int     swapon(const char*, int) all
 int     swapoff(const char*) all
 
@@ -221,21 +232,23 @@ int     __rt_sigtimedwait:rt_sigtimedwait(const sigset_t*, struct siginfo_t*, st
 int     signalfd4(int, const sigset_t*, size_t, int)  all
 
 # sockets
-int           socket(int, int, int)              arm,arm64,mips,x86_64
-int           socketpair(int, int, int, int*)    arm,arm64,mips,x86_64
-int           bind(int, struct sockaddr*, int)  arm,arm64,mips,x86_64
-int           connect(int, struct sockaddr*, socklen_t)   arm,arm64,mips,x86_64
-int           listen(int, int)                   arm,arm64,mips,x86_64
-int           accept(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,x86_64
-int           getsockname(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,x86_64
-int           getpeername(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,x86_64
-int           sendto(int, const void*, size_t, int, const struct sockaddr*, socklen_t)  arm,arm64,mips,x86_64
-int           recvfrom(int, void*, size_t, unsigned int, struct sockaddr*, socklen_t*)  arm,arm64,mips,x86_64
-int           shutdown(int, int)  arm,arm64,mips,x86_64
-int           setsockopt(int, int, int, const void*, socklen_t)  arm,arm64,mips,x86_64
-int           getsockopt(int, int, int, void*, socklen_t*)    arm,arm64,mips,x86_64
-int           sendmsg(int, const struct msghdr*, unsigned int)  arm,arm64,mips,x86_64
-int           recvmsg(int, struct msghdr*, unsigned int)   arm,arm64,mips,x86_64
+int           socket(int, int, int)              arm,arm64,mips,mips64,x86_64
+int           socketpair(int, int, int, int*)    arm,arm64,mips,mips64,x86_64
+int           bind(int, struct sockaddr*, int)  arm,arm64,mips,mips64,x86_64
+int           connect(int, struct sockaddr*, socklen_t)   arm,arm64,mips,mips64,x86_64
+int           listen(int, int)                   arm,arm64,mips,mips64,x86_64
+int           accept(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,mips64,x86_64
+int           getsockname(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,mips64,x86_64
+int           getpeername(int, struct sockaddr*, socklen_t*)  arm,arm64,mips,mips64,x86_64
+int           sendto(int, const void*, size_t, int, const struct sockaddr*, socklen_t)  arm,arm64,mips,mips64,x86_64
+int           recvfrom(int, void*, size_t, unsigned int, struct sockaddr*, socklen_t*)  arm,arm64,mips,mips64,x86_64
+int           shutdown(int, int)  arm,arm64,mips,mips64,x86_64
+int           setsockopt(int, int, int, const void*, socklen_t)  arm,arm64,mips,mips64,x86_64
+int           getsockopt(int, int, int, void*, socklen_t*)    arm,arm64,mips,mips64,x86_64
+int           sendmsg(int, const struct msghdr*, unsigned int)  arm,arm64,mips,mips64,x86_64
+int           recvmsg(int, struct msghdr*, unsigned int)   arm,arm64,mips,mips64,x86_64
+int           recvmmsg(int, struct mmsghdr*, unsigned int, int, const struct timespec*)   arm,arm64,mips,mips64,x86_64
+int           sendmmsg(int, struct mmsghdr*, unsigned int, int)   arm,arm64,mips,mips64,x86_64
 
 # sockets for x86. These are done as an "indexed" call to socketcall syscall.
 int           socket:socketcall:1(int, int, int) x86
@@ -253,6 +266,8 @@ int           setsockopt:socketcall:14(int, int, int, const void*, socklen_t)  x
 int           getsockopt:socketcall:15(int, int, int, void*, socklen_t*)    x86
 int           sendmsg:socketcall:16(int, const struct msghdr*, unsigned int)  x86
 int           recvmsg:socketcall:17(int, struct msghdr*, unsigned int)   x86
+int           recvmmsg:socketcall:19(int, struct mmsghdr*, unsigned int, int, const struct timespec*)   x86
+int           sendmmsg:socketcall:20(int, struct mmsghdr*, unsigned int, int)   x86
 
 # scheduler & real-time
 int sched_setscheduler(pid_t pid, int policy, const struct sched_param* param)  all
@@ -313,4 +328,4 @@ int     __set_tls:__ARM_NR_set_tls(void*)                                 arm
 int     cacheflush:__ARM_NR_cacheflush(long start, long end, long flags)  arm
 
 # MIPS-specific
-int     _flush_cache:cacheflush(char* addr, const int nbytes, const int op) mips
+int     _flush_cache:cacheflush(char* addr, const int nbytes, const int op) mips,mips64
index 95c3b610d738b80206b7d911ec418a2480fd71e8..89a1ce050f098b4c163654e9701fb58c0e615271 100644 (file)
@@ -1,4 +1,51 @@
-_LIBC_ARCH_COMMON_SRC_FILES := \
+# arm specific configs
+
+# These are used by the 32-bit targets, but not the 64-bit ones.
+libc_common_src_files_arm := \
+    bionic/legacy_32_bit_support.cpp \
+    bionic/ndk_cruft.cpp \
+
+# These are shared by all the 32-bit targets, but not the 64-bit ones.
+libc_bionic_src_files_arm := \
+    bionic/mmap.cpp
+
+libc_common_src_files_arm += \
+    bionic/index.cpp \
+    bionic/memchr.c \
+    bionic/memmove.c.arm \
+    bionic/memrchr.c \
+    bionic/strchr.cpp \
+    bionic/strnlen.c \
+    bionic/strrchr.cpp \
+    upstream-freebsd/lib/libc/string/wcscat.c \
+    upstream-freebsd/lib/libc/string/wcschr.c \
+    upstream-freebsd/lib/libc/string/wcscmp.c \
+    upstream-freebsd/lib/libc/string/wcscpy.c \
+    upstream-freebsd/lib/libc/string/wcslen.c \
+    upstream-freebsd/lib/libc/string/wcsrchr.c \
+    upstream-freebsd/lib/libc/string/wmemcmp.c \
+    upstream-openbsd/lib/libc/string/bcopy.c \
+    upstream-openbsd/lib/libc/string/strlcat.c \
+    upstream-openbsd/lib/libc/string/strlcpy.c \
+    upstream-openbsd/lib/libc/string/strncat.c \
+    upstream-openbsd/lib/libc/string/strncmp.c \
+    upstream-openbsd/lib/libc/string/strncpy.c \
+
+# The C++ fortify function implementations for which there is an
+# arm assembler version.
+#
+# Fortify implementations of libc functions.
+# libc_common_src_files_arm +=
+#    bionic/__memcpy_chk.cpp \
+#    bionic/__memset_chk.cpp \
+#    bionic/__strcpy_chk.cpp \
+#    bionic/__strcat_chk.cpp \
+
+libc_common_cflags_arm := -DSOFTFLOAT
+
+##########################################
+### CPU specific source files
+libc_bionic_src_files_arm += \
     arch-arm/bionic/abort_arm.S \
     arch-arm/bionic/atomics_arm.c \
     arch-arm/bionic/__bionic_clone.S \
@@ -14,30 +61,31 @@ _LIBC_ARCH_COMMON_SRC_FILES := \
     arch-arm/bionic/sigsetjmp.S \
     arch-arm/bionic/syscall.S \
 
-# These are used by the static and dynamic versions of the libc
-# respectively.
-_LIBC_ARCH_STATIC_SRC_FILES := \
-    arch-arm/bionic/exidx_static.c \
-    bionic/dl_iterate_phdr_static.c \
+libc_arch_static_src_files_arm := arch-arm/bionic/exidx_static.c
+libc_arch_dynamic_src_files_arm := arch-arm/bionic/exidx_dynamic.c
 
-_LIBC_ARCH_DYNAMIC_SRC_FILES := \
-    arch-arm/bionic/exidx_dynamic.c \
+## CPU variant specific source files
+ifeq ($(strip $(TARGET_$(my_2nd_arch_prefix)CPU_VARIANT)),)
+  $(warning TARGET_$(my_2nd_arch_prefix)ARCH is arm, but TARGET_$(my_2nd_arch_prefix)CPU_VARIANT is not defined)
+endif
+cpu_variant_mk := $(LOCAL_PATH)/arch-arm/$(TARGET_$(my_2nd_arch_prefix)CPU_VARIANT)/$(TARGET_$(my_2nd_arch_prefix)CPU_VARIANT).mk
+ifeq ($(wildcard $(cpu_variant_mk)),)
+$(error "TARGET_$(my_2nd_arch_prefix)CPU_VARIANT not set or set to an unknown value. Possible values are cortex-a7, cortex-a8, cortex-a9, cortex-a15, krait. Use generic for devices that do not have a CPU similar to any of the supported cpu variants.")
+endif
+include $(cpu_variant_mk)
+libc_common_additional_dependencies += $(cpu_variant_mk)
 
-# Remove the C++ fortify function implementations for which there is an
-# arm assembler version.
-_LIBC_FORTIFY_FILES_TO_REMOVE := \
-    bionic/__memcpy_chk.cpp \
-    bionic/__memset_chk.cpp \
-    bionic/__strcpy_chk.cpp \
-    bionic/__strcat_chk.cpp \
+cpu_variant_mk :=
 
-libc_common_src_files := \
-    $(filter-out $(_LIBC_FORTIFY_FILES_TO_REMOVE),$(libc_common_src_files))
 
-ifeq ($(strip $(wildcard bionic/libc/arch-arm/$(TARGET_CPU_VARIANT)/$(TARGET_CPU_VARIANT).mk)),)
-$(error "TARGET_CPU_VARIANT not set or set to an unknown value. Possible values are cortex-a7, cortex-a8, cortex-a9, cortex-a15, krait. Use generic for devices that do not have a CPU similar to any of the supported cpu variants.")
-endif
+libc_crt_target_cflags_arm := \
+    -I$(LOCAL_PATH)/arch-arm/include \
+    -mthumb-interwork
+
+libc_crt_target_so_cflags_arm :=
+
+libc_crt_target_crtbegin_file_arm := \
+    $(LOCAL_PATH)/arch-common/bionic/crtbegin.c
 
-_LIBC_ARCH_ADDITIONAL_DEPENDENCIES := \
-    $(LOCAL_PATH)/arch-arm/$(TARGET_CPU_VARIANT)/$(TARGET_CPU_VARIANT).mk
-include $(LOCAL_PATH)/arch-arm/$(TARGET_CPU_VARIANT)/$(TARGET_CPU_VARIANT).mk
+libc_crt_target_crtbegin_so_file_arm := \
+    $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c
index 2a7e7b7716e6a7aa207f4b5a9b5bfefc74b24f92..aabec6d8cc819dd4b07b5063f82b17f7cbf705ae 100644 (file)
@@ -26,7 +26,7 @@
  * SUCH DAMAGE.
  */
 
-#include <machine/asm.h>
+#include <private/bionic_asm.h>
 
 ENTRY(__get_sp)
   mov r0, sp
index 6b8aa503a635c2e03e1c06e72330c610ca198bcb..64a0a31c93dc8fa49ca778e4faeb6365508d9636 100644 (file)
@@ -34,7 +34,7 @@
  * SUCH DAMAGE.
  */
 
-#include <machine/asm.h>
+#include <private/bionic_asm.h>
 #include <machine/setjmp.h>
 #include <machine/cpu-features.h>
 
@@ -107,7 +107,7 @@ ENTRY(_longjmp)
 
        /* validation failed, die die die. */
 botch:
-       bl      PIC_SYM(_C_LABEL(longjmperror), PLT)
-       bl      PIC_SYM(_C_LABEL(abort), PLT)
+       bl      PIC_SYM(longjmperror, PLT)
+       bl      PIC_SYM(abort, PLT)
        b       . - 8           /* Cannot get here */
 END(_longjmp)
index 1aaf21ad88b17b075817a449e5e626aca6c88fa9..6b181efb753f2ce0592453fad36efce0c0268799 100644 (file)
@@ -26,7 +26,7 @@
  * SUCH DAMAGE.
  */
 
-#include <machine/asm.h>
+#include <private/bionic_asm.h>
 
 /*
  * Coding the abort function in assembly so that registers are guaranteed to
@@