x86.mk revision 6f2bde344123d8503cd60f3ecd3420f39aa24eb9
1# x86 specific configs
2
3# These are shared by all the 32-bit targets, but not the 64-bit ones.
4libc_common_src_files_x86 := \
5    bionic/legacy_32_bit_support.cpp \
6    bionic/ndk_cruft.cpp \
7    bionic/time64.c \
8
9# Fortify implementations of libc functions.
10libc_common_src_files_x86 += \
11    bionic/__memcpy_chk.cpp \
12    bionic/__memset_chk.cpp \
13    bionic/__strcpy_chk.cpp \
14    bionic/__strcat_chk.cpp \
15    upstream-freebsd/lib/libc/string/wmemmove.c \
16
17
18# These are shared by all the 32-bit targets, but not the 64-bit ones.
19libc_bionic_src_files_x86 := \
20    bionic/mmap.cpp
21
22##########################################
23### CPU specific source files
24libc_bionic_src_files_x86 += \
25    arch-x86/bionic/__bionic_clone.S \
26    arch-x86/bionic/_exit_with_stack_teardown.S \
27    arch-x86/bionic/__get_sp.S \
28    arch-x86/bionic/_setjmp.S \
29    arch-x86/bionic/setjmp.S \
30    arch-x86/bionic/__set_tls.c \
31    arch-x86/bionic/sigsetjmp.S \
32    arch-x86/bionic/syscall.S \
33    arch-x86/bionic/vfork.S \
34
35## ARCH variant specific source files
36arch_variant_mk := $(LOCAL_PATH)/arch-x86/$(TARGET_ARCH_VARIANT)/$(TARGET_ARCH_VARIANT).mk
37ifeq ($(wildcard $(arch_variant_mk)),)
38    arch_variant_mk := $(LOCAL_PATH)/arch-x86/generic/generic.mk
39endif
40include $(arch_variant_mk)
41libc_common_additional_dependencies += $(arch_variant_mk)
42
43arch_variant_mk :=
44
45libc_crt_target_cflags_x86 := \
46    -m32 \
47    -I$(LOCAL_PATH)/arch-x86/include
48
49libc_crt_target_ldflags_x86 := -melf_i386
50
51libc_crt_target_crtbegin_file_x86 := \
52     $(LOCAL_PATH)/arch-common/bionic/crtbegin.c
53
54libc_crt_target_crtbegin_so_file_x86 := \
55    $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c
56
57libc_crt_target_so_cflags_x86 := \
58    -fPIC
59