OSDN Git Service

Remove OverlayBufferManager.
[android-x86/external-IA-Hardware-Composer.git] / Android.mk
1 # Copyright (C) 2015 The Android Open Source Project
2 #
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
6 #
7 #      http://www.apache.org/licenses/LICENSE-2.0
8 #
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
14
15 ifeq ($(strip $(BOARD_USES_IA_HWCOMPOSER)),true)
16
17 LOCAL_PATH := $(call my-dir)
18 include $(CLEAR_VARS)
19
20 LOCAL_SHARED_LIBRARIES := \
21         libcutils \
22         libdrm \
23         libEGL \
24         libGLESv2 \
25         libhardware \
26         liblog \
27         libsync \
28         libui \
29         libutils
30
31
32 LOCAL_C_INCLUDES := \
33         system/core/include/utils \
34         system/core/libsync \
35         system/core/libsync/include \
36         $(LOCAL_PATH)/public \
37         $(LOCAL_PATH)/common/core \
38         $(LOCAL_PATH)/common/compositor \
39         $(LOCAL_PATH)/common/compositor/gl \
40         $(LOCAL_PATH)/common/display \
41         $(LOCAL_PATH)/common/utils \
42         $(LOCAL_PATH)/common/watchers \
43         $(LOCAL_PATH)/os/android
44
45 LOCAL_SRC_FILES := \
46         common/compositor/compositor.cpp \
47         common/compositor/factory.cpp \
48         common/compositor/nativesurface.cpp \
49         common/compositor/renderstate.cpp \
50         common/core/hwclayer.cpp \
51         common/core/gpudevice.cpp \
52         common/core/overlaybuffer.cpp \
53         common/core/overlaylayer.cpp \
54         common/display/display.cpp \
55         common/display/displayplane.cpp \
56         common/display/displayplanemanager.cpp \
57         common/display/displayqueue.cpp \
58         common/display/headless.cpp \
59         common/display/vblankeventhandler.cpp \
60         common/display/virtualdisplay.cpp \
61         common/utils/drmscopedtypes.cpp \
62         common/utils/fdhandler.cpp \
63         common/utils/hwcevent.cpp \
64         common/utils/hwcthread.cpp \
65         common/utils/hwcutils.cpp \
66         common/utils/disjoint_layers.cpp \
67         os/android/drmhwctwo.cpp \
68
69 ifeq ($(strip $(BOARD_USES_GRALLOC1)), true)
70 LOCAL_SRC_FILES += os/android/gralloc1bufferhandler.cpp
71 else
72 LOCAL_SRC_FILES += os/android/grallocbufferhandler.cpp
73 endif
74
75 LOCAL_CPPFLAGS += \
76         -DHWC2_USE_CPP11 \
77         -DHWC2_INCLUDE_STRINGIFICATION \
78         -DUSE_ANDROID_SYNC \
79         -DUSE_ANDROID_SHIM \
80         -O2 \
81         -D_FORTIFY_SOURCE=2 \
82         -fstack-protector-strong \
83         -Wformat -Wformat-security
84
85 ifeq ($(strip $(BOARD_DISABLE_NATIVE_COLOR_MODES)),true)
86 LOCAL_CPPFLAGS += -DDISABLE_NATIVE_COLOR_MODES
87 endif
88
89 ifeq ($(strip $(BOARD_USES_VULKAN)),)
90 LOCAL_CPPFLAGS += \
91         -DUSE_GL
92
93 LOCAL_SRC_FILES += \
94         common/compositor/gl/glprogram.cpp \
95         common/compositor/gl/glrenderer.cpp \
96         common/compositor/gl/glsurface.cpp \
97         common/compositor/gl/egloffscreencontext.cpp \
98         common/compositor/gl/nativeglresource.cpp \
99         common/compositor/gl/shim.cpp \
100         common/compositor/scopedrendererstate.cpp
101 endif
102
103 ifeq ($(strip $(BOARD_USES_MINIGBM)),true)
104 LOCAL_CPPFLAGS += -DUSE_MINIGBM
105 LOCAL_C_INCLUDES += \
106         $(INTEL_MINIGBM)/cros_gralloc/
107 else
108 LOCAL_C_INCLUDES += \
109         $(INTEL_DRM_GRALLOC)
110 endif
111
112 LOCAL_MODULE := hwcomposer.$(TARGET_BOARD_PLATFORM)
113 LOCAL_MODULE_TAGS := optional
114 #Preffered paths for all vendor hals /vendor/lib/hw
115 LOCAL_PROPRIETARY_MODULE := true
116 LOCAL_MODULE_RELATIVE_PATH := hw
117 LOCAL_MODULE_CLASS := SHARED_LIBRARIES
118 LOCAL_MODULE_SUFFIX := $(TARGET_SHLIB_SUFFIX)
119 include $(BUILD_SHARED_LIBRARY)
120
121 # libhwcservice
122 HWC_BUILD_DIRS := \
123 $(LOCAL_PATH)/os/android/libhwcservice/Android.mk
124
125 include $(HWC_BUILD_DIRS)
126
127 #Include tests only if eng build
128 ifneq (,$(filter eng,$(TARGET_BUILD_VARIANT)))
129 # Commenting for now include when ld issue is resolved
130 #include $(LOCAL_PATH)/tests/third_party/json-c/Android.mk
131 endif
132
133 endif