blob: 6c54ec3ed2f95a4487d20ea73b6bc2be3fa0ada3 [file] [log] [blame]
Dan Stoza01049c82014-11-11 10:32:31 -08001LOCAL_PATH := $(call my-dir)
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -08002include $(CLEAR_VARS)
3
Jesse Hall24cd98e2014-07-13 14:37:16 -07004LOCAL_CLANG := true
5
Jesse Halle9b23b62014-07-14 15:32:59 -07006LOCAL_ADDITIONAL_DEPENDENCIES := $(LOCAL_PATH)/Android.mk
Dan Stoza01049c82014-11-11 10:32:31 -08007LOCAL_SRC_FILES := \
Jesse Hall99c7dbb2013-03-14 14:29:29 -07008 Client.cpp \
9 DisplayDevice.cpp \
Jamie Gennisfaf77cc2013-07-30 15:10:32 -070010 DispSync.cpp \
Jamie Gennisd1700752013-10-14 12:22:52 -070011 EventControlThread.cpp \
Wei Wangf9b05ee2017-07-19 20:59:39 -070012 StartPropertySetThread.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070013 EventThread.cpp \
14 FrameTracker.cpp \
Jesse Hallfc038bd2016-03-26 22:20:22 -070015 GpuService.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070016 Layer.cpp \
David Sodman0c69cad2017-08-21 12:12:51 -070017 BufferLayer.cpp \
Chia-I Wuf1405182017-11-27 11:29:21 -080018 BufferLayerConsumer.cpp \
chaviw13fdc492017-06-27 12:40:18 -070019 ColorLayer.cpp \
Fabien Sanglard7b1563a2016-10-13 12:05:28 -070020 LayerRejecter.cpp \
Robert Carr2047fae2016-11-28 14:09:09 -080021 LayerVector.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070022 MessageQueue.cpp \
Dan Stozab9b08832014-03-13 11:55:57 -070023 MonitoredProducer.cpp \
Chia-I Wud265c422017-10-19 15:16:41 -070024 SurfaceFlinger.cpp \
Irvelc274c632016-06-13 16:44:08 -070025 SurfaceInterceptor.cpp \
Adrian Roos1e1a1282017-11-01 19:05:31 +010026 SurfaceTracing.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070027 Transform.cpp \
Chia-I Wuaab99f52016-10-05 12:59:58 +080028 DisplayHardware/ComposerHal.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070029 DisplayHardware/FramebufferSurface.cpp \
Dan Stoza651bf312015-10-23 17:03:17 -070030 DisplayHardware/HWC2.cpp \
Chia-I Wud265c422017-10-19 15:16:41 -070031 DisplayHardware/HWComposer.cpp \
Chia-I Wuaaff73f2017-02-13 12:28:24 -080032 DisplayHardware/HWComposerBufferCache.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070033 DisplayHardware/VirtualDisplaySurface.cpp \
Mathias Agopianff2ed702013-09-01 21:36:12 -070034 Effects/Daltonizer.cpp \
Mathias Agopian85cce372013-06-04 21:50:31 -070035 EventLog/EventLogTags.logtags \
Mathias Agopian875d8e12013-06-07 15:35:48 -070036 EventLog/EventLog.cpp \
Mathias Agopian3f844832013-08-07 21:24:32 -070037 RenderEngine/Description.cpp \
Chia-I Wu401ef832017-12-01 10:52:22 -080038 RenderEngine/Image.cpp \
Mathias Agopian3f844832013-08-07 21:24:32 -070039 RenderEngine/Mesh.cpp \
40 RenderEngine/Program.cpp \
41 RenderEngine/ProgramCache.cpp \
Mathias Agopian875d8e12013-06-07 15:35:48 -070042 RenderEngine/GLExtensions.cpp \
43 RenderEngine/RenderEngine.cpp \
Chia-I Wu7e60ecc2017-11-09 11:04:45 -080044 RenderEngine/Surface.cpp \
Mathias Agopian49457ac2013-08-14 18:20:17 -070045 RenderEngine/Texture.cpp \
Irvelc274c632016-06-13 16:44:08 -070046 RenderEngine/GLES20RenderEngine.cpp \
chaviw1d044282017-09-27 12:19:28 -070047 LayerProtoHelper.cpp \
chaviwa76b2712017-09-20 12:02:26 -070048 RenderArea.cpp \
Mathias Agopian875d8e12013-06-07 15:35:48 -070049
Irvelc274c632016-06-13 16:44:08 -070050LOCAL_MODULE := libsurfaceflinger
Jesse Hall8b0d55e2016-03-31 19:29:36 -070051LOCAL_C_INCLUDES := \
Irvelc274c632016-06-13 16:44:08 -070052 frameworks/native/vulkan/include \
53 external/vulkan-validation-layers/libs/vkjson \
Chia-I Wucd8d7f02016-11-16 11:02:31 +080054 system/libhwbinder/fast_msgq/include \
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080055
Dan Stoza01049c82014-11-11 10:32:31 -080056LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
Mathias Agopian076b1cc2009-04-10 14:24:30 -070057LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
Fabien Sanglard9d96de42016-10-11 00:15:18 +000058
Michael Lentine7306c672014-07-30 13:00:37 -070059LOCAL_CFLAGS += -fvisibility=hidden -Werror=format
Mathias Agopianb6df7d02013-05-09 14:53:35 -070060
Hendrik Wagenaar87670ff2017-02-01 12:10:46 -080061LOCAL_STATIC_LIBRARIES := \
Hendrik Wagenaar87670ff2017-02-01 12:10:46 -080062 libtrace_proto \
63 libvkjson \
64 libvr_manager \
Vishnu Nair35798872017-10-06 16:00:36 -070065 libvrflinger \
66 libserviceutils
67
Courtney Goeltzenleuchter87551222018-01-16 14:00:09 -080068LOCAL_HEADER_LIBRARIES := \
69 android.hardware.graphics.composer@2.1-command-buffer
70
Vishnu Nair35798872017-10-06 16:00:36 -070071LOCAL_EXPORT_STATIC_LIBRARY_HEADERS := libserviceutils
Hendrik Wagenaar87670ff2017-02-01 12:10:46 -080072
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080073LOCAL_SHARED_LIBRARIES := \
Daniel Nicoara95a99a12017-03-21 15:30:45 -040074 android.frameworks.vr.composer@1.0 \
Chia-I Wuaab99f52016-10-05 12:59:58 +080075 android.hardware.graphics.allocator@2.0 \
76 android.hardware.graphics.composer@2.1 \
Jiyong Park4b20c2e2017-01-14 19:45:11 +090077 android.hardware.configstore@1.0 \
Jaesoo Lee585e32f2017-03-30 15:25:19 +090078 android.hardware.configstore-utils \
Andreas Gampe89fd4f72014-11-13 14:18:56 -080079 libcutils \
80 liblog \
81 libdl \
Chia-I Wucd8d7f02016-11-16 11:02:31 +080082 libfmq \
Andreas Gampe89fd4f72014-11-13 14:18:56 -080083 libhardware \
Yifan Hong67a47622016-11-17 13:02:06 -080084 libhidlbase \
85 libhidltransport \
Chia-I Wuaab99f52016-10-05 12:59:58 +080086 libhwbinder \
Andreas Gampe89fd4f72014-11-13 14:18:56 -080087 libutils \
88 libEGL \
89 libGLESv1_CM \
90 libGLESv2 \
91 libbinder \
92 libui \
93 libgui \
Irvelc274c632016-06-13 16:44:08 -070094 libvulkan \
Chia-I Wucd8d7f02016-11-16 11:02:31 +080095 libsync \
Colin Cross63549382016-10-26 12:52:53 -070096 libprotobuf-cpp-lite \
Ruchi Kandoib5ee1782016-10-04 17:51:50 -070097 libbase \
chaviw1d044282017-09-27 12:19:28 -070098 android.hardware.power@1.0 \
99 liblayers_proto
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -0800100
Chia-I Wuaab99f52016-10-05 12:59:58 +0800101LOCAL_EXPORT_SHARED_LIBRARY_HEADERS := \
102 android.hardware.graphics.allocator@2.0 \
103 android.hardware.graphics.composer@2.1 \
Yifan Hong67a47622016-11-17 13:02:06 -0800104 libhidlbase \
105 libhidltransport \
Chia-I Wuaab99f52016-10-05 12:59:58 +0800106 libhwbinder
107
Dan Stoza2b6d38e2017-06-01 16:40:30 -0700108LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code -std=c++1z
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800109
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -0800110include $(BUILD_SHARED_LIBRARY)
Keun young Park63f165f2012-08-31 10:53:36 -0700111
112###############################################################
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700113# build surfaceflinger's executable
114include $(CLEAR_VARS)
115
Dan Stoza01049c82014-11-11 10:32:31 -0800116LOCAL_CLANG := true
Mathias Agopian4f4f0942013-08-19 17:26:18 -0700117
Dimitry Ivanovf06248f2016-08-01 14:13:37 -0700118LOCAL_LDFLAGS_32 := -Wl,--version-script,art/sigchainlib/version-script32.txt -Wl,--export-dynamic
119LOCAL_LDFLAGS_64 := -Wl,--version-script,art/sigchainlib/version-script64.txt -Wl,--export-dynamic
Dan Stoza01049c82014-11-11 10:32:31 -0800120LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
Dan Stoza01049c82014-11-11 10:32:31 -0800121
Tom Cherry74155992015-08-14 13:01:23 -0700122LOCAL_INIT_RC := surfaceflinger.rc
123
Dan Stoza01049c82014-11-11 10:32:31 -0800124LOCAL_SRC_FILES := \
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800125 main_surfaceflinger.cpp
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700126
127LOCAL_SHARED_LIBRARIES := \
Steven Moreland6ad20f72017-05-16 17:42:50 -0700128 android.frameworks.displayservice@1.0 \
Chia-I Wub2784042017-03-30 11:56:21 -0700129 android.hardware.configstore@1.0 \
130 android.hardware.configstore-utils \
131 android.hardware.graphics.allocator@2.0 \
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800132 libsurfaceflinger \
133 libcutils \
Steven Moreland6ad20f72017-05-16 17:42:50 -0700134 libdisplayservicehidl \
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800135 liblog \
136 libbinder \
Chia-I Wub2784042017-03-30 11:56:21 -0700137 libhidlbase \
138 libhidltransport \
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800139 libutils \
Mathias Agopiana9347642017-02-13 16:42:28 -0800140 libui \
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800141 libgui \
chaviw1d044282017-09-27 12:19:28 -0700142 libdl \
143 liblayers_proto
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700144
Dmitriy Ivanov4340a142014-10-20 14:17:26 -0700145LOCAL_WHOLE_STATIC_LIBRARIES := libsigchain
Vishnu Nair35798872017-10-06 16:00:36 -0700146LOCAL_STATIC_LIBRARIES := libtrace_proto \
147 libserviceutils
Dmitriy Ivanov4340a142014-10-20 14:17:26 -0700148
Dan Stoza01049c82014-11-11 10:32:31 -0800149LOCAL_MODULE := surfaceflinger
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700150
Colin Cross89450d42014-02-20 15:36:21 -0800151ifdef TARGET_32_BIT_SURFACEFLINGER
152LOCAL_32_BIT_ONLY := true
153endif
154
Steven Thomas6e8f7062017-11-22 14:15:29 -0800155LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code -std=c++1z
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800156
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700157include $(BUILD_EXECUTABLE)
158
159###############################################################
Keun young Park63f165f2012-08-31 10:53:36 -0700160# uses jni which may not be available in PDK
161ifneq ($(wildcard libnativehelper/include),)
162include $(CLEAR_VARS)
Mathias Agopian1b3aeb42012-10-07 16:41:12 -0700163
Dan Stoza01049c82014-11-11 10:32:31 -0800164LOCAL_CLANG := true
165
166LOCAL_CFLAGS := -DLOG_TAG=\"SurfaceFlinger\"
Dan Stoza01049c82014-11-11 10:32:31 -0800167
168LOCAL_SRC_FILES := \
Keun young Park63f165f2012-08-31 10:53:36 -0700169 DdmConnection.cpp
170
171LOCAL_SHARED_LIBRARIES := \
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800172 libcutils \
173 liblog \
174 libdl
Keun young Park63f165f2012-08-31 10:53:36 -0700175
Dan Stoza01049c82014-11-11 10:32:31 -0800176LOCAL_MODULE := libsurfaceflinger_ddmconnection
Keun young Park63f165f2012-08-31 10:53:36 -0700177
Andreas Gampe89fd4f72014-11-13 14:18:56 -0800178LOCAL_CFLAGS += -Wall -Werror -Wunused -Wunreachable-code
179
Keun young Park63f165f2012-08-31 10:53:36 -0700180include $(BUILD_SHARED_LIBRARY)
181endif # libnativehelper
Robert Carreb893992017-03-10 13:09:00 -0800182
183include $(call first-makefiles-under,$(LOCAL_PATH))