1LOCAL_PATH := $(call my-dir)
2include $(CLEAR_VARS)
3include $(LOCAL_PATH)/../../../common.mk
4
5ifeq ($(use_hwc2),true)
6
7LOCAL_MODULE                  := hwcomposer.$(TARGET_BOARD_PLATFORM)
8LOCAL_VENDOR_MODULE           := true
9LOCAL_MODULE_RELATIVE_PATH    := hw
10LOCAL_MODULE_TAGS             := optional
11LOCAL_C_INCLUDES              := $(common_includes)
12LOCAL_HEADER_LIBRARIES        := display_headers
13
14LOCAL_CFLAGS                  := -Wno-missing-field-initializers -Wno-unused-parameter \
15                                 -fcolor-diagnostics\
16                                 -DLOG_TAG=\"SDM\" $(common_flags)
17LOCAL_CLANG                   := true
18
19LOCAL_SHARED_LIBRARIES        := libsdmcore libqservice libbinder libhardware libhardware_legacy \
20                                 libutils libcutils libsync libqdutils libqdMetaData \
21                                 libsdmutils libc++ liblog libgrallocutils libui libgpu_tonemapper \
22                                 libhidlbase vendor.display.config@1.0 \
23                                 android.hardware.graphics.mapper@2.0 \
24                                 android.hardware.graphics.mapper@2.1 \
25                                 android.hardware.graphics.composer@2.2 \
26                                 android.hardware.graphics.composer@2.3 \
27                                 android.hardware.graphics.allocator@2.0 \
28                                 libdisplaydebug \
29                                 hardware.google.light@1.0 \
30                                 libdrm.vendor \
31
32LOCAL_STATIC_LIBRARIES        := libhistogram
33
34ifeq ($(display_config_version), DISPLAY_CONFIG_1_1)
35LOCAL_SHARED_LIBRARIES        += vendor.display.config@1.1
36endif
37ifeq ($(display_config_version), DISPLAY_CONFIG_1_2)
38LOCAL_SHARED_LIBRARIES        += vendor.display.config@1.2 vendor.display.config@1.1
39endif
40ifeq ($(display_config_version), DISPLAY_CONFIG_1_3)
41LOCAL_SHARED_LIBRARIES        += vendor.display.config@1.1
42LOCAL_SHARED_LIBRARIES        += vendor.display.config@1.2
43LOCAL_SHARED_LIBRARIES        += vendor.display.config@1.3
44endif
45
46# Allow implicit fallthroughs in hwc_display.cpp until they are fixed.
47LOCAL_CFLAGS                  += -Wno-error=implicit-fallthrough
48
49LOCAL_SRC_FILES               := hwc_session.cpp \
50                                 hwc_session_services.cpp \
51                                 hwc_display.cpp \
52                                 hwc_display_primary.cpp \
53                                 hwc_display_external.cpp \
54                                 hwc_display_virtual.cpp \
55                                 hwc_debugger.cpp \
56                                 hwc_buffer_sync_handler.cpp \
57                                 hwc_color_manager.cpp \
58                                 hwc_layers.cpp \
59                                 hwc_callbacks.cpp \
60                                 cpuhint.cpp \
61                                 hwc_tonemapper.cpp \
62                                 display_null.cpp \
63                                 hwc_socket_handler.cpp \
64                                 hwc_buffer_allocator.cpp \
65                                 hwc_display_external_test.cpp
66
67include $(BUILD_SHARED_LIBRARY)
68endif
69