diff --git a/libm/Android.mk b/libm/Android.mk index ce98236d7..64a40e4fa 100644 --- a/libm/Android.mk +++ b/libm/Android.mk @@ -225,22 +225,6 @@ libm_common_cflags := \ libm_common_includes := $(LOCAL_PATH)/upstream-freebsd/lib/msun/src/ -libm_arm_includes := $(LOCAL_PATH)/arm -libm_arm_src_files := arm/fenv.c - -libm_arm64_includes := $(LOCAL_PATH)/arm64 -libm_arm64_src_files := arm64/fenv.c - -libm_x86_includes := $(LOCAL_PATH)/i386 $(LOCAL_PATH)/i387 -libm_x86_src_files := i387/fenv.c - -libm_x86_64_includes := $(LOCAL_PATH)/amd64 -libm_x86_64_src_files := amd64/fenv.c - -libm_mips_cflags := -fno-builtin-rintf -fno-builtin-rint -libm_mips_includes := $(LOCAL_PATH)/mips -libm_mips_src_files := mips/fenv.c - # # libm.a for target. # @@ -248,10 +232,28 @@ include $(CLEAR_VARS) LOCAL_MODULE:= libm LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk LOCAL_ARM_MODE := arm -LOCAL_CFLAGS := $(libm_common_cflags) $(libm_$(TARGET_ARCH)_cflags) -LOCAL_C_INCLUDES += $(libm_common_includes) $(libm_$(TARGET_ARCH)_includes) -LOCAL_SRC_FILES := $(libm_common_src_files) $(libm_$(TARGET_ARCH)_src_files) +LOCAL_CFLAGS := $(libm_common_cflags) +LOCAL_C_INCLUDES += $(libm_common_includes) +LOCAL_SRC_FILES := $(libm_common_src_files) LOCAL_SYSTEM_SHARED_LIBRARIES := libc + +# arch-specific settings +LOCAL_C_INCLUDES_arm := $(LOCAL_PATH)/arm +LOCAL_SRC_FILES_arm := arm/fenv.c + +LOCAL_C_INCLUDES_arm64 := $(LOCAL_PATH)/arm64 +LOCAL_SRC_FILES_arm64 := arm64/fenv.c + +LOCAL_C_INCLUDES_x86 := $(LOCAL_PATH)/i386 $(LOCAL_PATH)/i387 +LOCAL_SRC_FILES_x86 := i387/fenv.c + +LOCAL_C_INCLUDES_x86_64 := $(LOCAL_PATH)/amd64 +LOCAL_SRC_FILES_x86_64 := amd64/fenv.c + +LOCAL_CFLAGS_mips := -fno-builtin-rintf -fno-builtin-rint +LOCAL_C_INCLUDES_mips := $(LOCAL_PATH)/mips +LOCAL_SRC_FILES_mips := mips/fenv.c + include $(BUILD_STATIC_LIBRARY) #