Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 1 | # 32-bit x86. |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 2 | |
Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 3 | # |
| 4 | # Various kinds of LP32 cruft. |
| 5 | # |
| 6 | |
| 7 | libc_bionic_src_files_x86 += \ |
| 8 | bionic/mmap.cpp \ |
| 9 | |
| 10 | libc_common_src_files_x86 += \ |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 11 | bionic/legacy_32_bit_support.cpp \ |
| 12 | bionic/ndk_cruft.cpp \ |
Elliott Hughes | 8d77bce | 2014-04-22 13:55:58 -0700 | [diff] [blame] | 13 | bionic/time64.c \ |
Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 14 | |
| 15 | libc_netbsd_src_files_x86 += \ |
| 16 | upstream-netbsd/common/lib/libc/hash/sha1/sha1.c \ |
| 17 | |
| 18 | libc_openbsd_src_files_x86 += \ |
Dan Albert | 8e613cf | 2014-06-11 14:17:35 -0700 | [diff] [blame] | 19 | upstream-openbsd/lib/libc/stdio/putw.c \ |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 20 | |
Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 21 | # |
| 22 | # Default implementations of functions that are commonly optimized. |
| 23 | # |
| 24 | |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 25 | libc_common_src_files_x86 += \ |
| 26 | bionic/__memcpy_chk.cpp \ |
| 27 | bionic/__memset_chk.cpp \ |
| 28 | bionic/__strcpy_chk.cpp \ |
| 29 | bionic/__strcat_chk.cpp \ |
Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 30 | |
| 31 | libc_freebsd_src_files_x86 += \ |
Bernhard Rosenkraenzer | 6f2bde3 | 2014-05-23 17:44:18 +0200 | [diff] [blame] | 32 | upstream-freebsd/lib/libc/string/wmemmove.c \ |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 33 | |
Elliott Hughes | 7c02d94 | 2014-09-16 19:06:31 -0700 | [diff] [blame] | 34 | # |
| 35 | # Inherently architecture-specific functions. |
| 36 | # |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 37 | |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 38 | libc_bionic_src_files_x86 += \ |
Elliott Hughes | 36d6188 | 2013-11-19 13:31:58 -0800 | [diff] [blame] | 39 | arch-x86/bionic/__bionic_clone.S \ |
Christopher Ferris | 04954a4 | 2013-02-26 01:30:00 -0800 | [diff] [blame] | 40 | arch-x86/bionic/_exit_with_stack_teardown.S \ |
Christopher Ferris | 6869d26 | 2014-10-06 15:11:28 -0700 | [diff] [blame^] | 41 | arch-x86/bionic/libgcc_compat.c \ |
Elliott Hughes | 36f451a | 2014-09-10 15:20:40 -0700 | [diff] [blame] | 42 | arch-x86/bionic/__restore_rt.S \ |
| 43 | arch-x86/bionic/__restore.S \ |
Christopher Ferris | 04954a4 | 2013-02-26 01:30:00 -0800 | [diff] [blame] | 44 | arch-x86/bionic/_setjmp.S \ |
| 45 | arch-x86/bionic/setjmp.S \ |
| 46 | arch-x86/bionic/__set_tls.c \ |
| 47 | arch-x86/bionic/sigsetjmp.S \ |
| 48 | arch-x86/bionic/syscall.S \ |
Dan Albert | 6a91887 | 2014-08-05 20:53:31 +0000 | [diff] [blame] | 49 | arch-x86/bionic/vfork.S \ |
Liubov Dmitrieva | 0a49066 | 2012-01-17 12:55:46 +0400 | [diff] [blame] | 50 | |
Varvara Rainchik | 5a92284 | 2014-04-24 15:41:20 +0400 | [diff] [blame] | 51 | ## ARCH variant specific source files |
| 52 | arch_variant_mk := $(LOCAL_PATH)/arch-x86/$(TARGET_ARCH_VARIANT)/$(TARGET_ARCH_VARIANT).mk |
| 53 | ifeq ($(wildcard $(arch_variant_mk)),) |
| 54 | arch_variant_mk := $(LOCAL_PATH)/arch-x86/generic/generic.mk |
Liubov Dmitrieva | 0a49066 | 2012-01-17 12:55:46 +0400 | [diff] [blame] | 55 | endif |
Varvara Rainchik | 5a92284 | 2014-04-24 15:41:20 +0400 | [diff] [blame] | 56 | include $(arch_variant_mk) |
| 57 | libc_common_additional_dependencies += $(arch_variant_mk) |
Liubov Dmitrieva | 0a49066 | 2012-01-17 12:55:46 +0400 | [diff] [blame] | 58 | |
Varvara Rainchik | 5a92284 | 2014-04-24 15:41:20 +0400 | [diff] [blame] | 59 | arch_variant_mk := |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 60 | |
Ying Wang | f25d677 | 2014-01-23 15:17:50 -0800 | [diff] [blame] | 61 | libc_crt_target_cflags_x86 := \ |
| 62 | -m32 \ |
| 63 | -I$(LOCAL_PATH)/arch-x86/include |
| 64 | |
| 65 | libc_crt_target_ldflags_x86 := -melf_i386 |
| 66 | |
| 67 | libc_crt_target_crtbegin_file_x86 := \ |
| 68 | $(LOCAL_PATH)/arch-common/bionic/crtbegin.c |
| 69 | |
| 70 | libc_crt_target_crtbegin_so_file_x86 := \ |
| 71 | $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c |
| 72 | |
| 73 | libc_crt_target_so_cflags_x86 := \ |
| 74 | -fPIC |