blob: 7ee4d49f64fef3891719c4635539463da9eb0f20 [file] [log] [blame]
Dan Willemsen3106c1c2016-10-03 23:56:51 -07001// Copyright 2010 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.
Jiyong Park172bd722017-06-21 12:14:18 +090014cc_library_headers {
15 name: "libgui_headers",
16 vendor_available: true,
17 export_include_dirs: ["include"],
18}
Dan Willemsen3106c1c2016-10-03 23:56:51 -070019
20cc_library_shared {
21 name: "libgui",
Jiyong Park99c514e2017-11-17 19:09:31 +090022 vendor_available: false,
Justin Yun71d6c8852017-07-24 15:19:45 +090023 vndk: {
24 enabled: true,
25 },
Dan Willemsen3106c1c2016-10-03 23:56:51 -070026
27 clang: true,
Chih-Hung Hsiehd66be0a2017-10-05 13:51:32 -070028 cflags: [
29 "-Wall",
30 "-Werror",
31 ],
Dan Willemsen3106c1c2016-10-03 23:56:51 -070032 cppflags: [
33 "-Weverything",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070034
35 // The static constructors and destructors in this library have not been noted to
36 // introduce significant overheads
37 "-Wno-exit-time-destructors",
38 "-Wno-global-constructors",
39
40 // We only care about compiling as C++14
41 "-Wno-c++98-compat-pedantic",
42
43 // We don't need to enumerate every case in a switch as long as a default case
44 // is present
45 "-Wno-switch-enum",
46
47 // Allow calling variadic macros without a __VA_ARGS__ list
48 "-Wno-gnu-zero-variadic-macro-arguments",
49
50 // Don't warn about struct padding
51 "-Wno-padded",
52
Dan Stoza71bded52016-10-19 11:10:33 -070053 // We are aware of the risks inherent in comparing floats for equality
54 "-Wno-float-equal",
55
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -080056 // Pure abstract classes trigger this warning
57 "-Wno-weak-vtables",
58
59 // Allow four-character integer literals
60 "-Wno-four-char-constants",
61
62 // Allow documentation warnings
63 "-Wno-documentation",
64
Dan Willemsen3106c1c2016-10-03 23:56:51 -070065 "-DDEBUG_ONLY_CODE=0",
66 ],
67
68 product_variables: {
69 brillo: {
70 cflags: ["-DHAVE_NO_SURFACE_FLINGER"],
71 },
Fabien Sanglard98bfd4f2017-06-22 11:13:49 -070072 eng: {
Dan Willemsen3106c1c2016-10-03 23:56:51 -070073 cppflags: [
74 "-UDEBUG_ONLY_CODE",
75 "-DDEBUG_ONLY_CODE=1",
76 ],
77 },
78 },
79
80 srcs: [
Dan Willemsen3106c1c2016-10-03 23:56:51 -070081 "BitTube.cpp",
82 "BufferItem.cpp",
83 "BufferItemConsumer.cpp",
84 "BufferQueue.cpp",
85 "BufferQueueConsumer.cpp",
86 "BufferQueueCore.cpp",
87 "BufferQueueProducer.cpp",
88 "BufferSlot.cpp",
89 "ConsumerBase.cpp",
90 "CpuConsumer.cpp",
91 "DisplayEventReceiver.cpp",
Brian Andersond6927fb2016-07-23 23:37:30 -070092 "FrameTimestamps.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070093 "GLConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070094 "GuiConfig.cpp",
Courtney Goeltzenleuchter9bad0d72017-12-19 12:34:34 -070095 "HdrMetadata.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070096 "IDisplayEventConnection.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080097 "IConsumerListener.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080098 "IGraphicBufferConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070099 "IGraphicBufferProducer.cpp",
100 "IProducerListener.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700101 "ISurfaceComposer.cpp",
102 "ISurfaceComposerClient.cpp",
Kalle Raitaa099a242017-01-11 11:17:29 -0800103 "LayerDebugInfo.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700104 "LayerState.cpp",
105 "OccupancyTracker.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700106 "StreamSplitter.cpp",
107 "Surface.cpp",
108 "SurfaceControl.cpp",
109 "SurfaceComposerClient.cpp",
110 "SyncFeatures.cpp",
Mathias Agopian05debe12017-02-08 17:04:18 -0800111 "view/Surface.cpp",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800112 "bufferqueue/1.0/B2HProducerListener.cpp",
113 "bufferqueue/1.0/H2BGraphicBufferProducer.cpp"
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700114 ],
115
116 shared_libs: [
Jesse Hall153fbc82017-01-03 16:18:15 -0800117 "libsync",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700118 "libbinder",
119 "libcutils",
120 "libEGL",
121 "libGLESv2",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700122 "libui",
123 "libutils",
Mathias Agopian89ed4c82017-02-09 18:48:34 -0800124 "libnativewindow",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700125 "liblog",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800126 "libhidlbase",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600127 "libhidltransport",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800128 "android.hidl.token@1.0-utils",
129 "android.hardware.graphics.bufferqueue@1.0",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600130 "android.hardware.configstore@1.0",
Jaesoo Lee3e85cbe2017-03-30 15:24:15 +0900131 "android.hardware.configstore-utils",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700132 ],
133
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700134 header_libs: [
135 "libnativebase_headers",
Jiyong Park172bd722017-06-21 12:14:18 +0900136 "libgui_headers",
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700137 ],
138
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800139 export_shared_lib_headers: [
140 "libbinder",
Steven Moreland33f64842017-06-22 17:50:49 -0700141 "libEGL",
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700142 "libnativewindow",
Steven Moreland33f64842017-06-22 17:50:49 -0700143 "libui",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800144 "android.hidl.token@1.0-utils",
145 "android.hardware.graphics.bufferqueue@1.0",
146 ],
Dan Stoza1e438d22017-03-31 16:18:10 -0700147
Jiyong Park172bd722017-06-21 12:14:18 +0900148 export_header_lib_headers: [
149 "libgui_headers",
150 ],
151
Dan Stoza1e438d22017-03-31 16:18:10 -0700152 export_include_dirs: [
153 "include",
154 ],
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700155}
156
157subdirs = ["tests"]