x86.mk revision fd0ce866ce46ed62aa17dc2959a085cb3bf5755d
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
16
17# These are shared by all the 32-bit targets, but not the 64-bit ones.
18libc_bionic_src_files_x86 := \
19    bionic/mmap.cpp
20
21##########################################
22### CPU specific source files
23libc_bionic_src_files_x86 += \
24    arch-x86/bionic/__bionic_clone.S \
25    arch-x86/bionic/_exit_with_stack_teardown.S \
26    arch-x86/bionic/__get_sp.S \
27    arch-x86/bionic/_setjmp.S \
28    arch-x86/bionic/setjmp.S \
29    arch-x86/bionic/__set_tls.c \
30    arch-x86/bionic/sigsetjmp.S \
31    arch-x86/bionic/syscall.S \
32    arch-x86/bionic/vfork.S \
33
34## ARCH variant specific source files
35arch_variant_mk := $(LOCAL_PATH)/arch-x86/$(TARGET_ARCH_VARIANT)/$(TARGET_ARCH_VARIANT).mk
36ifeq ($(wildcard $(arch_variant_mk)),)
37    arch_variant_mk := $(LOCAL_PATH)/arch-x86/generic/generic.mk
38endif
39include $(arch_variant_mk)
40libc_common_additional_dependencies += $(arch_variant_mk)
41
42arch_variant_mk :=
43
44libc_crt_target_cflags_x86 := \
45    -m32 \
46    -I$(LOCAL_PATH)/arch-x86/include
47
48libc_crt_target_ldflags_x86 := -melf_i386
49
50libc_crt_target_crtbegin_file_x86 := \
51     $(LOCAL_PATH)/arch-common/bionic/crtbegin.c
52
53libc_crt_target_crtbegin_so_file_x86 := \
54    $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c
55
56libc_crt_target_so_cflags_x86 := \
57    -fPIC
58