Android.mk revision 36d6188f8cd8b948fb797f11d9620d63d0c2215a
11dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_PATH:= $(call my-dir) 21dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 31dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(LOCAL_PATH)/arch-$(TARGET_ARCH)/syscalls.mk 4ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin 5d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris# Make everything depend on any changes to included makefiles. 6d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferrislibc_common_additional_dependencies := \ 7d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris $(LOCAL_PATH)/arch-$(TARGET_ARCH)/syscalls.mk \ 8d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris $(LOCAL_PATH)/Android.mk \ 9d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris 10ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# Define the common source files for all the libc instances 11ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ========================================================= 121dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectlibc_common_src_files := \ 131dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project $(syscall_src) \ 141dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/alarm.c \ 151dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/exec.c \ 161dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/fnmatch.c \ 171dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/syslog.c \ 181dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/system.c \ 191dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project unistd/time.c \ 201dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/asprintf.c \ 211dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fflush.c \ 221dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fgetc.c \ 231dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/findfp.c \ 241dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fprintf.c \ 251dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fputc.c \ 261dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fread.c \ 271dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/freopen.c \ 281dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fscanf.c \ 291dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fseek.c \ 301dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/ftell.c \ 311dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/fvwrite.c \ 321dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/gets.c \ 331dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/printf.c \ 341dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/refill.c \ 351dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/rewind.c \ 361dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/scanf.c \ 371dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/snprintf.c\ 381dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/sprintf.c \ 391dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/sscanf.c \ 401dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/stdio.c \ 411dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/ungetc.c \ 421dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vasprintf.c \ 431dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vfprintf.c \ 441dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vfscanf.c \ 451dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vprintf.c \ 461dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vsnprintf.c \ 471dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vsprintf.c \ 481dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vscanf.c \ 491dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/vsscanf.c \ 501dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdio/wbuf.c \ 511dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/atexit.c \ 521dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/ctype_.c \ 531dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/getenv.c \ 541dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/putenv.c \ 551dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/setenv.c \ 561dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtod.c \ 571dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtoimax.c \ 581dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtol.c \ 591dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtoll.c \ 601dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtoul.c \ 611dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtoull.c \ 621dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/strtoumax.c \ 631dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/tolower_.c \ 641dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project stdlib/toupper_.c \ 651dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strcasecmp.c \ 661dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strcspn.c \ 671dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strdup.c \ 681dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strpbrk.c \ 691dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strsep.c \ 701dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strspn.c \ 711dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strstr.c \ 721dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project string/strtok.c \ 733527fd6f0df794207215790321824b7844cc712dDavid 'Digit' Turner wchar/wcswidth.c \ 7470465614e14a87f547cdd1b82b0b270b87d215c1Kristian Monsen wchar/wcsxfrm.c \ 751dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/arc4random.c \ 76a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/atoi.c \ 77a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/atol.c \ 78a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/atoll.c \ 79a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/bindresvport.c \ 80fc10b24accd082fb33c8f92ff8b92481c22fe3dcColin Cross bionic/clearenv.c \ 81a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/daemon.c \ 8264ceac3f493e3063a289aec4a12c74787be974e4Colin Cross bionic/err.c \ 83a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ether_aton.c \ 84a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ether_ntoa.c \ 85fc10b24accd082fb33c8f92ff8b92481c22fe3dcColin Cross bionic/fdprintf.c \ 86a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/flockfile.c \ 87a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ftime.c \ 88a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ftok.c \ 8964ceac3f493e3063a289aec4a12c74787be974e4Colin Cross bionic/fts.c \ 90a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/getdtablesize.c \ 91a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/gethostname.c \ 92a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/getpgrp.c \ 93a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/getpriority.c \ 94a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/getpt.c \ 951dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/if_indextoname.c \ 96a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/if_nametoindex.c \ 97a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/initgroups.c \ 981dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/ioctl.c \ 99a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/isatty.c \ 100a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/issetugid.c \ 1011dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/ldexp.c \ 1021dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/md5.c \ 103a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/memmem.c \ 104a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/memswap.c \ 105a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/pathconf.c \ 106a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/perror.c \ 107a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ptsname.c \ 108a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/ptsname_r.c \ 1091dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/pututline.c \ 110a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/reboot.c \ 111a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/recv.c \ 11272e6fd42421dca80fb2776a9185c186d4a04e5f7David 'Digit' Turner bionic/sched_cpualloc.c \ 11372e6fd42421dca80fb2776a9185c186d4a04e5f7David 'Digit' Turner bionic/sched_cpucount.c \ 114a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/sched_getcpu.c \ 1151dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/semaphore.c \ 116a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/send.c \ 117a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/setpgrp.c \ 118a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/sigblock.c \ 119a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/siginterrupt.c \ 120a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/siglist.c \ 121a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/signame.c \ 122a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/sigsetmask.c \ 123a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/sleep.c \ 124a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/strndup.c \ 125a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/strntoimax.c \ 126a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/strntoumax.c \ 127a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/strtotimeval.c \ 1281dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/system_properties.c \ 1295e9a086145764d64c0f7fbce5489d820aa7fdcd4Colin Cross bionic/system_properties_compat.c \ 130a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/tcgetpgrp.c \ 131a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/tcsetpgrp.c \ 132a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/time64.c \ 133a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/umount.c \ 134a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/unlockpt.c \ 135a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/usleep.c \ 1361dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/utmp.c \ 137a89864a20b818621a1da10e88fda815334062f9fElliott Hughes bionic/wcscoll.c \ 138eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 139eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 140eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hugheslibc_dns_src_files += \ 141eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/gethnamaddr.c \ 142eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/inet/nsap_addr.c \ 143eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_name.c \ 144eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_netint.c \ 145eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_parse.c \ 146eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_print.c \ 147eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_samedomain.c \ 148eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/nameser/ns_ttl.c \ 149eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/base64.c \ 150eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/getaddrinfo.c \ 151eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/getnameinfo.c \ 152eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/getservbyname.c \ 153eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/getservbyport.c \ 154eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/getservent.c \ 155eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/net/nsdispatch.c \ 156eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/__dn_comp.c \ 157eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/herror.c \ 158eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_cache.c \ 159eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/__res_close.c \ 160eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_comp.c \ 161eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_data.c \ 162eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_debug.c \ 163eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_init.c \ 164eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_mkquery.c \ 165eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_query.c \ 166eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/__res_send.c \ 167eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_send.c \ 168eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes netbsd/resolv/res_state.c \ 169eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 1701dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 171062092543fdbd6fa2676e4f5b37a15f7bba94332Elliott Hughes# These are used by the 32-bit targets, but not the 64-bit ones. 172a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),arm mips x86)) 173a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinlibc_common_src_files += \ 174062092543fdbd6fa2676e4f5b37a15f7bba94332Elliott Hughes bionic/legacy_32_bit_support.cpp \ 175567a8de3ca5b4c4f033bfbcdd339a3fd59a76227Elliott Hughes bionic/ndk_cruft.cpp \ 176a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 177a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinendif 178a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 17959a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris# Fortify implementations of libc functions. 18059a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferrislibc_common_src_files += \ 18190201d5eca050414d50a433866ccb580415bb0d4Nick Kralevich bionic/__FD_chk.cpp \ 18259a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__fgets_chk.cpp \ 18359a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__memcpy_chk.cpp \ 18459a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__memmove_chk.cpp \ 18559a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__memset_chk.cpp \ 186b036b5ca36c1e12b075909b3eca6eab73ee611cfNick Kralevich bionic/__read_chk.cpp \ 18760f4f9a5b99a0a66817f50edfc2194a49f8b5146Nick Kralevich bionic/__recvfrom_chk.cpp \ 18859a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strcat_chk.cpp \ 18959a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strchr_chk.cpp \ 19059a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strcpy_chk.cpp \ 19159a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strlcat_chk.cpp \ 19259a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strlcpy_chk.cpp \ 19359a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strlen_chk.cpp \ 19459a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strncat_chk.cpp \ 19559a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strncpy_chk.cpp \ 19659a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__strrchr_chk.cpp \ 19759a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__umask_chk.cpp \ 19859a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__vsnprintf_chk.cpp \ 19959a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris bionic/__vsprintf_chk.cpp \ 20059a13c122ebc4191583b67c846a95d690dcda5cfChristopher Ferris 20129c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hugheslibc_bionic_src_files := \ 20261e699a133a4807fe878a6cb0d7190d7c96e21f8Elliott Hughes bionic/abort.cpp \ 203f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/access.cpp \ 204063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/assert.cpp \ 20511952073af22568bba0b661f7a9d4402c443a888Elliott Hughes bionic/bionic_time_conversions.cpp \ 206428f5567be25b8090e3dd72e2d3d337c305b514eElliott Hughes bionic/brk.cpp \ 207f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/chmod.cpp \ 208f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/chown.cpp \ 20936d6188f8cd8b948fb797f11d9620d63d0c2215aElliott Hughes bionic/clone.cpp \ 210c30396f5f225e0b5a83a35432e2d82a7063cfdb9David 'Digit' Turner bionic/dirent.cpp \ 211cac7b9d6ec1a09814bc028e2f768db732f018891Elliott Hughes bionic/dup2.cpp \ 212cac7b9d6ec1a09814bc028e2f768db732f018891Elliott Hughes bionic/epoll_create.cpp \ 21311952073af22568bba0b661f7a9d4402c443a888Elliott Hughes bionic/epoll_wait.cpp \ 21411952073af22568bba0b661f7a9d4402c443a888Elliott Hughes bionic/epoll_pwait.cpp \ 2152a0b873065edb304fa2d1c54f8de663ea638b8abElliott Hughes bionic/__errno.cpp \ 2169b84824dfd597d8137137fa33295faa26cc70ae0Kito Cheng bionic/eventfd_read.cpp \ 2179b84824dfd597d8137137fa33295faa26cc70ae0Kito Cheng bionic/eventfd_write.cpp \ 218bf425680e484486803bf21e4c4cd1e3f36614a3cElliott Hughes bionic/ffs.cpp \ 219232163cf70712fe00436b70dd495f4cf405e9eabElliott Hughes bionic/fork.cpp \ 220d0be7c8f9a06b3ca8ea7647ea35c8f9dc63f0fe1Elliott Hughes bionic/futimens.cpp \ 2212c5153b043b44e9935a334ae9b2d5a4bc5258b40Nick Kralevich bionic/getauxval.cpp \ 222063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/getcwd.cpp \ 223cac7b9d6ec1a09814bc028e2f768db732f018891Elliott Hughes bionic/inotify_init.cpp \ 224f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/lchown.cpp \ 22542b2c6a5eed5e4ef35315b8cd32d1355f12a69b6Elliott Hughes bionic/libc_init_common.cpp \ 2268f2a5a0b40fc82126c691d5c30131d908772aab7Elliott Hughes bionic/libc_logging.cpp \ 22758b575485c446f9d76ee00f67516ed42cf017769Elliott Hughes bionic/libgen.cpp \ 228f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/link.cpp \ 229f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/lstat.cpp \ 230f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/mkdir.cpp \ 231594b1a4af204aa9de2b4913182f4556e38d71648Elliott Hughes bionic/mkfifo.cpp \ 232f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/mknod.cpp \ 233f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/open.cpp \ 23411952073af22568bba0b661f7a9d4402c443a888Elliott Hughes bionic/pause.cpp \ 235cac7b9d6ec1a09814bc028e2f768db732f018891Elliott Hughes bionic/pipe.cpp \ 23611952073af22568bba0b661f7a9d4402c443a888Elliott Hughes bionic/poll.cpp \ 237c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_atfork.cpp \ 2383e898476c7230b60a0f76968e64ff25f475b48c0Elliott Hughes bionic/pthread_attr.cpp \ 239c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_cond.cpp \ 240c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_create.cpp \ 2419d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_detach.cpp \ 2429d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_equal.cpp \ 243c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_exit.cpp \ 2449d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_getcpuclockid.cpp \ 2459d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_getschedparam.cpp \ 2469d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_internals.cpp \ 2479d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_join.cpp \ 248c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_key.cpp \ 2499d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_kill.cpp \ 250c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_mutex.cpp \ 251c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_once.cpp \ 252c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/pthread_rwlock.cpp \ 2539d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_self.cpp \ 2543e898476c7230b60a0f76968e64ff25f475b48c0Elliott Hughes bionic/pthread_setname_np.cpp \ 2559d23e04c43dbb8480bea8be28b8a2f37423bec49Elliott Hughes bionic/pthread_setschedparam.cpp \ 256c5d028fc913de84a781bd61084bf7ae2182fd48eElliott Hughes bionic/pthread_sigmask.cpp \ 257c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/ptrace.cpp \ 258d8a5a6f513c6fa99229e9c82c5c308c7cd6b3d54Chris Dearman bionic/raise.cpp \ 259f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/readlink.cpp \ 260f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/rename.cpp \ 261f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/rmdir.cpp \ 262428f5567be25b8090e3dd72e2d3d337c305b514eElliott Hughes bionic/sbrk.cpp \ 263701bec2af33feaa9dddf12ccf8e4c714441b7f2eElliott Hughes bionic/scandir.cpp \ 2644ca685e36e9d7f53c135eba2b4b8ece152129dbeKito Cheng bionic/sched_getaffinity.cpp \ 265232163cf70712fe00436b70dd495f4cf405e9eabElliott Hughes bionic/setegid.cpp \ 2664a9e837840fda3aaea48aeba85c7c7a8782d2586Elliott Hughes bionic/__set_errno.cpp \ 267232163cf70712fe00436b70dd495f4cf405e9eabElliott Hughes bionic/seteuid.cpp \ 268063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/setlocale.cpp \ 269a4b2dc016fa62bd172a73c3f8971c805700ffb0fRom Lemarchand bionic/signalfd.cpp \ 270c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigaction.cpp \ 271c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigaddset.cpp \ 272c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigdelset.cpp \ 273c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigemptyset.cpp \ 274c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigfillset.cpp \ 275c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/sigismember.cpp \ 276c7e9b2331771e5e87c34a8ee3dc6cc41d35b02feElliott Hughes bionic/signal.cpp \ 27740d105ccb3e6283566ce54b693b3088f31aa4f26Elliott Hughes bionic/sigpending.cpp \ 27819e62325c268a668692e2b65fde2284079f369aaElliott Hughes bionic/sigprocmask.cpp \ 2791f5af926fa626734981d6b4dcc0ab54e520032a9Elliott Hughes bionic/sigsuspend.cpp \ 280c5d028fc913de84a781bd61084bf7ae2182fd48eElliott Hughes bionic/sigwait.cpp \ 281f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/stat.cpp \ 28206040fd75c1edff9e5ffb2b3d3e2a6e66d57c11dElliott Hughes bionic/statvfs.cpp \ 283063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/strerror.cpp \ 284063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/strerror_r.cpp \ 285063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/strsignal.cpp \ 286063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/stubs.cpp \ 287f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/symlink.cpp \ 28891a9925998f2b878f0245ce03aab22cc412a4d8bElliott Hughes bionic/sysconf.cpp \ 289c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/thread_atexit.cpp \ 290063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/tdestroy.cpp \ 291c3f114037dbf028896310609fd28cf2b3da99c4dElliott Hughes bionic/timer.cpp \ 292063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/tmpfile.cpp \ 293f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/unlink.cpp \ 294f8fcfbc85a3ce3e195626b90736d3a484331494bElliott Hughes bionic/utimes.cpp \ 29517a8b0db63d54e9d79bf11112ace0c4fe9606289Elliott Hughes bionic/wait.cpp \ 296063cfb2084ea4b12d3c85b2d2c44e888f0857eb4Elliott Hughes bionic/wchar.cpp \ 29729c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes 298a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin# These are shared by all the 32-bit targets, but not the 64-bit ones. 299a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),arm mips x86)) 300a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinlibc_bionic_src_files += \ 301a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/mmap.cpp \ 302a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 303a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinendif 304a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 305ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hugheslibc_tzcode_src_files := \ 306ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes tzcode/asctime.c \ 307ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes tzcode/difftime.c \ 308ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes tzcode/localtime.c \ 309ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes tzcode/strftime.c \ 310ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes tzcode/strptime.c \ 311ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 312f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hugheslibc_upstream_freebsd_src_files := \ 3136b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/clrerr.c \ 3146b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fclose.c \ 3156b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fdopen.c \ 3166b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/feof.c \ 3176b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/ferror.c \ 3186b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fgetln.c \ 3196b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fgetpos.c \ 3206b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fgets.c \ 3216b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fileno.c \ 3226b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/flags.c \ 3236b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fopen.c \ 3246b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fpurge.c \ 3256b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fputs.c \ 3266b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fsetpos.c \ 3276b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/funopen.c \ 3286b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fwalk.c \ 3296b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/fwrite.c \ 3306b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/getc.c \ 3316b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/getchar.c \ 332677ee5647721df22f13909375d5d0e770a1a80bfElliott Hughes upstream-freebsd/lib/libc/stdio/makebuf.c \ 333284f7880323d33356df682c3cfb6b7f0c665bfd4Elliott Hughes upstream-freebsd/lib/libc/stdio/mktemp.c \ 3346b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/putc.c \ 3356b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/putchar.c \ 3366b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/puts.c \ 3376b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/putw.c \ 3386b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/remove.c \ 3396b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/rget.c \ 3406b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/setbuf.c \ 3416b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/setbuffer.c \ 342677ee5647721df22f13909375d5d0e770a1a80bfElliott Hughes upstream-freebsd/lib/libc/stdio/setvbuf.c \ 3436b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/tempnam.c \ 3446b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/tmpnam.c \ 3456b05c8e28017518fae04a3a601d0d245916561d2Elliott Hughes upstream-freebsd/lib/libc/stdio/wsetup.c \ 346aec2ffbc5a7b45368ceab3663265fbb659968fe7Elliott Hughes upstream-freebsd/lib/libc/stdlib/abs.c \ 347d278b828fef47fb2d7098f8ec70867fbd3da09d6Elliott Hughes upstream-freebsd/lib/libc/stdlib/getopt_long.c \ 348aec2ffbc5a7b45368ceab3663265fbb659968fe7Elliott Hughes upstream-freebsd/lib/libc/stdlib/imaxabs.c \ 349aec2ffbc5a7b45368ceab3663265fbb659968fe7Elliott Hughes upstream-freebsd/lib/libc/stdlib/imaxdiv.c \ 350aec2ffbc5a7b45368ceab3663265fbb659968fe7Elliott Hughes upstream-freebsd/lib/libc/stdlib/labs.c \ 351aec2ffbc5a7b45368ceab3663265fbb659968fe7Elliott Hughes upstream-freebsd/lib/libc/stdlib/llabs.c \ 3520b25f633a23e575c8a1f9547d1af5dc5b0157a1cElliott Hughes upstream-freebsd/lib/libc/stdlib/qsort.c \ 353f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes upstream-freebsd/lib/libc/stdlib/realpath.c \ 354eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcpcpy.c \ 355eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcpncpy.c \ 356eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcscasecmp.c \ 357eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcscspn.c \ 358eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsdup.c \ 359eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcslcat.c \ 360eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcslcpy.c \ 361eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsncasecmp.c \ 362eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsncat.c \ 363eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsncmp.c \ 364eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsncpy.c \ 365eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsnlen.c \ 366eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcspbrk.c \ 367eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsspn.c \ 368eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcsstr.c \ 369eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wcstok.c \ 370eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wmemchr.c \ 371eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wmemcpy.c \ 372eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wmemmove.c \ 373eb93ebffba21e2c9b8a12bb86db60d38c7750270Elliott Hughes upstream-freebsd/lib/libc/string/wmemset.c \ 374f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 375f8b3a920a895a53b207017249080087d562bd0d2Elliott Hugheslibc_upstream_netbsd_src_files := \ 376e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/common/lib/libc/hash/sha1/sha1.c \ 377e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/common/lib/libc/inet/inet_addr.c \ 378e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/compat-43/creat.c \ 379e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/gen/ftw.c \ 380e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/gen/nftw.c \ 381e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/gen/nice.c \ 3826b3f49a5374305ce9690c3c5ca2aadc90f54c521Elliott Hughes upstream-netbsd/libc/gen/popen.c \ 383e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/gen/psignal.c \ 384ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/gen/setjmperr.c \ 385e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/gen/utime.c \ 386e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/inet/inet_ntoa.c \ 387e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/inet/inet_ntop.c \ 388e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/inet/inet_pton.c \ 389ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/isc/ev_streams.c \ 390ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/isc/ev_timers.c \ 391e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/regex/regcomp.c \ 392e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/regex/regerror.c \ 393e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/regex/regexec.c \ 394e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/regex/regfree.c \ 395e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdio/getdelim.c \ 396e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdio/getline.c \ 397ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/stdlib/bsearch.c \ 398ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/stdlib/div.c \ 399e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/drand48.c \ 400e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/erand48.c \ 401652289942d0d2543af90c8af9c04d80a2edb481aPawit Pornkitprasan upstream-netbsd/libc/stdlib/exit.c \ 402e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/jrand48.c \ 403ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/stdlib/ldiv.c \ 404ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/stdlib/lldiv.c \ 405e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/lrand48.c \ 406e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/mrand48.c \ 407e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/nrand48.c \ 408e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/_rand48.c \ 409e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/seed48.c \ 410e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/srand48.c \ 411e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/tdelete.c \ 412e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/tfind.c \ 413e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/stdlib/tsearch.c \ 414c51cd764a2d0897234762abd4dbd21420cb9f17dElliott Hughes upstream-netbsd/libc/string/memccpy.c \ 415e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/string/strcasestr.c \ 4162b473070126345e323d0694b87f88264cc9a77ccElliott Hughes upstream-netbsd/libc/string/strcoll.c \ 417e8bcca3a2ca4a70156c72239d62bb68eeb2929fdElliott Hughes upstream-netbsd/libc/string/strxfrm.c \ 418652289942d0d2543af90c8af9c04d80a2edb481aPawit Pornkitprasan upstream-netbsd/libc/thread-stub/__isthreaded.c \ 419ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes upstream-netbsd/libc/unistd/killpg.c \ 420f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 4212f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes# Architecture specific source files go here 4222f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes# ========================================================= 4232f287bc72827525ad42ee43d532d267a388104c3Elliott Hughesifeq ($(TARGET_ARCH),arm) 4242f287bc72827525ad42ee43d532d267a388104c3Elliott Hugheslibc_common_src_files += \ 4252f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memchr.c \ 4262f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memmove.c.arm \ 4272f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memrchr.c \ 4282f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/strchr.cpp \ 4292f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/strnlen.c \ 4302f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/bcopy.c \ 4312f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/index.c \ 4322f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strlcat.c \ 4332f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strlcpy.c \ 4342f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncat.c \ 4352f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncmp.c \ 4362f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncpy.c \ 4372f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strrchr.c \ 4382f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscat.c \ 4392f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcschr.c \ 4402f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscmp.c \ 4412f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscpy.c \ 4422f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcslen.c \ 4432f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcsrchr.c \ 4442f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wmemcmp.c \ 4452f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes 4462f287bc72827525ad42ee43d532d267a388104c3Elliott Hughesendif # arm 4472f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes 4482f287bc72827525ad42ee43d532d267a388104c3Elliott Hughesifeq ($(TARGET_ARCH),mips) 4492f287bc72827525ad42ee43d532d267a388104c3Elliott Hugheslibc_common_src_files += \ 4502f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memchr.c \ 4512f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memcmp.c \ 4522f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/memrchr.c \ 4532f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/strchr.cpp \ 4542f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes bionic/strnlen.c \ 4552f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/bcopy.c \ 4562f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/index.c \ 4572f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strcat.c \ 4582f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strcmp.c \ 4592f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strcpy.c \ 4602f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strlcat.c \ 4612f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strlcpy.c \ 4622f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncat.c \ 4632f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncmp.c \ 4642f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strncpy.c \ 4652f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes string/strrchr.c \ 4662f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscat.c \ 4672f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcschr.c \ 4682f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscmp.c \ 4692f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcscpy.c \ 4702f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcslen.c \ 4712f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wcsrchr.c \ 4722f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes upstream-freebsd/lib/libc/string/wmemcmp.c \ 4732f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes 4742f287bc72827525ad42ee43d532d267a388104c3Elliott Hughesendif # mips 47510093276e98d26428875480c502a278dffe550c7Shin-ichiro KAWASAKI 476a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86_64)) 477a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinlibc_common_src_files += \ 478a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memchr.c \ 479a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memcmp.c \ 480a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memcpy.c \ 481a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memmove.c \ 482a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memrchr.c \ 483a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/memset.c \ 484a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/strchr.cpp \ 485a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin bionic/strnlen.c \ 486a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/bcopy.c \ 487a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/index.c \ 488a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strcat.c \ 489a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strcmp.c \ 490a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strcpy.c \ 491a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strlcat.c \ 492a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strlcpy.c \ 493a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strlen.c \ 494a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strncat.c \ 495a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strncmp.c \ 496a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strncpy.c \ 497a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin string/strrchr.c \ 498a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcscat.c \ 499a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcschr.c \ 500a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcscmp.c \ 501a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcscpy.c \ 502a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcslen.c \ 503a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wcsrchr.c \ 504a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin upstream-freebsd/lib/libc/string/wmemcmp.c \ 505a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 506a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinendif # x86_64 507a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupin 5082f287bc72827525ad42ee43d532d267a388104c3Elliott Hughesifeq ($(TARGET_ARCH),arm) 5092f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes ifeq ($(strip $(TARGET_CPU_VARIANT)),) 5102f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes $(warning TARGET_ARCH is arm, but TARGET_CPU_VARIANT is not defined) 5112f287bc72827525ad42ee43d532d267a388104c3Elliott Hughes endif 5127c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferrisendif 5137c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris 5147c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris########################################################### 5157c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## Add cpu specific source files. 5167c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## 5177c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## This can be called multiple times, but it will only add 5187c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## the first source file for each unique $(1). 5197c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## $(1): Unique identifier to identify the cpu variant 5207c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## implementation. 5217c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris## $(2): Cpu specific source file. 5227c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris########################################################### 5237c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris 5247c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferrisdefine libc-add-cpu-variant-src 5257c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris$(if $(filter true,$(_LIBC_ARCH_CPU_VARIANT_HAS_$(1))), \ 5267c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris , \ 5277c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris $(eval _LIBC_ARCH_CPU_VARIANT_HAS_$(1) := true) \ 5287c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris $(eval _LIBC_ARCH_CPU_VARIANT_SRC_FILE.$(1) := $(2)) \ 5297c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris $(eval _LIBC_ARCH_CPU_VARIANT_SRC_FILES += $(2)) \ 5307c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris) 5317c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferrisendef 5327c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris 5337c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris_LIBC_ARCH_COMMON_SRC_FILES := 5347c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris_LIBC_ARCH_CPU_VARIANT_SRC_FILES := 5357c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris_LIBC_ARCH_STATIC_SRC_FILES := 5367c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris_LIBC_ARCH_DYNAMIC_SRC_FILES := 537d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris_LIBC_ARCH_ADDITIONAL_DEPENDENCIES := 538d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris 539d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferrislibc_common_additional_dependencies += \ 540d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferris $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk 541d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferrisinclude $(LOCAL_PATH)/arch-$(TARGET_ARCH)/$(TARGET_ARCH).mk 5427c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris 543eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hugheslibc_bionic_src_files += $(_LIBC_ARCH_COMMON_SRC_FILES) 544eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hugheslibc_bionic_src_files += $(_LIBC_ARCH_CPU_VARIANT_SRC_FILES) 5457c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferrislibc_arch_static_src_files := $(_LIBC_ARCH_STATIC_SRC_FILES) 5467c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferrislibc_arch_dynamic_src_files := $(_LIBC_ARCH_DYNAMIC_SRC_FILES) 547d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher Ferrislibc_common_additional_dependencies += $(_LIBC_ARCH_ADDITIONAL_DEPENDENCIES) 5487c83a1ed81a15f3e75836c1ac7d500a952f02e10Christopher Ferris 549ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# Define some common cflags 550ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 5511dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectlibc_common_cflags := \ 552470631ed79538ce912edb94505dee3e24af8db89Elliott Hughes -DANDROID_CHANGES \ 553470631ed79538ce912edb94505dee3e24af8db89Elliott Hughes -D_LIBC=1 \ 5542ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes -Wall -Wextra \ 5552ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes 5562ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes# Try to catch typical 32-bit assumptions that break with 64-bit pointers. 5572ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hugheslibc_common_cflags += \ 5582ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes -Werror=pointer-to-int-cast \ 5592ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes -Werror=int-to-pointer-cast \ 5602ec400bfc7d1605b68ae3f5501add7bf2647b9ddElliott Hughes -Werror=type-limits \ 5611dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 562d2c9dcc9265e66f6432ec39dcc7378b944449e60Dave Bortifeq ($(strip $(DEBUG_BIONIC_LIBC)),true) 5631dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project libc_common_cflags += -DDEBUG 5641dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectendif 5651dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 5662fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Ren# To customize dlmalloc's alignment, set BOARD_MALLOC_ALIGNMENT in 5672fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Ren# the appropriate BoardConfig.mk file. 5682fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Ren# 5692fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Renifneq ($(BOARD_MALLOC_ALIGNMENT),) 5702fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Ren libc_common_cflags += -DMALLOC_ALIGNMENT=$(BOARD_MALLOC_ALIGNMENT) 5712fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Renendif 5722fd81ef71c10aecf6583facdd79f8f60f3eed678Jack Ren 5731dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectifeq ($(TARGET_ARCH),arm) 574a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_common_cflags += -DSOFTFLOAT 5751dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project libc_common_cflags += -fstrict-aliasing 576ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin libc_crt_target_cflags := -mthumb-interwork 5777e841ed688947855a3bd20d2b23a44599257038aElliott Hughesendif # arm 578a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham 579a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamifeq ($(TARGET_ARCH),mips) 580a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham ifneq ($(ARCH_MIPS_HAS_FPU),true) 581a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_common_cflags += -DSOFTFLOAT 582a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham endif 583a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_common_cflags += -fstrict-aliasing 584a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_crt_target_cflags := $(TARGET_GLOBAL_CFLAGS) 585a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamendif # mips 586a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham 5877e841ed688947855a3bd20d2b23a44599257038aElliott Hughesifeq ($(TARGET_ARCH),x86) 5887e841ed688947855a3bd20d2b23a44599257038aElliott Hughes libc_crt_target_cflags := -m32 5897e841ed688947855a3bd20d2b23a44599257038aElliott Hughes libc_crt_target_ldflags := -melf_i386 5907e841ed688947855a3bd20d2b23a44599257038aElliott Hughesendif # x86 5917e841ed688947855a3bd20d2b23a44599257038aElliott Hughes 5927e841ed688947855a3bd20d2b23a44599257038aElliott Hughesifeq ($(TARGET_ARCH),x86_64) 5937e841ed688947855a3bd20d2b23a44599257038aElliott Hughes libc_crt_target_cflags := -m64 5947e841ed688947855a3bd20d2b23a44599257038aElliott Hughes libc_crt_target_ldflags := -melf_x86_64 5957e841ed688947855a3bd20d2b23a44599257038aElliott Hughesendif # x86_64 5967e841ed688947855a3bd20d2b23a44599257038aElliott Hughes 597fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFadden# Define ANDROID_SMP appropriately. 598fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFaddenifeq ($(TARGET_CPU_SMP),true) 599fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFadden libc_common_cflags += -DANDROID_SMP=1 600fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFaddenelse 601fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFadden libc_common_cflags += -DANDROID_SMP=0 602fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFaddenendif 603fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFadden 60476be660aae0911467c51dc3f86a4f8d7fed5b332Elliott Hughes# crtbrand.c needs <stdint.h> and a #define for the platform SDK version. 60576be660aae0911467c51dc3f86a4f8d7fed5b332Elliott Hugheslibc_crt_target_cflags += \ 60676be660aae0911467c51dc3f86a4f8d7fed5b332Elliott Hughes -I$(LOCAL_PATH)/include \ 607eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -I$(LOCAL_PATH)/arch-$(TARGET_ARCH)/include \ 608eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -DPLATFORM_SDK_VERSION=$(PLATFORM_SDK_VERSION) \ 609fcd00ebbdf3e7f4e1e7782a65ae10fb0fc03a1aaAndy McFadden 610762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines# Define some common conlyflags 611762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hineslibc_common_conlyflags := \ 612762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines -std=gnu99 613762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines 614762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines# Define some common cppflags 615762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hineslibc_common_cppflags := \ 616762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines -std=gnu++11 617762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines 618ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# Define some common includes 619ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 6201dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectlibc_common_c_includes := \ 6211dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project $(LOCAL_PATH)/stdlib \ 6221dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project $(LOCAL_PATH)/string \ 62376656afc6dd069fcfda5768e6e54bb85e4e99942Nick Kralevich $(LOCAL_PATH)/stdio \ 62476656afc6dd069fcfda5768e6e54bb85e4e99942Nick Kralevich external/safe-iop/include 6251dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 626ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# Define the libc run-time (crt) support object files that must be built, 627ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# which are needed to build all other objects (shared/static libs and 628ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# executables) 629ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ========================================================================== 630a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham# ARM, MIPS, and x86 all need crtbegin_so/crtend_so. 6316a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# 6326a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# For x86, the .init section must point to a function that calls all 6336a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# entries in the .ctors section. (on ARM this is done through the 6346a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# .init_array section instead). 6356a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# 636a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham# For all the platforms, the .fini_array section must point to a function 6376a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# that will call __cxa_finalize(&__dso_handle) in order to ensure that 6386a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# static C++ destructors are properly called on dlclose(). 6396a9b888d7c4b246f6f66360789c72b754ff85021David 'Digit' Turner# 640b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupinlibc_crt_target_crtbegin_file := $(LOCAL_PATH)/arch-common/bionic/crtbegin.c 641b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupinlibc_crt_target_crtbegin_so_file := $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c 642b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupin 643a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamifeq ($(TARGET_ARCH),arm) 644a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_crt_target_so_cflags := 645a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamendif 646a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamifeq ($(TARGET_ARCH),mips) 647a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_crt_target_so_cflags := -fPIC 648b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupinlibc_crt_target_crtbegin_file := $(LOCAL_PATH)/arch-$(TARGET_ARCH)/bionic/crtbegin.c 649a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamendif 650a567a8e4bd9036bcb74a0a028235a48d8b2a115ePavel Chupinifeq ($(TARGET_ARCH),$(filter $(TARGET_ARCH),x86 x86_64)) 651a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandham libc_crt_target_so_cflags := -fPIC 652a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamendif 653a4c7933b49f1d43579f184167e79a5fb237bd206Raghu Gandhamlibc_crt_target_so_cflags += $(libc_crt_target_cflags) 654ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope 655ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope# See the comment in crtbrand.c for the reason why we need to generate 656ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope# crtbrand.s before generating crtbrand.o. 657ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.s 658ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope$(GEN): $(LOCAL_PATH)/bionic/crtbrand.c 659ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope @mkdir -p $(dir $@) 660cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) -S \ 661cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.s=%.d) -o $@ $< 662cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) sed -i -e '/\.note\.ABI-tag/s/progbits/note/' $@ 663cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(call transform-d-to-p-args,$(@:%.s=%.d),$(@:%.s=%.P)) 664cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.s=%.P) 665ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeALL_GENERATED_SOURCES += $(GEN) 666ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope 667ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o 668ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.s 669ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope @mkdir -p $(dir $@) 670cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) -o $@ -c $< 671ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeALL_GENERATED_SOURCES += $(GEN) 672ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope 673fc9e525fe07846c1efa23235a59575f8dad69c53Ying WangGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_so.o 67412949e5d3946cc5d5b53d52adf5a3b925bfca2c6Elliott Hughes$(GEN): $(libc_crt_target_crtbegin_so_file) 6751dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project @mkdir -p $(dir $@) 676cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) \ 677cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.o=%.d) -o $@ -c $< 678cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(transform-d-to-p) 679cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.o=%.P) 6801dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectALL_GENERATED_SOURCES += $(GEN) 6811dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 682fc9e525fe07846c1efa23235a59575f8dad69c53Ying WangGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_so.o 683b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupin$(GEN): $(LOCAL_PATH)/arch-common/bionic/crtend_so.S 684ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin @mkdir -p $(dir $@) 685cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_so_cflags) \ 686cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.o=%.d) -o $@ -c $< 687cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(transform-d-to-p) 688cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.o=%.P) 689ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinALL_GENERATED_SOURCES += $(GEN) 690fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei Liao 691cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang# The following two are installed to device 692fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei LiaoGEN := $(TARGET_OUT_SHARED_LIBRARIES)/crtbegin_so.o 693cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_so.o 694cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) mkdir -p $(dir $@) && cp -f $< $@ 695fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei LiaoALL_GENERATED_SOURCES += $(GEN) 696fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei Liao 697fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei LiaoGEN := $(TARGET_OUT_SHARED_LIBRARIES)/crtend_so.o 698cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_so.o 699cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) mkdir -p $(dir $@) && cp -f $< $@ 700fc0725ec5cc51053c06bf2c67755a5a57a5da621Shih-wei LiaoALL_GENERATED_SOURCES += $(GEN) 7011dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 7021dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 703ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static1.o 70412949e5d3946cc5d5b53d52adf5a3b925bfca2c6Elliott Hughes$(GEN): $(libc_crt_target_crtbegin_file) 705ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin @mkdir -p $(dir $@) 706cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \ 707cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.o=%.d) -o $@ -c $< 708cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(transform-d-to-p) 709cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.o=%.P) 710ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinALL_GENERATED_SOURCES += $(GEN) 7111dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 712ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static.o 713ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_static1.o $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o 714ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope @mkdir -p $(dir $@) 715e85c1834248916d7d13891e602461d9be91dda28Pavel Chupin $(hide) $(TARGET_LD) $(libc_crt_target_ldflags) -r -o $@ $^ 716ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeALL_GENERATED_SOURCES += $(GEN) 717ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope 718ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic1.o 71912949e5d3946cc5d5b53d52adf5a3b925bfca2c6Elliott Hughes$(GEN): $(libc_crt_target_crtbegin_file) 7201dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project @mkdir -p $(dir $@) 721cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \ 722cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.o=%.d) -o $@ -c $< 723cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(transform-d-to-p) 724cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.o=%.P) 7251dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectALL_GENERATED_SOURCES += $(GEN) 7261dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 727ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic.o 728ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope$(GEN): $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbegin_dynamic1.o $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtbrand.o 729ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael Hope @mkdir -p $(dir $@) 730e85c1834248916d7d13891e602461d9be91dda28Pavel Chupin $(hide) $(TARGET_LD) $(libc_crt_target_ldflags) -r -o $@ $^ 731ea8fad11d980d55ebd2bcf2302f3f1f742b6351cMichael HopeALL_GENERATED_SOURCES += $(GEN) 732ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin 733ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# We rename crtend.o to crtend_android.o to avoid a 734ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# name clash between gcc and bionic. 735fc9e525fe07846c1efa23235a59575f8dad69c53Ying WangGEN := $(TARGET_OUT_INTERMEDIATE_LIBRARIES)/crtend_android.o 736b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupin$(GEN): $(LOCAL_PATH)/arch-common/bionic/crtend.S 7371dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project @mkdir -p $(dir $@) 738cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(hide) $(TARGET_CC) $(libc_crt_target_cflags) \ 739cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang -MD -MF $(@:%.o=%.d) -o $@ -c $< 740cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang $(transform-d-to-p) 741cf464878efda7652b0a7eb636e45944eda6b6f2fYing Wang-include $(GEN:%.o=%.P) 7421dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectALL_GENERATED_SOURCES += $(GEN) 7431dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 7441dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 745ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# To enable malloc leak check for statically linked programs, add 746ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# "WITH_MALLOC_CHECK_LIBC_A := true" to buildspec.mk 747ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinWITH_MALLOC_CHECK_LIBC_A := $(strip $(WITH_MALLOC_CHECK_LIBC_A)) 7481dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 749ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 7506334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# libbionic_ssp.a - stack protector code 7516334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# ======================================================== 7526334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# 7536334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# The stack protector code needs to be compiled 7546334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# with -fno-stack-protector, since it modifies the 7556334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# stack canary. 7566334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich 7576334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevichinclude $(CLEAR_VARS) 7586334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich 759642331b5dd5647e7d196ac4f44406fd435478a56Elliott HughesLOCAL_SRC_FILES := bionic/__stack_chk_fail.cpp 760dc5ec07158079b39f758ed41eca5b937e52c3729Elliott HughesLOCAL_CFLAGS := $(libc_common_cflags) -fno-stack-protector -Werror 761762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 762762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 7636334c662cae4cd9b61f5f3185048b0cd3633dad7Nick KralevichLOCAL_C_INCLUDES := $(libc_common_c_includes) 7646334c662cae4cd9b61f5f3185048b0cd3633dad7Nick KralevichLOCAL_MODULE := libbionic_ssp 765d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 7666334c662cae4cd9b61f5f3185048b0cd3633dad7Nick KralevichLOCAL_SYSTEM_SHARED_LIBRARIES := 7676334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich 7686334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevichinclude $(BUILD_STATIC_LIBRARY) 7696334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich 7706334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich 7716334c662cae4cd9b61f5f3185048b0cd3633dad7Nick Kralevich# ======================================================== 772ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes# libc_tzcode.a - upstream 'tzcode' code 773ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes# ======================================================== 774ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 775ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughesinclude $(CLEAR_VARS) 776ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 777ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_SRC_FILES := $(libc_tzcode_src_files) 778ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_CFLAGS := \ 779ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes $(libc_common_cflags) \ 780ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes -DSTD_INSPIRED=1 \ 781ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes -DTZDIR=\"/system/usr/share/zoneinfo\" \ 782ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes -DTM_GMTOFF=tm_gmtoff \ 783ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes -DUSG_COMPAT=1 784762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 785762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 786ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_C_INCLUDES := $(libc_common_c_includes) 787ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_MODULE := libc_tzcode 788d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 789ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_SYSTEM_SHARED_LIBRARIES := 790ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 791ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughesinclude $(BUILD_STATIC_LIBRARY) 792ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 793ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes 794ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes# ======================================================== 795eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes# libc_dns.a - modified NetBSD DNS code 796eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes# ======================================================== 797eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 798eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughesinclude $(CLEAR_VARS) 799eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 800eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_SRC_FILES := $(libc_dns_src_files) 801eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_CFLAGS := \ 802eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes $(libc_common_cflags) \ 803eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -DINET6 \ 804eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -I$(LOCAL_PATH)/private \ 805eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -I$(LOCAL_PATH)/upstream-netbsd/libc/include # for NetBSD private headers 806eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 807eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 808eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_CPPFLAGS := $(libc_common_cppflags) 809eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_C_INCLUDES := $(libc_common_c_includes) 810eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_MODULE := libc_dns 811eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 812eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_SYSTEM_SHARED_LIBRARIES := 813eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 814eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughesinclude $(BUILD_STATIC_LIBRARY) 815eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 816eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 817eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes# ======================================================== 818f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# libc_freebsd.a - upstream FreeBSD C library code 819f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# ======================================================== 820f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# 821f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# These files are built with the freebsd-compat.h header file 822f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# automatically included. 823f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 824f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughesinclude $(CLEAR_VARS) 825f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 826f0777843c03deb26b1f78c8edd17c557041696e9Elliott HughesLOCAL_SRC_FILES := $(libc_upstream_freebsd_src_files) 827f0777843c03deb26b1f78c8edd17c557041696e9Elliott HughesLOCAL_CFLAGS := \ 828f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes $(libc_common_cflags) \ 829f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes -I$(LOCAL_PATH)/upstream-freebsd \ 830f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes -I$(LOCAL_PATH)/upstream-freebsd/libc/include \ 831f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes -include upstream-freebsd/freebsd-compat.h 832762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 833762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 834f0777843c03deb26b1f78c8edd17c557041696e9Elliott HughesLOCAL_C_INCLUDES := $(libc_common_c_includes) 835f0777843c03deb26b1f78c8edd17c557041696e9Elliott HughesLOCAL_MODULE := libc_freebsd 836d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 837f0777843c03deb26b1f78c8edd17c557041696e9Elliott HughesLOCAL_SYSTEM_SHARED_LIBRARIES := 838f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 839f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughesinclude $(BUILD_STATIC_LIBRARY) 840f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 841f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes 842f0777843c03deb26b1f78c8edd17c557041696e9Elliott Hughes# ======================================================== 843f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# libc_netbsd.a - upstream NetBSD C library code 844f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# ======================================================== 845f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# 846f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# These files are built with the netbsd-compat.h header file 847f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# automatically included. 848f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 849f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughesinclude $(CLEAR_VARS) 850f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 851f8b3a920a895a53b207017249080087d562bd0d2Elliott HughesLOCAL_SRC_FILES := $(libc_upstream_netbsd_src_files) 852f8b3a920a895a53b207017249080087d562bd0d2Elliott HughesLOCAL_CFLAGS := \ 853f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes $(libc_common_cflags) \ 854eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes -DPOSIX_MISTAKE \ 8553d2d448af1b16923f5a329b49bb8e658dbad8a06Elliott Hughes -I$(LOCAL_PATH)/upstream-netbsd \ 856ab44f52202878cdf2bf22457aeae33ec24089556Elliott Hughes -I$(LOCAL_PATH)/upstream-netbsd/libc/include \ 857f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes -include upstream-netbsd/netbsd-compat.h 858762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 859762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 860f8b3a920a895a53b207017249080087d562bd0d2Elliott HughesLOCAL_C_INCLUDES := $(libc_common_c_includes) 861f8b3a920a895a53b207017249080087d562bd0d2Elliott HughesLOCAL_MODULE := libc_netbsd 862d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 863f8b3a920a895a53b207017249080087d562bd0d2Elliott HughesLOCAL_SYSTEM_SHARED_LIBRARIES := 864f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 865f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughesinclude $(BUILD_STATIC_LIBRARY) 866f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 867f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 868f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes# ======================================================== 86929c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes# libc_bionic.a - home-grown C library code 87029c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes# ======================================================== 87129c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes# 87229c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughesinclude $(CLEAR_VARS) 87329c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes 87429c7f0b4d18f812267c2194b85204e19e41d0387Elliott HughesLOCAL_SRC_FILES := $(libc_bionic_src_files) 87529c7f0b4d18f812267c2194b85204e19e41d0387Elliott HughesLOCAL_CFLAGS := $(libc_common_cflags) -Werror 876762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 877762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 87829c7f0b4d18f812267c2194b85204e19e41d0387Elliott HughesLOCAL_C_INCLUDES := $(libc_common_c_includes) 87929c7f0b4d18f812267c2194b85204e19e41d0387Elliott HughesLOCAL_MODULE := libc_bionic 880d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 88129c7f0b4d18f812267c2194b85204e19e41d0387Elliott HughesLOCAL_SYSTEM_SHARED_LIBRARIES := 88229c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes 88366759d6041b33706c3a92dde48492ba4f2bbab2fElliott Hughes# Set -DPTHREAD_DEBUG_ENABLED=true to enable support for pthread deadlock prediction. 88466759d6041b33706c3a92dde48492ba4f2bbab2fElliott Hughes# Since this code is experimental it is disabled by default. 88566759d6041b33706c3a92dde48492ba4f2bbab2fElliott HughesLOCAL_CFLAGS += $(libc_common_cflags) -DPTHREAD_DEBUG_ENABLED=false 88666759d6041b33706c3a92dde48492ba4f2bbab2fElliott Hughes 88729c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughesinclude $(BUILD_STATIC_LIBRARY) 88829c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes 88929c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes 89029c7f0b4d18f812267c2194b85204e19e41d0387Elliott Hughes# ======================================================== 891ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# libc_common.a 892ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 893f8b3a920a895a53b207017249080087d562bd0d2Elliott Hughes 894ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavininclude $(CLEAR_VARS) 8951dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 896ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinLOCAL_SRC_FILES := $(libc_common_src_files) 897eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott HughesLOCAL_CFLAGS := $(libc_common_cflags) 898762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 899762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 900ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinLOCAL_C_INCLUDES := $(libc_common_c_includes) 9011dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_MODULE := libc_common 902d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 903ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott HughesLOCAL_WHOLE_STATIC_LIBRARIES := \ 904ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes libbionic_ssp \ 905ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes libc_bionic \ 906eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes libc_dns \ 907ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes libc_freebsd \ 908ce4783ce76a4ef888466e02e4c6f3a0a3910bce8Elliott Hughes libc_netbsd \ 909eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes libc_tzcode \ 910eb847bc8666842a3cfc9c06e8458ad1abebebaf0Elliott Hughes 9111dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SYSTEM_SHARED_LIBRARIES := 9121dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 913c97c5fc7880267fd835d22946a920bf370461cf2Ying Wang# TODO: split out the asflags. 914c97c5fc7880267fd835d22946a920bf370461cf2Ying WangLOCAL_ASFLAGS := $(LOCAL_CFLAGS) 915c97c5fc7880267fd835d22946a920bf370461cf2Ying Wang 9161dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(BUILD_STATIC_LIBRARY) 9171dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 9181dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 919ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 92049e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin# libc_nomalloc.a 92149e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin# ======================================================== 92249e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin# 92349e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin# This is a version of the static C library that does not 92491a9925998f2b878f0245ce03aab22cc412a4d8bElliott Hughes# include malloc. It's useful in situations when the user wants 92591a9925998f2b878f0245ce03aab22cc412a4d8bElliott Hughes# to provide their own malloc implementation, or wants to 92691a9925998f2b878f0245ce03aab22cc412a4d8bElliott Hughes# explicitly disallow the use of the use of malloc, 92791a9925998f2b878f0245ce03aab22cc412a4d8bElliott Hughes# such as in the dynamic loader. 92849e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 92949e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavininclude $(CLEAR_VARS) 93049e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 93149e55332784b82f7112ee7c1ea3c176c9dc32d7aDima ZavinLOCAL_SRC_FILES := \ 93249e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin $(libc_arch_static_src_files) \ 9336a51defa034a1c033ed01f7de444c0a4fc615249David 'Digit' Turner $(libc_static_common_src_files) \ 93442b2c6a5eed5e4ef35315b8cd32d1355f12a69b6Elliott Hughes bionic/libc_init_static.cpp 93549e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 93649e55332784b82f7112ee7c1ea3c176c9dc32d7aDima ZavinLOCAL_C_INCLUDES := $(libc_common_c_includes) 9376a51defa034a1c033ed01f7de444c0a4fc615249David 'Digit' TurnerLOCAL_CFLAGS := $(libc_common_cflags) \ 938762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines -DLIBC_STATIC 939762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 940762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 94149e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 94249e55332784b82f7112ee7c1ea3c176c9dc32d7aDima ZavinLOCAL_MODULE := libc_nomalloc 943d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 94449e55332784b82f7112ee7c1ea3c176c9dc32d7aDima ZavinLOCAL_WHOLE_STATIC_LIBRARIES := libc_common 94549e55332784b82f7112ee7c1ea3c176c9dc32d7aDima ZavinLOCAL_SYSTEM_SHARED_LIBRARIES := 94649e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 94749e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavininclude $(BUILD_STATIC_LIBRARY) 94849e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 94949e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin 95049e55332784b82f7112ee7c1ea3c176c9dc32d7aDima Zavin# ======================================================== 9511dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# libc.a 9521dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# ======================================================== 9531dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(CLEAR_VARS) 9541dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 9551dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SRC_FILES := \ 956ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin $(libc_arch_static_src_files) \ 9576a51defa034a1c033ed01f7de444c0a4fc615249David 'Digit' Turner $(libc_static_common_src_files) \ 9581dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/dlmalloc.c \ 959c4d1fecc105063e68a5090a6900b63d1b9a24287Elliott Hughes bionic/malloc_debug_common.cpp \ 96042b2c6a5eed5e4ef35315b8cd32d1355f12a69b6Elliott Hughes bionic/libc_init_static.cpp 9611dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 962b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_CFLAGS := $(libc_common_cflags) \ 963762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen Hines -DLIBC_STATIC 964762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 965762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 9661dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_C_INCLUDES := $(libc_common_c_includes) 967ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinLOCAL_MODULE := libc 968d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 9691dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_WHOLE_STATIC_LIBRARIES := libc_common 9701dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SYSTEM_SHARED_LIBRARIES := 9711dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 9721dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(BUILD_STATIC_LIBRARY) 9731dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 9741dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 975ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 9761dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# libc.so 9771dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# ======================================================== 9781dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(CLEAR_VARS) 9791dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 98066759d6041b33706c3a92dde48492ba4f2bbab2fElliott HughesLOCAL_CFLAGS := $(libc_common_cflags) 981762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 982762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 9831dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_C_INCLUDES := $(libc_common_c_includes) 9841dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 9851dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SRC_FILES := \ 986ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin $(libc_arch_dynamic_src_files) \ 9876a51defa034a1c033ed01f7de444c0a4fc615249David 'Digit' Turner $(libc_static_common_src_files) \ 9881dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project bionic/dlmalloc.c \ 989c4d1fecc105063e68a5090a6900b63d1b9a24287Elliott Hughes bionic/malloc_debug_common.cpp \ 9901e980b6bc8315d00a07312b25486531247abd98cElliott Hughes bionic/pthread_debug.cpp \ 99142b2c6a5eed5e4ef35315b8cd32d1355f12a69b6Elliott Hughes bionic/libc_init_dynamic.cpp 9921dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 993f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvelifeq ($(TARGET_ARCH),arm) 994f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel LOCAL_NO_CRT := true 995f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel LOCAL_CFLAGS += -DCRT_LEGACY_WORKAROUND 996f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel 997f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel LOCAL_SRC_FILES := \ 998b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupin arch-common/bionic/crtbegin_so.c \ 999f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel arch-arm/bionic/atexit_legacy.c \ 1000f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel $(LOCAL_SRC_FILES) \ 1001b49c17c2bf1232e29bc390e58d6fa43688929aa5Pavel Chupin arch-common/bionic/crtend_so.S 1002f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvelendif 1003f3cfcd869ded41d25c1f4f4e48e7c374a64f9583Ard Biesheuvel 10041dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_MODULE:= libc 1005d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 1006914d8d4cff10f023ccd382fb43b2c7833dd34f72Elliott HughesLOCAL_REQUIRED_MODULES := tzdata 10071dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10081dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# WARNING: The only library libc.so should depend on is libdl.so! If you add other libraries, 10091dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# make sure to add -Wl,--exclude-libs=libgcc.a to the LOCAL_LDFLAGS for those libraries. This 10101dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# ensures that symbols that are pulled into those new libraries from libgcc.a are not declared 10111dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# external; if that were the case, then libc would not pull those symbols from libgcc.a as it 10121dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# should, instead relying on the external symbols from the dependent libraries. That would 10131dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# create an "cloaked" dependency on libgcc.a in libc though the libraries, which is not what 10141dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# you wanted! 10151dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10161dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SHARED_LIBRARIES := libdl 10171dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_WHOLE_STATIC_LIBRARIES := libc_common 10181dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SYSTEM_SHARED_LIBRARIES := 10191dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10201dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(BUILD_SHARED_LIBRARY) 10211dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10221dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1023b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# For all builds, except for the -user build we will enable memory 1024b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# allocation checking (including memory leaks, buffer overwrites, etc.) 1025b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# Note that all these checks are also controlled by env. settings 1026b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# that can enable, or disable specific checks. Note also that some of 1027b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# the checks are available only in emulator and are implemeted in 1028b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# libc_malloc_qemu_instrumented.so. 1029b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkineifneq ($(TARGET_BUILD_VARIANT),user) 1030b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1031ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin# ======================================================== 1032b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# libc_malloc_debug_leak.so 10331dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# ======================================================== 10341dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(CLEAR_VARS) 10351dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1036ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima ZavinLOCAL_CFLAGS := \ 1037ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin $(libc_common_cflags) \ 1038ca122b0e34df0e8c485be0d3ab1b80f728b76276Dima Zavin -DMALLOC_LEAK_CHECK 1039762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 1040762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 10411dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10421dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_C_INCLUDES := $(libc_common_c_includes) 10431dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10441dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SRC_FILES := \ 10451e980b6bc8315d00a07312b25486531247abd98cElliott Hughes bionic/debug_mapinfo.cpp \ 10461e980b6bc8315d00a07312b25486531247abd98cElliott Hughes bionic/debug_stacktrace.cpp \ 1047c4d1fecc105063e68a5090a6900b63d1b9a24287Elliott Hughes bionic/malloc_debug_leak.cpp \ 1048c4d1fecc105063e68a5090a6900b63d1b9a24287Elliott Hughes bionic/malloc_debug_check.cpp \ 10491dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1050b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_MODULE:= libc_malloc_debug_leak 1051d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 10521dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1053e007775f4b21f6b94078ed1d34b753435ba28fdaPavel ChupinLOCAL_SHARED_LIBRARIES := libc libdl 1054b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_WHOLE_STATIC_LIBRARIES := libc_common 1055b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_SYSTEM_SHARED_LIBRARIES := 1056aa46fa24035f3ab020f9a7abd86c25ae2196bb32Bruce BeareLOCAL_ALLOW_UNDEFINED_SYMBOLS := true 1057368070454b1349d1fcf29a5d1eb51c869fb538f6Iliyan Malchev 1058b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# Don't install on release build 1059b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_MODULE_TAGS := eng debug 10601dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1061b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkineinclude $(BUILD_SHARED_LIBRARY) 1062b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1063b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1064b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# ======================================================== 1065b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# libc_malloc_debug_qemu.so 1066b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine# ======================================================== 1067b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkineinclude $(CLEAR_VARS) 1068b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1069b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_CFLAGS := \ 1070b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine $(libc_common_cflags) \ 1071b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine -DMALLOC_QEMU_INSTRUMENT 1072762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CONLYFLAGS := $(libc_common_conlyflags) 1073762cea46f070e25b33de6f36a54fb7c293f0fee5Stephen HinesLOCAL_CPPFLAGS := $(libc_common_cppflags) 1074b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1075b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_C_INCLUDES := $(libc_common_c_includes) 1076b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1077b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_SRC_FILES := \ 1078c4d1fecc105063e68a5090a6900b63d1b9a24287Elliott Hughes bionic/malloc_debug_qemu.cpp 1079b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1080b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_MODULE:= libc_malloc_debug_qemu 1081d7a632948d5b3128cc536a2c4db3124b4fa57a80Christopher FerrisLOCAL_ADDITIONAL_DEPENDENCIES := $(libc_common_additional_dependencies) 1082b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 10837c0c3793722aea293c45921ef50e4adcdf9645ceMathias AgopianLOCAL_SHARED_LIBRARIES := libc libdl 10841dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_WHOLE_STATIC_LIBRARIES := libc_common 10851dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source ProjectLOCAL_SYSTEM_SHARED_LIBRARIES := 1086368070454b1349d1fcf29a5d1eb51c869fb538f6Iliyan Malchev 10871dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# Don't install on release build 1088b74ceb25aae555570df64fa4d4076272733a9a20Vladimir ChtchetkineLOCAL_MODULE_TAGS := eng debug 10891dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 10901dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(BUILD_SHARED_LIBRARY) 10911dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project 1092b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkineendif #!user 1093b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 1094b74ceb25aae555570df64fa4d4076272733a9a20Vladimir Chtchetkine 10951dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Project# ======================================================== 10961dc9e472e19acfe6dc7f41e429236e7eef7ceda1The Android Open Source Projectinclude $(call all-makefiles-under,$(LOCAL_PATH)) 1097