1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184
|
LOCAL_PATH := $(call my-dir)
include $(CLEAR_VARS)
LOCAL_CLANG := true
LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
LOCAL_SRC_FILES := \
Client.cpp \
DisplayDevice.cpp \
DispSync.cpp \
EventControlThread.cpp \
StartPropertySetThread.cpp \
EventThread.cpp \
FrameTracker.cpp \
GpuService.cpp \
Layer.cpp \
LayerDim.cpp \
LayerRejecter.cpp \
LayerVector.cpp \
MessageQueue.cpp \
MonitoredProducer.cpp \
SurfaceFlingerConsumer.cpp \
SurfaceInterceptor.cpp \
Transform.cpp \
DisplayHardware/ComposerHal.cpp \
DisplayHardware/FramebufferSurface.cpp \
DisplayHardware/HWC2.cpp \
DisplayHardware/HWComposerBufferCache.cpp \
DisplayHardware/PowerHAL.cpp \
DisplayHardware/VirtualDisplaySurface.cpp \
Effects/Daltonizer.cpp \
EventLog/EventLogTags.logtags \
EventLog/EventLog.cpp \
RenderEngine/Description.cpp \
RenderEngine/Mesh.cpp \
RenderEngine/Program.cpp \
RenderEngine/ProgramCache.cpp \
RenderEngine/GLExtensions.cpp \
RenderEngine/RenderEngine.cpp \
RenderEngine/Texture.cpp \
RenderEngine/GLES20RenderEngine.cpp \
LOCAL_MODULE := libsurfaceflinger
LOCAL_C_INCLUDES := \
frameworks/native/vulkan/include \
external/vulkan-validation-layers/libs/vkjson \
system/libhwbinder/fast_msgq/include \
LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
ifeq ($(TARGET_USES_HWC2),true)
LOCAL_CFLAGS += -DUSE_HWC2
LOCAL_SRC_FILES += \
SurfaceFlinger.cpp \
DisplayHardware/HWComposer.cpp
else
LOCAL_SRC_FILES += \
SurfaceFlinger_hwc1.cpp \
DisplayHardware/HWComposer_hwc1.cpp
endif
LOCAL_CFLAGS += -fvisibility=hidden -Werror=format
LOCAL_STATIC_LIBRARIES := \
libhwcomposer-command-buffer \
libtrace_proto \
libvkjson \
libvr_manager \
libvrflinger
LOCAL_SHARED_LIBRARIES := \
android.frameworks.vr.composer@1.0 \
android.hardware.graphics.allocator@2.0 \
android.hardware.graphics.composer@2.1 \
android.hardware.configstore@1.0 \
android.hardware.configstore-utils \
libcutils \
liblog \
libdl \
libfmq \
libhardware \
libhidlbase \
libhidltransport \
libhwbinder \
libutils \
libEGL \
libGLESv1_CM \
libGLESv2 \
libbinder \
libui \
libgui \
libpowermanager \
libvulkan \
libsync \
libprotobuf-cpp-lite \
libbase \
android.hardware.power@1.0
LOCAL_EXPORT_SHARED_LIBRARY_HEADERS := \
android.hardware.graphics.allocator@2.0 \
android.hardware.graphics.composer@2.1 \
libhidlbase \
libhidltransport \
libhwbinder
LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code -std=c++1z
include $(BUILD_SHARED_LIBRARY)
###############################################################
# build surfaceflinger's executable
include $(CLEAR_VARS)
LOCAL_CLANG := true
LOCAL_LDFLAGS_32 := -Wl,--version-script,art/sigchainlib/version-script32.txt -Wl,--export-dynamic
LOCAL_LDFLAGS_64 := -Wl,--version-script,art/sigchainlib/version-script64.txt -Wl,--export-dynamic
LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
LOCAL_INIT_RC := surfaceflinger.rc
ifeq ($(TARGET_USES_HWC2),true)
LOCAL_CFLAGS += -DUSE_HWC2
endif
LOCAL_SRC_FILES := \
main_surfaceflinger.cpp
LOCAL_SHARED_LIBRARIES := \
android.frameworks.displayservice@1.0 \
android.hardware.configstore@1.0 \
android.hardware.configstore-utils \
android.hardware.graphics.allocator@2.0 \
libsurfaceflinger \
libcutils \
libdisplayservicehidl \
liblog \
libbinder \
libhidlbase \
libhidltransport \
libutils \
libui \
libgui \
libdl
LOCAL_WHOLE_STATIC_LIBRARIES := libsigchain
LOCAL_STATIC_LIBRARIES := libtrace_proto
LOCAL_MODULE := surfaceflinger
ifdef TARGET_32_BIT_SURFACEFLINGER
LOCAL_32_BIT_ONLY := true
endif
LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code
include $(BUILD_EXECUTABLE)
###############################################################
# uses jni which may not be available in PDK
ifneq ($(wildcard libnativehelper/include),)
include $(CLEAR_VARS)
LOCAL_CLANG := true
LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
LOCAL_SRC_FILES := \
DdmConnection.cpp
LOCAL_SHARED_LIBRARIES := \
libcutils \
liblog \
libdl
LOCAL_MODULE := libsurfaceflinger_ddmconnection
LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code
include $(BUILD_SHARED_LIBRARY)
endif # libnativehelper
include $(call first-makefiles-under,$(LOCAL_PATH))
|