1// Copyright (C) 2018 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
15package {
16    // See: http://go/android-license-faq
17    // A large-scale-change added 'default_applicable_licenses' to import
18    // all of the 'license_kinds' from "frameworks_native_license"
19    // to get the below license kinds:
20    //   SPDX-license-identifier-Apache-2.0
21    default_applicable_licenses: ["frameworks_native_license"],
22    default_team: "trendy_team_android_core_graphics_stack",
23}
24
25cc_test {
26    name: "SurfaceFlinger_test",
27    defaults: [
28        "android.hardware.graphics.common-ndk_shared",
29        "surfaceflinger_defaults",
30        "libsurfaceflinger_common_test_deps",
31    ],
32    test_suites: ["device-tests"],
33    srcs: [
34        "BootDisplayMode_test.cpp",
35        "Binder_test.cpp",
36        "BufferGenerator.cpp",
37        "Credentials_test.cpp",
38        "DereferenceSurfaceControl_test.cpp",
39        "DisplayConfigs_test.cpp",
40        "DisplayEventReceiver_test.cpp",
41        "Dumpsys_test.cpp",
42        "EffectLayer_test.cpp",
43        "HdrSdrRatioOverlay_test.cpp",
44        "InvalidHandles_test.cpp",
45        "LayerCallback_test.cpp",
46        "LayerRenderTypeTransaction_test.cpp",
47        "LayerState_test.cpp",
48        "LayerTransaction_test.cpp",
49        "LayerTrustedPresentationListener_test.cpp",
50        "LayerTypeAndRenderTypeTransaction_test.cpp",
51        "LayerTypeTransaction_test.cpp",
52        "LayerUpdate_test.cpp",
53        "MirrorLayer_test.cpp",
54        "MultiDisplayLayerBounds_test.cpp",
55        "RefreshRateOverlay_test.cpp",
56        "RelativeZ_test.cpp",
57        "ReleaseBufferCallback_test.cpp",
58        "ScreenCapture_test.cpp",
59        "SetFrameRate_test.cpp",
60        "SetGeometry_test.cpp",
61        "Stress_test.cpp",
62        "TextureFiltering_test.cpp",
63        "VirtualDisplay_test.cpp",
64        "WindowInfosListener_test.cpp",
65    ],
66    data: ["SurfaceFlinger_test.filter"],
67    static_libs: [
68        "liblayers_proto",
69        "android.hardware.graphics.composer@2.1",
70        "libsurfaceflinger_common",
71    ],
72    shared_libs: [
73        "android.hardware.graphics.common@1.2",
74        "libandroid",
75        "libbase",
76        "libbinder",
77        "libcutils",
78        "libEGL",
79        "libGLESv2",
80        "libgui",
81        "liblog",
82        "libnativewindow",
83        "libprotobuf-cpp-full",
84        "libui",
85        "libutils",
86        "server_configurable_flags",
87    ],
88    header_libs: [
89        "libnativewindow_headers",
90    ],
91}
92
93cc_defaults {
94    name: "ipc_defaults",
95    cflags: [
96        "-Wall",
97        "-Werror",
98    ],
99}
100
101cc_test {
102    name: "IPC_test",
103    defaults: ["ipc_defaults"],
104    test_suites: ["device-tests"],
105    srcs: [
106        "BufferGenerator.cpp",
107        "IPC_test.cpp",
108    ],
109    cppflags: [
110        "-Wall",
111        "-Werror",
112        "-Wformat",
113        "-Wthread-safety",
114        "-Wunused",
115        "-Wunreachable-code",
116    ],
117    shared_libs: [
118        "libandroid",
119        "libbinder",
120        "libcutils",
121        "libEGL",
122        "libGLESv2",
123        "libgui",
124        "liblayers_proto",
125        "liblog",
126        "libprotobuf-cpp-full",
127        "libui",
128        "libutils",
129    ],
130    cpp_std: "experimental",
131    gnu_extensions: false,
132    data: [
133        ":SurfaceFlinger_test",
134    ],
135}
136
137subdirs = [
138    "hwc2",
139    "unittests",
140    "utils",
141    "vsync",
142    "waitforvsync",
143]
144