blob: d464c770762ea166b54c6781c4600392a8f3f5d3 [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)
94LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)/include
95LOCAL_C_INCLUDES += $(LOCAL_EXPORT_C_INCLUDE_DIRS)
96LOCAL_CFLAGS := $(PIXELFLINGER_CFLAGS)
97LOCAL_C_INCLUDES_x86 := $(PIXELFLINGER_C_INCLUDES_x86)
98ifeq ($(TW_HAVE_X86_ACCELERATED_PIXELFLINGER),true)
99LOCAL_WHOLE_STATIC_LIBRARIES += libenc
100LOCAL_C_INCLUDES += external/libenc
101endif
102include $(BUILD_STATIC_LIBRARY)