blob: f12d7b6a1750576c73d38600559ed3622058d04f [file] [log] [blame]
Bob Badour3306e492021-02-25 15:35:37 -08001package {
2 // See: http://go/android-license-faq
3 // A large-scale-change added 'default_applicable_licenses' to import
4 // all of the 'license_kinds' from "frameworks_native_license"
5 // to get the below license kinds:
6 // SPDX-license-identifier-Apache-2.0
7 default_applicable_licenses: ["frameworks_native_license"],
8}
9
Lloyd Pique70d91362018-10-18 16:02:55 -070010cc_defaults {
11 name: "libcompositionengine_defaults",
12 defaults: ["surfaceflinger_defaults"],
13 cflags: [
14 "-DLOG_TAG=\"CompositionEngine\"",
Lloyd Pique05b67b92019-09-25 13:16:44 -070015 "-DATRACE_TAG=ATRACE_TAG_GRAPHICS",
Lloyd Pique70d91362018-10-18 16:02:55 -070016 ],
Lloyd Pique441d5042018-10-18 16:49:51 -070017 shared_libs: [
18 "android.hardware.graphics.allocator@2.0",
19 "android.hardware.graphics.composer@2.1",
20 "android.hardware.graphics.composer@2.2",
21 "android.hardware.graphics.composer@2.3",
Dominik Laskowski25a4e7d2019-09-20 14:50:10 -070022 "android.hardware.graphics.composer@2.4",
Ady Abrahame7385f72021-09-05 00:54:25 -070023 "android.hardware.graphics.composer3-V1-ndk",
Lloyd Pique441d5042018-10-18 16:49:51 -070024 "android.hardware.power@1.0",
25 "android.hardware.power@1.3",
Xiang Wange12b4fa2022-03-25 23:48:40 +000026 "android.hardware.power-V2-cpp",
Lloyd Pique441d5042018-10-18 16:49:51 -070027 "libbase",
28 "libcutils",
29 "libgui",
30 "liblayers_proto",
31 "liblog",
Lloyd Pique31cb2942018-10-19 17:23:03 -070032 "libnativewindow",
Alec Mourie4034bb2019-11-19 12:45:54 -080033 "libprotobuf-cpp-lite",
Dan Stoza269dc4d2021-01-15 15:07:43 -080034 "libSurfaceFlingerProp",
Yiwei Zhangd7927052020-01-13 16:05:01 -080035 "libtimestats",
Lloyd Pique441d5042018-10-18 16:49:51 -070036 "libui",
37 "libutils",
38 ],
39 static_libs: [
40 "libmath",
41 "librenderengine",
Alec Mouri465b2962021-10-08 16:22:21 -070042 "libtonemap",
Lloyd Pique441d5042018-10-18 16:49:51 -070043 "libtrace_proto",
Ady Abrahame7385f72021-09-05 00:54:25 -070044 "libaidlcommonsupport",
Vishnu Naira3140382022-02-24 14:07:11 -080045 "libprocessgroup",
46 "libcgrouprc",
47 "libjsoncpp",
48 "libcgrouprc_format",
Lloyd Pique441d5042018-10-18 16:49:51 -070049 ],
50 header_libs: [
Lloyd Pique37c2c9b2018-12-04 17:25:10 -080051 "android.hardware.graphics.composer@2.1-command-buffer",
52 "android.hardware.graphics.composer@2.2-command-buffer",
53 "android.hardware.graphics.composer@2.3-command-buffer",
Peiyong Linafa0f572020-01-13 16:35:02 -080054 "android.hardware.graphics.composer@2.4-command-buffer",
Ady Abrahame7385f72021-09-05 00:54:25 -070055 "android.hardware.graphics.composer3-command-buffer",
Lloyd Pique441d5042018-10-18 16:49:51 -070056 "libsurfaceflinger_headers",
57 ],
Lloyd Pique70d91362018-10-18 16:02:55 -070058}
59
60cc_library {
61 name: "libcompositionengine",
62 defaults: ["libcompositionengine_defaults"],
63 srcs: [
Dan Stoza6166c312021-01-15 16:34:05 -080064 "src/planner/CachedSet.cpp",
65 "src/planner/Flattener.cpp",
Dan Stoza269dc4d2021-01-15 15:07:43 -080066 "src/planner/LayerState.cpp",
67 "src/planner/Planner.cpp",
Dan Stoza47437bb2021-01-15 16:21:07 -080068 "src/planner/Predictor.cpp",
Alec Mouridf6201b2021-06-01 16:20:42 -070069 "src/planner/TexturePool.cpp",
Vishnu Nair9b079a22020-01-21 14:36:08 -080070 "src/ClientCompositionRequestCache.cpp",
Lloyd Pique70d91362018-10-18 16:02:55 -070071 "src/CompositionEngine.cpp",
Lloyd Pique45a165a2018-10-19 11:54:47 -070072 "src/Display.cpp",
Lloyd Pique3d0c02e2018-10-19 18:38:12 -070073 "src/DisplayColorProfile.cpp",
Lloyd Pique542307f2018-10-19 13:24:08 -070074 "src/DisplaySurface.cpp",
Lloyd Pique32cbe282018-10-19 13:09:22 -070075 "src/DumpHelpers.cpp",
Vishnu Naira3140382022-02-24 14:07:11 -080076 "src/HwcAsyncWorker.cpp",
Lloyd Pique76ed7032018-12-04 17:24:28 -080077 "src/HwcBufferCache.cpp",
Lloyd Pique9755fb72019-03-26 14:44:40 -070078 "src/LayerFECompositionState.cpp",
Lloyd Pique32cbe282018-10-19 13:09:22 -070079 "src/Output.cpp",
80 "src/OutputCompositionState.cpp",
Lloyd Piquecc01a452018-12-04 17:24:00 -080081 "src/OutputLayer.cpp",
Lloyd Pique37c2c9b2018-12-04 17:25:10 -080082 "src/OutputLayerCompositionState.cpp",
Lloyd Pique31cb2942018-10-19 17:23:03 -070083 "src/RenderSurface.cpp",
Lloyd Pique70d91362018-10-18 16:02:55 -070084 ],
85 local_include_dirs: ["include"],
86 export_include_dirs: ["include"],
87}
88
89cc_library {
90 name: "libcompositionengine_mocks",
91 defaults: ["libcompositionengine_defaults"],
92 srcs: [
93 "mock/CompositionEngine.cpp",
Lloyd Pique45a165a2018-10-19 11:54:47 -070094 "mock/Display.cpp",
Lloyd Pique3d0c02e2018-10-19 18:38:12 -070095 "mock/DisplayColorProfile.cpp",
Lloyd Pique542307f2018-10-19 13:24:08 -070096 "mock/DisplaySurface.cpp",
Lloyd Piquefeb73d72018-12-04 17:23:44 -080097 "mock/LayerFE.cpp",
chaviw8beb4142019-04-11 13:09:05 -070098 "mock/NativeWindow.cpp",
Lloyd Pique32cbe282018-10-19 13:09:22 -070099 "mock/Output.cpp",
Lloyd Piquecc01a452018-12-04 17:24:00 -0800100 "mock/OutputLayer.cpp",
Lloyd Pique31cb2942018-10-19 17:23:03 -0700101 "mock/RenderSurface.cpp",
Lloyd Pique70d91362018-10-18 16:02:55 -0700102 ],
103 static_libs: [
104 "libgtest",
105 "libgmock",
106 "libcompositionengine",
107 ],
108 local_include_dirs: ["include"],
109 export_include_dirs: ["include"],
110}
111
112cc_test {
113 name: "libcompositionengine_test",
114 test_suites: ["device-tests"],
115 defaults: ["libcompositionengine_defaults"],
116 srcs: [
Ady Abrahamcf027d62021-03-02 18:48:57 -0800117 "tests/planner/CachedSetTest.cpp",
Ady Abrahamb7db4102021-03-04 12:19:26 -0800118 "tests/planner/FlattenerTest.cpp",
Alec Mourieb920d92021-03-01 17:48:30 -0800119 "tests/planner/LayerStateTest.cpp",
Alec Mourif6a684b2021-03-09 13:00:18 -0800120 "tests/planner/PredictorTest.cpp",
Alec Mouridf6201b2021-06-01 16:20:42 -0700121 "tests/planner/TexturePoolTest.cpp",
Lloyd Pique70d91362018-10-18 16:02:55 -0700122 "tests/CompositionEngineTest.cpp",
Lloyd Pique3d0c02e2018-10-19 18:38:12 -0700123 "tests/DisplayColorProfileTest.cpp",
Lloyd Pique45a165a2018-10-19 11:54:47 -0700124 "tests/DisplayTest.cpp",
Lloyd Pique76ed7032018-12-04 17:24:28 -0800125 "tests/HwcBufferCacheTest.cpp",
Lloyd Pique35d58242018-12-18 16:33:25 -0800126 "tests/MockHWC2.cpp",
Lloyd Pique441d5042018-10-18 16:49:51 -0700127 "tests/MockHWComposer.cpp",
Lloyd Pique688abd42019-02-15 15:42:24 -0800128 "tests/MockPowerAdvisor.cpp",
Lloyd Piquecc01a452018-12-04 17:24:00 -0800129 "tests/OutputLayerTest.cpp",
Marin Shalamanov68933fb2020-09-10 17:58:12 +0200130 "tests/OutputTest.cpp",
131 "tests/ProjectionSpaceTest.cpp",
Lloyd Pique31cb2942018-10-19 17:23:03 -0700132 "tests/RenderSurfaceTest.cpp",
Lloyd Pique70d91362018-10-18 16:02:55 -0700133 ],
134 static_libs: [
135 "libcompositionengine",
136 "libcompositionengine_mocks",
Lloyd Piqueaad4ebf2019-10-03 17:58:30 -0700137 "libgui_mocks",
Lloyd Piqueb97e04f2018-10-18 17:07:05 -0700138 "librenderengine_mocks",
Lloyd Pique70d91362018-10-18 16:02:55 -0700139 "libgmock",
140 "libgtest",
141 ],
142 sanitize: {
Florian Mayerd3fe83a2023-09-13 14:19:28 -0700143 hwaddress: true,
Lloyd Pique70d91362018-10-18 16:02:55 -0700144 },
145}