blob: 05e71985479f492a119f96348fba92f869d1234b [file] [log] [blame]
Elliott Hughes7c02d942014-09-16 19:06:31 -07001# 32-bit mips.
Ying Wangf25d6772014-01-23 15:17:50 -08002
Elliott Hughes7c02d942014-09-16 19:06:31 -07003#
Elliott Hughes7c02d942014-09-16 19:06:31 -07004# Default implementations of functions that are commonly optimized.
5#
Ying Wangf25d6772014-01-23 15:17:50 -08006
Elliott Hughes7c02d942014-09-16 19:06:31 -07007libc_bionic_src_files_mips += \
Elliott Hughese6099092015-01-27 11:09:27 -08008 arch-mips/string/memcmp.c \
Nikola Veljkovic38f2eaa2015-05-26 12:06:09 +02009 arch-mips/string/memcpy.S \
10 arch-mips/string/memset.S \
11 arch-mips/string/strcmp.S \
Elliott Hughes7c02d942014-09-16 19:06:31 -070012 bionic/__memcpy_chk.cpp \
13 bionic/__memset_chk.cpp \
14 bionic/__strcpy_chk.cpp \
15 bionic/__strcat_chk.cpp \
Ying Wangf25d6772014-01-23 15:17:50 -080016 bionic/strchr.cpp \
17 bionic/strnlen.c \
Elliott Hughes53e43292014-02-24 18:00:43 -080018 bionic/strrchr.cpp \
Elliott Hughes7c02d942014-09-16 19:06:31 -070019
20libc_freebsd_src_files_mips += \
Ying Wangf25d6772014-01-23 15:17:50 -080021 upstream-freebsd/lib/libc/string/wcscat.c \
22 upstream-freebsd/lib/libc/string/wcschr.c \
23 upstream-freebsd/lib/libc/string/wcscmp.c \
24 upstream-freebsd/lib/libc/string/wcscpy.c \
25 upstream-freebsd/lib/libc/string/wcslen.c \
26 upstream-freebsd/lib/libc/string/wcsrchr.c \
27 upstream-freebsd/lib/libc/string/wmemcmp.c \
Bernhard Rosenkraenzer6f2bde32014-05-23 17:44:18 +020028 upstream-freebsd/lib/libc/string/wmemmove.c \
Elliott Hughes7c02d942014-09-16 19:06:31 -070029
30libc_openbsd_src_files_mips += \
Elliott Hughes41ef9022015-02-14 13:21:22 -080031 upstream-openbsd/lib/libc/string/memchr.c \
Elliott Hughes76f89162015-01-26 13:34:58 -080032 upstream-openbsd/lib/libc/string/memmove.c \
Elliott Hughes41ef9022015-02-14 13:21:22 -080033 upstream-openbsd/lib/libc/string/memrchr.c \
Varvara Rainchik5a922842014-04-24 15:41:20 +040034 upstream-openbsd/lib/libc/string/stpcpy.c \
35 upstream-openbsd/lib/libc/string/stpncpy.c \
Elliott Hughes53e43292014-02-24 18:00:43 -080036 upstream-openbsd/lib/libc/string/strcat.c \
Elliott Hughes53e43292014-02-24 18:00:43 -080037 upstream-openbsd/lib/libc/string/strcpy.c \
38 upstream-openbsd/lib/libc/string/strlcat.c \
39 upstream-openbsd/lib/libc/string/strlcpy.c \
40 upstream-openbsd/lib/libc/string/strncat.c \
41 upstream-openbsd/lib/libc/string/strncmp.c \
42 upstream-openbsd/lib/libc/string/strncpy.c \
Ying Wangf25d6772014-01-23 15:17:50 -080043
Elliott Hughes7c02d942014-09-16 19:06:31 -070044#
45# Inherently architecture-specific code.
46#
Ying Wangf25d6772014-01-23 15:17:50 -080047
Ying Wangf25d6772014-01-23 15:17:50 -080048libc_bionic_src_files_mips += \
Elliott Hughes36d61882013-11-19 13:31:58 -080049 arch-mips/bionic/__bionic_clone.S \
Christopher Ferris7c83a1e2013-02-26 01:30:00 -080050 arch-mips/bionic/bzero.S \
Elliott Hughes14b467e2013-10-09 16:40:33 -070051 arch-mips/bionic/cacheflush.cpp \
Elliott Hughesbf425682013-10-24 16:29:40 -070052 arch-mips/bionic/_exit_with_stack_teardown.S \
Christopher Ferris7c83a1e2013-02-26 01:30:00 -080053 arch-mips/bionic/setjmp.S \
Chris Dearmaneffaa782013-11-13 14:15:31 -080054 arch-mips/bionic/syscall.S \
Dan Albert6a918872014-08-05 20:53:31 +000055 arch-mips/bionic/vfork.S \
Duane Sandbc5a3ec2014-07-10 15:24:27 -070056
57ifndef ARCH_MIPS_REV6
58libc_bionic_src_files_mips += \
Christopher Ferris7c83a1e2013-02-26 01:30:00 -080059 arch-mips/string/mips_strlen.c \
Ying Wangf25d6772014-01-23 15:17:50 -080060
Duane Sandbc5a3ec2014-07-10 15:24:27 -070061else
62libc_bionic_src_files_mips += \
Elliott Hughese6099092015-01-27 11:09:27 -080063 arch-mips/string/strlen.c \
Elliott Hughes7c02d942014-09-16 19:06:31 -070064
65endif
Ying Wangf25d6772014-01-23 15:17:50 -080066
Ying Wangf25d6772014-01-23 15:17:50 -080067libc_crt_target_cflags_mips := \
68 $($(my_2nd_arch_prefix)TARGET_GLOBAL_CFLAGS) \
69 -I$(LOCAL_PATH)/arch-mips/include
70
71libc_crt_target_crtbegin_file_mips := \
72 $(LOCAL_PATH)/arch-mips/bionic/crtbegin.c
73
74libc_crt_target_crtbegin_so_file_mips := \
75 $(LOCAL_PATH)/arch-common/bionic/crtbegin_so.c
76
77libc_crt_target_so_cflags_mips := \
78 -fPIC
Duane Sandf5416502014-07-16 12:29:34 -070079
80libc_crt_target_ldflags_mips := \
81 -melf32ltsmip