blob: 054053898c388e993ba710d688c7f26b3e2cbeb2 [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
Peiyong Lincbc184f2018-08-22 13:24:10 -070010cc_defaults {
11 name: "renderengine_defaults",
12 cflags: [
13 "-DLOG_TAG=\"RenderEngine\"",
14 "-Wall",
15 "-Werror",
16 "-Wthread-safety",
17 "-Wunused",
18 "-Wunreachable-code",
19 ],
Peiyong Lincbc184f2018-08-22 13:24:10 -070020}
21
22cc_defaults {
23 name: "librenderengine_defaults",
Sally Qi6920a2f2022-08-26 10:40:05 -070024 defaults: [
25 "android.hardware.graphics.composer3-ndk_shared",
26 "renderengine_defaults",
27 ],
Peiyong Lincbc184f2018-08-22 13:24:10 -070028 cflags: [
29 "-DGL_GLEXT_PROTOTYPES",
30 "-DEGL_EGLEXT_PROTOTYPES",
31 ],
32 shared_libs: [
Yiwei Zhang5434a782018-12-05 18:06:32 -080033 "libbase",
Peiyong Lincbc184f2018-08-22 13:24:10 -070034 "libcutils",
35 "libEGL",
36 "libGLESv1_CM",
37 "libGLESv2",
38 "libgui",
39 "liblog",
Peiyong Lin46080ef2018-10-26 18:43:14 -070040 "libnativewindow",
Alec Mouri16a99402019-07-29 16:37:30 -070041 "libprocessgroup",
Alec Mouri0d5e1eb2018-11-10 20:40:12 -080042 "libsync",
Peiyong Lincbc184f2018-08-22 13:24:10 -070043 "libui",
44 "libutils",
45 ],
Alec Mouri465b2962021-10-08 16:22:21 -070046
47 static_libs: [
Alec Mouri492c85c2021-11-19 15:58:10 -080048 "libshaders",
Alec Mouri465b2962021-10-08 16:22:21 -070049 "libtonemap",
50 ],
Peiyong Lincbc184f2018-08-22 13:24:10 -070051 local_include_dirs: ["include"],
52 export_include_dirs: ["include"],
53}
54
55filegroup {
56 name: "librenderengine_sources",
57 srcs: [
58 "Description.cpp",
Alec Mouria90a5702021-04-16 16:36:21 +000059 "ExternalTexture.cpp",
Peiyong Lincbc184f2018-08-22 13:24:10 -070060 "Mesh.cpp",
Peiyong Lincbc184f2018-08-22 13:24:10 -070061 "RenderEngine.cpp",
Peiyong Lincbc184f2018-08-22 13:24:10 -070062 "Texture.cpp",
63 ],
64}
65
Peiyong Lin833074a2018-08-28 11:53:54 -070066filegroup {
67 name: "librenderengine_gl_sources",
68 srcs: [
Peiyong Lin7e219eb2018-12-03 05:40:42 -080069 "gl/GLESRenderEngine.cpp",
Peiyong Lin833074a2018-08-28 11:53:54 -070070 "gl/GLExtensions.cpp",
Peiyong Line5a9a7f2018-08-30 15:32:13 -070071 "gl/GLFramebuffer.cpp",
Peiyong Linf1bada92018-08-29 09:39:31 -070072 "gl/GLImage.cpp",
Vishnu Nairf19544f2020-02-03 11:23:26 -080073 "gl/GLShadowTexture.cpp",
Vishnu Nair16efdbf2019-12-10 11:55:42 -080074 "gl/GLShadowVertexGenerator.cpp",
75 "gl/GLSkiaShadowPort.cpp",
Lucas Dupinad663372020-03-19 12:44:36 -070076 "gl/GLVertexBuffer.cpp",
Alec Mouri16a99402019-07-29 16:37:30 -070077 "gl/ImageManager.cpp",
Peiyong Lin833074a2018-08-28 11:53:54 -070078 "gl/Program.cpp",
79 "gl/ProgramCache.cpp",
Lucas Dupin19c8f0e2019-11-25 17:55:44 -080080 "gl/filters/BlurFilter.cpp",
Lucas Dupin19c8f0e2019-11-25 17:55:44 -080081 "gl/filters/GenericProgram.cpp",
Peiyong Lin833074a2018-08-28 11:53:54 -070082 ],
83}
84
Ana Krulec9bc9dc62020-02-26 12:16:40 -080085filegroup {
86 name: "librenderengine_threaded_sources",
87 srcs: [
88 "threaded/RenderEngineThreaded.cpp",
89 ],
90}
91
John Reck67b1e2b2020-08-26 13:17:24 -070092filegroup {
93 name: "librenderengine_skia_sources",
94 srcs: [
Alec Mouric7f6c8b2020-11-09 18:35:20 -080095 "skia/AutoBackendTexture.cpp",
Leon Scroggins IIIb9216dc2021-03-08 17:19:01 -050096 "skia/Cache.cpp",
Alec Mouric0aae732021-01-12 13:32:18 -080097 "skia/ColorSpaces.cpp",
John Reck67b1e2b2020-08-26 13:17:24 -070098 "skia/SkiaRenderEngine.cpp",
99 "skia/SkiaGLRenderEngine.cpp",
Ana Krulec70d15b1b2020-12-01 10:05:15 -0800100 "skia/debug/CaptureTimer.cpp",
101 "skia/debug/CommonPool.cpp",
102 "skia/debug/SkiaCapture.cpp",
Derek Sollenberger0e6d3562021-04-07 19:34:39 -0400103 "skia/debug/SkiaMemoryReporter.cpp",
Robin Lee26dacab2021-08-09 14:31:01 +0200104 "skia/filters/BlurFilter.cpp",
105 "skia/filters/GaussianBlurFilter.cpp",
Robin Lee026680a2021-07-26 12:49:53 +0200106 "skia/filters/KawaseBlurFilter.cpp",
Alec Mouri029d1952020-10-12 10:37:08 -0700107 "skia/filters/LinearEffect.cpp",
Alec Mouri465b2962021-10-08 16:22:21 -0700108 "skia/filters/StretchShaderFactory.cpp",
John Reck67b1e2b2020-08-26 13:17:24 -0700109 ],
110}
111
Peiyong Lincbc184f2018-08-22 13:24:10 -0700112cc_library_static {
113 name: "librenderengine",
114 defaults: ["librenderengine_defaults"],
115 double_loadable: true,
Peiyong Lincbc184f2018-08-22 13:24:10 -0700116 cflags: [
117 "-fvisibility=hidden",
118 "-Werror=format",
Ana Krulec70d15b1b2020-12-01 10:05:15 -0800119 "-Wno-unused-parameter",
Peiyong Lincbc184f2018-08-22 13:24:10 -0700120 ],
Peiyong Lincbc184f2018-08-22 13:24:10 -0700121 srcs: [
122 ":librenderengine_sources",
Peiyong Lin833074a2018-08-28 11:53:54 -0700123 ":librenderengine_gl_sources",
Ana Krulec9bc9dc62020-02-26 12:16:40 -0800124 ":librenderengine_threaded_sources",
John Reck67b1e2b2020-08-26 13:17:24 -0700125 ":librenderengine_skia_sources",
Peiyong Lincbc184f2018-08-22 13:24:10 -0700126 ],
Long Ling317c3f02022-02-02 14:09:24 -0800127 header_libs: [
128 "libtonemap_headers",
129 ],
Derek Sollenbergerc8d959d2021-02-10 12:53:02 -0500130 include_dirs: [
131 "external/skia/src/gpu",
132 ],
Leon Scroggins IIIe4169c82021-04-28 11:31:50 -0400133 whole_static_libs: ["libskia_renderengine"],
Peiyong Lincbc184f2018-08-22 13:24:10 -0700134 lto: {
135 thin: true,
136 },
137}
Lloyd Pique3823e7b2018-10-18 16:58:10 -0700138
139cc_library_static {
140 name: "librenderengine_mocks",
141 defaults: ["librenderengine_defaults"],
142 srcs: [
143 "mock/Framebuffer.cpp",
144 "mock/Image.cpp",
145 "mock/RenderEngine.cpp",
146 ],
147 static_libs: [
148 "libgtest",
149 "libgmock",
150 ],
151 local_include_dirs: ["include"],
152 export_include_dirs: ["include"],
153}