blob: c0ae3d78365708fca83d4e89912db4c764eb1a00 [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.
14
15cc_library_shared {
16 name: "libgui",
17
18 clang: true,
19 cppflags: [
20 "-Weverything",
21 "-Werror",
22
23 // The static constructors and destructors in this library have not been noted to
24 // introduce significant overheads
25 "-Wno-exit-time-destructors",
26 "-Wno-global-constructors",
27
28 // We only care about compiling as C++14
29 "-Wno-c++98-compat-pedantic",
30
31 // We don't need to enumerate every case in a switch as long as a default case
32 // is present
33 "-Wno-switch-enum",
34
35 // Allow calling variadic macros without a __VA_ARGS__ list
36 "-Wno-gnu-zero-variadic-macro-arguments",
37
38 // Don't warn about struct padding
39 "-Wno-padded",
40
Dan Stoza71bded52016-10-19 11:10:33 -070041 // We are aware of the risks inherent in comparing floats for equality
42 "-Wno-float-equal",
43
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -080044 // Pure abstract classes trigger this warning
45 "-Wno-weak-vtables",
46
47 // Allow four-character integer literals
48 "-Wno-four-char-constants",
49
50 // Allow documentation warnings
51 "-Wno-documentation",
52
Dan Willemsen3106c1c2016-10-03 23:56:51 -070053 "-DDEBUG_ONLY_CODE=0",
54 ],
55
56 product_variables: {
57 brillo: {
58 cflags: ["-DHAVE_NO_SURFACE_FLINGER"],
59 },
60 debuggable: {
61 cppflags: [
62 "-UDEBUG_ONLY_CODE",
63 "-DDEBUG_ONLY_CODE=1",
64 ],
65 },
66 },
67
68 srcs: [
Dan Willemsen3106c1c2016-10-03 23:56:51 -070069 "BitTube.cpp",
70 "BufferItem.cpp",
71 "BufferItemConsumer.cpp",
72 "BufferQueue.cpp",
73 "BufferQueueConsumer.cpp",
74 "BufferQueueCore.cpp",
75 "BufferQueueProducer.cpp",
76 "BufferSlot.cpp",
77 "ConsumerBase.cpp",
78 "CpuConsumer.cpp",
79 "DisplayEventReceiver.cpp",
Brian Andersond6927fb2016-07-23 23:37:30 -070080 "FrameTimestamps.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070081 "GLConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070082 "GuiConfig.cpp",
83 "IDisplayEventConnection.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080084 "IConsumerListener.cpp",
Mathias Agopian801ea092017-03-06 15:05:04 -080085 "IGraphicBufferConsumer.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070086 "IGraphicBufferProducer.cpp",
87 "IProducerListener.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070088 "ISurfaceComposer.cpp",
89 "ISurfaceComposerClient.cpp",
90 "LayerState.cpp",
91 "OccupancyTracker.cpp",
Dan Willemsen3106c1c2016-10-03 23:56:51 -070092 "StreamSplitter.cpp",
93 "Surface.cpp",
94 "SurfaceControl.cpp",
95 "SurfaceComposerClient.cpp",
96 "SyncFeatures.cpp",
Mathias Agopian05debe12017-02-08 17:04:18 -080097 "view/Surface.cpp",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -080098 "bufferqueue/1.0/B2HProducerListener.cpp",
99 "bufferqueue/1.0/H2BGraphicBufferProducer.cpp"
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700100 ],
101
102 shared_libs: [
Jesse Hall153fbc82017-01-03 16:18:15 -0800103 "libsync",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700104 "libbinder",
105 "libcutils",
106 "libEGL",
107 "libGLESv2",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700108 "libui",
109 "libutils",
Mathias Agopian89ed4c82017-02-09 18:48:34 -0800110 "libnativewindow",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700111 "liblog",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800112 "libhidlbase",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600113 "libhidltransport",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800114 "android.hidl.token@1.0-utils",
115 "android.hardware.graphics.bufferqueue@1.0",
Courtney Goeltzenleuchtera0c93e12017-03-17 16:16:48 -0600116 "android.hardware.configstore@1.0",
Jaesoo Lee3e85cbe2017-03-30 15:24:15 +0900117 "android.hardware.configstore-utils",
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700118 ],
119
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700120 header_libs: [
121 "libnativebase_headers",
122 ],
123
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800124 export_shared_lib_headers: [
125 "libbinder",
126 "libui",
Mathias Agopian6a3c05b2017-04-27 20:06:55 -0700127 "libnativewindow",
Pawin Vongmasa6e1193a2017-03-07 13:08:40 -0800128 "android.hidl.token@1.0-utils",
129 "android.hardware.graphics.bufferqueue@1.0",
130 ],
Dan Stoza1e438d22017-03-31 16:18:10 -0700131
132 export_include_dirs: [
133 "include",
134 ],
Dan Willemsen3106c1c2016-10-03 23:56:51 -0700135}
136
137subdirs = ["tests"]