blob: 4558fe87c6bd857a8d768ed4829d85a7382ec4cd [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 Park172bd722017-06-21 12:14:18 +090022 vendor_available: true,
Dan Willemsen3106c1c2016-10-03 23:56:51 -070023
24 clang: true,
25 cppflags: [
26 "-Weverything",
27 "-Werror",
28
29 // The static constructors and destructors in this library have not been noted to
30 // introduce significant overheads
31 "-Wno-exit-time-destructors",
32 "-Wno-global-constructors",
33
34 // We only care about compiling as C++14
35 "-Wno-c++98-compat-pedantic",
36
37 // We don't need to enumerate every case in a switch as long as a default case
38 // is present
39 "-Wno-switch-enum",
40
41 // Allow calling variadic macros without a __VA_ARGS__ list
42 "-Wno-gnu-zero-variadic-macro-arguments",
43
44 // Don't warn about struct padding
45 "-Wno-padded",
46
Dan Stoza71bded52016-10-19 11:10:33 -070047 // We are aware of the risks inherent in comparing floats for equality
48 "-Wno-float-equal",
49
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -080050 // Pure abstract classes trigger this warning
51 "-Wno-weak-vtables",
52
53 // Allow four-character integer literals
54 "-Wno-four-char-constants",
55
56 // Allow documentation warnings
57 "-Wno-documentation",
58
Dan Willemsen3106c1c2016-10-03 23:56:51 -070059 "-DDEBUG_ONLY_CODE=0",
60 ],
61
62 product_variables: {
63 brillo: {
64 cflags: ["-DHAVE_NO_SURFACE_FLINGER"],
65 },
Fabien Sanglard98bfd4f2017-06-22 11:13:49 -070066 eng: {
Dan Willemsen3106c1c2016-10-03 23:56:51 -070067 cppflags: [
68 "-UDEBUG_ONLY_CODE",
69 "-DDEBUG_ONLY_CODE=1",
70 ],
71 },
72 },
73
74 srcs: [
Dan Willemsen3106c1c2016-10-03 23:56:51 -070075 "BitTube.cpp",
76 "BufferItem.cpp",
77 "BufferItemConsumer.cpp",
78 "BufferQueue.cpp",
79 "BufferQueueConsumer.cpp",
80 "BufferQueueCore.cpp",
81 "BufferQueueProducer.cpp",
82 "BufferSlot.cpp",
83 "ConsumerBase.cpp",
84 "CpuConsumer.cpp",
85 "DisplayEventReceiver.cpp",
Brian Andersond6927fb2016-07-23 23:37:30 -070086 "FrameTimestamps.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070087 "GLConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070088 "GuiConfig.cpp",
89 "IDisplayEventConnection.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080090 "IConsumerListener.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080091 "IGraphicBufferConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070092 "IGraphicBufferProducer.cpp",
93 "IProducerListener.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070094 "ISurfaceComposer.cpp",
95 "ISurfaceComposerClient.cpp",
96 "LayerState.cpp",
97 "OccupancyTracker.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070098 "StreamSplitter.cpp",
99 "Surface.cpp",
100 "SurfaceControl.cpp",
101 "SurfaceComposerClient.cpp",
102 "SyncFeatures.cpp",
Mathias Agopian05debe12017-02-08 17:04:18 -0800103 "view/Surface.cpp",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800104 "bufferqueue/1.0/B2HProducerListener.cpp",
105 "bufferqueue/1.0/H2BGraphicBufferProducer.cpp"
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700106 ],
107
108 shared_libs: [
Jesse Hall153fbc82017-01-03 16:18:15 -0800109 "libsync",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700110 "libbinder",
111 "libcutils",
112 "libEGL",
113 "libGLESv2",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700114 "libui",
115 "libutils",
Mathias Agopian89ed4c82017-02-09 18:48:34 -0800116 "libnativewindow",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700117 "liblog",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800118 "libhidlbase",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600119 "libhidltransport",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800120 "android.hidl.token@1.0-utils",
121 "android.hardware.graphics.bufferqueue@1.0",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600122 "android.hardware.configstore@1.0",
Jaesoo Lee3e85cbe2017-03-30 15:24:15 +0900123 "android.hardware.configstore-utils",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700124 ],
125
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700126 header_libs: [
127 "libnativebase_headers",
Jiyong Park172bd722017-06-21 12:14:18 +0900128 "libgui_headers",
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700129 ],
130
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800131 export_shared_lib_headers: [
132 "libbinder",
Steven Moreland33f64842017-06-22 17:50:49 -0700133 "libEGL",
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700134 "libnativewindow",
Steven Moreland33f64842017-06-22 17:50:49 -0700135 "libui",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800136 "android.hidl.token@1.0-utils",
137 "android.hardware.graphics.bufferqueue@1.0",
138 ],
Dan Stoza1e438d22017-03-31 16:18:10 -0700139
Jiyong Park172bd722017-06-21 12:14:18 +0900140 export_header_lib_headers: [
141 "libgui_headers",
142 ],
143
Dan Stoza1e438d22017-03-31 16:18:10 -0700144 export_include_dirs: [
145 "include",
146 ],
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700147}
148
149subdirs = ["tests"]