blob: bd89bd5fd3876d16740ea402212a913566ec5788 [file] [log] [blame]
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -08001LOCAL_PATH:= $(call my-dir)
2include $(CLEAR_VARS)
3
4LOCAL_SRC_FILES:= \
Jesse Hall99c7dbb2013-03-14 14:29:29 -07005 Client.cpp \
6 DisplayDevice.cpp \
Jamie Gennisfaf77cc2013-07-30 15:10:32 -07007 DispSync.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -07008 EventThread.cpp \
9 FrameTracker.cpp \
Jesse Hall99c7dbb2013-03-14 14:29:29 -070010 Layer.cpp \
11 LayerDim.cpp \
12 MessageQueue.cpp \
13 SurfaceFlinger.cpp \
14 SurfaceFlingerConsumer.cpp \
15 SurfaceTextureLayer.cpp \
16 Transform.cpp \
17 DisplayHardware/FramebufferSurface.cpp \
18 DisplayHardware/HWComposer.cpp \
19 DisplayHardware/PowerHAL.cpp \
20 DisplayHardware/VirtualDisplaySurface.cpp \
Mathias Agopianff2ed702013-09-01 21:36:12 -070021 Effects/Daltonizer.cpp \
Mathias Agopian85cce372013-06-04 21:50:31 -070022 EventLog/EventLogTags.logtags \
Mathias Agopian875d8e12013-06-07 15:35:48 -070023 EventLog/EventLog.cpp \
Mathias Agopian3f844832013-08-07 21:24:32 -070024 RenderEngine/Description.cpp \
25 RenderEngine/Mesh.cpp \
26 RenderEngine/Program.cpp \
27 RenderEngine/ProgramCache.cpp \
Mathias Agopian875d8e12013-06-07 15:35:48 -070028 RenderEngine/GLExtensions.cpp \
29 RenderEngine/RenderEngine.cpp \
Mathias Agopian49457ac2013-08-14 18:20:17 -070030 RenderEngine/Texture.cpp \
Mathias Agopian875d8e12013-06-07 15:35:48 -070031 RenderEngine/GLES10RenderEngine.cpp \
Mathias Agopian3f844832013-08-07 21:24:32 -070032 RenderEngine/GLES11RenderEngine.cpp \
33 RenderEngine/GLES20RenderEngine.cpp
Mathias Agopian875d8e12013-06-07 15:35:48 -070034
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080035
Mathias Agopian076b1cc2009-04-10 14:24:30 -070036LOCAL_CFLAGS:= -DLOG_TAG=\"SurfaceFlinger\"
37LOCAL_CFLAGS += -DGL_GLEXT_PROTOTYPES -DEGL_EGLEXT_PROTOTYPES
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080038
Mathias Agopian5df99622012-06-18 17:27:56 -070039ifeq ($(TARGET_BOARD_PLATFORM),omap3)
Mathias Agopiana5529c82010-12-07 19:38:17 -080040 LOCAL_CFLAGS += -DNO_RGBX_8888
Mathias Agopiana8f3e4e2010-06-30 15:43:47 -070041endif
Mathias Agopian5df99622012-06-18 17:27:56 -070042ifeq ($(TARGET_BOARD_PLATFORM),omap4)
Mathias Agopian57bf9e72011-10-07 15:42:53 -070043 LOCAL_CFLAGS += -DHAS_CONTEXT_PRIORITY
44endif
Mathias Agopian5df99622012-06-18 17:27:56 -070045ifeq ($(TARGET_BOARD_PLATFORM),s5pc110)
Mathias Agopian7f42a9c2012-04-23 20:00:16 -070046 LOCAL_CFLAGS += -DHAS_CONTEXT_PRIORITY
Mathias Agopian7f42a9c2012-04-23 20:00:16 -070047endif
48
Mathias Agopian5df99622012-06-18 17:27:56 -070049ifeq ($(TARGET_DISABLE_TRIPLE_BUFFERING),true)
Mathias Agopian7f42a9c2012-04-23 20:00:16 -070050 LOCAL_CFLAGS += -DTARGET_DISABLE_TRIPLE_BUFFERING
Mathias Agopian67226812010-10-11 17:54:43 -070051endif
52
Jamie Genniscdbaecb2012-10-12 14:18:10 -070053ifneq ($(NUM_FRAMEBUFFER_SURFACE_BUFFERS),)
54 LOCAL_CFLAGS += -DNUM_FRAMEBUFFER_SURFACE_BUFFERS=$(NUM_FRAMEBUFFER_SURFACE_BUFFERS)
55endif
56
Jamie Gennisfaf77cc2013-07-30 15:10:32 -070057ifeq ($(TARGET_RUNNING_WITHOUT_SYNC_FRAMEWORK),true)
58 LOCAL_CFLAGS += -DRUNNING_WITHOUT_SYNC_FRAMEWORK
59endif
60
61# See build/target/board/generic/BoardConfig.mk for a description of this setting.
62ifneq ($(VSYNC_EVENT_PHASE_OFFSET_NS),)
63 LOCAL_CFLAGS += -DVSYNC_EVENT_PHASE_OFFSET_NS=$(VSYNC_EVENT_PHASE_OFFSET_NS)
64else
65 LOCAL_CFLAGS += -DVSYNC_EVENT_PHASE_OFFSET_NS=0
66endif
67
68ifneq ($(PRESENT_TIME_OFFSET_FROM_VSYNC_NS),)
69 LOCAL_CFLAGS += -DPRESENT_TIME_OFFSET_FROM_VSYNC_NS=$(PRESENT_TIME_OFFSET_FROM_VSYNC_NS)
70else
71 LOCAL_CFLAGS += -DPRESENT_TIME_OFFSET_FROM_VSYNC_NS=0
72endif
73
Mathias Agopianb6df7d02013-05-09 14:53:35 -070074LOCAL_CFLAGS += -fvisibility=hidden
75
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080076LOCAL_SHARED_LIBRARIES := \
Mathias Agopianaf54ab92009-07-02 19:04:39 -070077 libcutils \
Ying Wang8a0cb4e2013-04-09 21:55:39 -070078 liblog \
Mathias Agopianc1d359d2012-08-04 20:09:03 -070079 libdl \
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080080 libhardware \
81 libutils \
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080082 libEGL \
Mathias Agopianaf54ab92009-07-02 19:04:39 -070083 libGLESv1_CM \
Mathias Agopian3f844832013-08-07 21:24:32 -070084 libGLESv2 \
Mathias Agopianaf54ab92009-07-02 19:04:39 -070085 libbinder \
Mathias Agopian9cce3252010-02-09 17:46:37 -080086 libui \
Mathias Agopiand87f1622011-03-25 18:42:40 -070087 libgui
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080088
The Android Open Source Projectedbf3b62009-03-03 19:31:44 -080089LOCAL_MODULE:= libsurfaceflinger
90
91include $(BUILD_SHARED_LIBRARY)
Keun young Park63f165f2012-08-31 10:53:36 -070092
93###############################################################
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -070094# build surfaceflinger's executable
95include $(CLEAR_VARS)
96
Mathias Agopian4f4f0942013-08-19 17:26:18 -070097LOCAL_CFLAGS:= -DLOG_TAG=\"SurfaceFlinger\"
98
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -070099LOCAL_SRC_FILES:= \
100 main_surfaceflinger.cpp
101
102LOCAL_SHARED_LIBRARIES := \
103 libsurfaceflinger \
Mathias Agopian9414d672013-08-23 15:56:38 -0700104 libcutils \
Mathias Agopian4f4f0942013-08-19 17:26:18 -0700105 liblog \
Mathias Agopian7ffaa7c2013-07-22 12:20:28 -0700106 libbinder \
107 libutils
108
109LOCAL_MODULE:= surfaceflinger
110
111include $(BUILD_EXECUTABLE)
112
113###############################################################
Keun young Park63f165f2012-08-31 10:53:36 -0700114# uses jni which may not be available in PDK
115ifneq ($(wildcard libnativehelper/include),)
116include $(CLEAR_VARS)
Mathias Agopian1b3aeb42012-10-07 16:41:12 -0700117LOCAL_CFLAGS:= -DLOG_TAG=\"SurfaceFlinger\"
118
Keun young Park63f165f2012-08-31 10:53:36 -0700119LOCAL_SRC_FILES:= \
120 DdmConnection.cpp
121
122LOCAL_SHARED_LIBRARIES := \
123 libcutils \
Ying Wang8a0cb4e2013-04-09 21:55:39 -0700124 liblog \
Keun young Park63f165f2012-08-31 10:53:36 -0700125 libdl
126
127LOCAL_MODULE:= libsurfaceflinger_ddmconnection
128
129include $(BUILD_SHARED_LIBRARY)
130endif # libnativehelper