blob: 693a612a7c9b2629c90a9951d2e7afd0c448715b [file] [log] [blame]
Ethan Yonkerc798c9c2015-10-09 11:15:26 -05001LOCAL_PATH:= system/core/libpixelflinger
2include $(CLEAR_VARS)
3
4#
5# C/C++ and ARMv5 objects
6#
7
8include $(CLEAR_VARS)
9
10ifneq ($(wildcard system/core/libpixelflinger/codeflinger/x86/X86Assembler.cpp),)
11 ifeq ($(TARGET_ARCH),x86)
12 TW_HAVE_X86_ACCELERATED_PIXELFLINGER := true
13 endif
14endif
15
16PIXELFLINGER_SRC_FILES += \
17 codeflinger/CodeCache.cpp \
18 codeflinger/tinyutils/SharedBuffer.cpp \
19 codeflinger/tinyutils/VectorImpl.cpp \
20 format.cpp \
21 clear.cpp \
22 raster.cpp \
23 buffer.cpp
24
25ifneq ($(TW_HAVE_X86_ACCELERATED_PIXELFLINGER),true)
26PIXELFLINGER_SRC_FILES += \
27 codeflinger/ARMAssemblerInterface.cpp \
28 codeflinger/ARMAssemblerProxy.cpp \
29 codeflinger/GGLAssembler.cpp \
30 codeflinger/load_store.cpp \
31 codeflinger/blending.cpp \
32 codeflinger/texturing.cpp \
33 fixed.cpp.arm \
34 picker.cpp.arm \
35 pixelflinger.cpp.arm \
36 trap.cpp.arm \
37 scanline.cpp.arm
38else
39PIXELFLINGER_SRC_FILES_x86 := \
40 codeflinger/x86/X86Assembler.cpp \
41 codeflinger/x86/GGLX86Assembler.cpp \
42 codeflinger/x86/load_store.cpp \
43 codeflinger/x86/blending.cpp \
44 codeflinger/x86/texturing.cpp \
45 fixed.cpp \
46 picker.cpp \
47 pixelflinger.cpp \
48 trap.cpp \
49 scanline.cpp
50
51PIXELFLINGER_C_INCLUDES_x86 := \
52 external/libenc
53
54endif
55
56PIXELFLINGER_CFLAGS := -fstrict-aliasing -fomit-frame-pointer
57
58PIXELFLINGER_SRC_FILES_arm := \
59 codeflinger/ARMAssembler.cpp \
60 codeflinger/disassem.c \
61 col32cb16blend.S \
62 t32cb16blend.S \
63
64ifeq ($(ARCH_ARM_HAVE_NEON),true)
65PIXELFLINGER_SRC_FILES_arm += col32cb16blend_neon.S
66PIXELFLINGER_CFLAGS_arm += -D__ARM_HAVE_NEON
67endif
68
69PIXELFLINGER_SRC_FILES_arm64 := \
70 codeflinger/Arm64Assembler.cpp \
71 codeflinger/Arm64Disassembler.cpp \
72 arch-arm64/col32cb16blend.S \
73 arch-arm64/t32cb16blend.S \
74
75ifndef ARCH_MIPS_REV6
76PIXELFLINGER_SRC_FILES_mips := \
77 codeflinger/MIPSAssembler.cpp \
78 codeflinger/mips_disassem.c \
79 arch-mips/t32cb16blend.S \
80
81endif
82
83#
84# Static library version
85#
86
87include $(CLEAR_VARS)
88LOCAL_MODULE:= libpixelflinger_twrp
89LOCAL_SRC_FILES := $(PIXELFLINGER_SRC_FILES)
90LOCAL_SRC_FILES_arm := $(PIXELFLINGER_SRC_FILES_arm)
91LOCAL_SRC_FILES_arm64 := $(PIXELFLINGER_SRC_FILES_arm64)
92LOCAL_SRC_FILES_x86 := $(PIXELFLINGER_SRC_FILES_x86)
93LOCAL_SRC_FILES_mips := $(PIXELFLINGER_SRC_FILES_mips)
that05791142015-10-10 15:59:22 +020094ifneq ($(shell test $(PLATFORM_SDK_VERSION) -gt 22; echo $$?),0)
95 LOCAL_SRC_FILES += $(LOCAL_SRC_FILES_$(TARGET_ARCH))
96endif
Ethan Yonkerc798c9c2015-10-09 11:15:26 -050097LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include
98LOCAL_C_INCLUDES += $(LOCAL_EXPORT_C_INCLUDE_DIRS)
99LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
100LOCAL_C_INCLUDES_x86 := $(PIXELFLINGER_C_INCLUDES_x86)
101ifeq ($(TW_HAVE_X86_ACCELERATED_PIXELFLINGER),true)
102LOCAL_WHOLE_STATIC_LIBRARIES += libenc
103LOCAL_C_INCLUDES += external/libenc
104endif
105include $(BUILD_STATIC_LIBRARY)