1//
2// Copyright (C) 2020 The Android Open Source Project
3//
4// Licensed under the Apache License, Version 2.0 (the "License");
5// you may not use this file except in compliance with the License.
6// You may obtain a copy of the License at
7//
8//      http://www.apache.org/licenses/LICENSE-2.0
9//
10// Unless required by applicable law or agreed to in writing, software
11// distributed under the License is distributed on an "AS IS" BASIS,
12// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13// See the License for the specific language governing permissions and
14// limitations under the License.
15//
16
17package {
18    default_applicable_licenses: ["Android-Apache-2.0"],
19}
20
21cc_defaults {
22    name: "dmabufheap-unit-tests-default",
23    cflags: [
24        "-Wall",
25        "-Werror",
26    ],
27    static_libs: [
28        "libc++fs",
29        "libbase",
30        "liblog",
31    ],
32    shared_libs: [
33        "libdmabufheap",
34        "libvintf",
35    ],
36    srcs: [
37        "dmabuf_heap_test.cpp",
38    ],
39}
40
41cc_test {
42    name: "dmabufheap-vts-unit-tests",
43    defaults: ["dmabufheap-unit-tests-default"],
44    test_config: "dmabufheap-vts-unit-tests.xml",
45    test_suites: [
46        "general-tests",
47        "vts",
48    ],
49}
50
51cc_test {
52    name: "dmabufheap-unit-tests",
53    defaults: ["dmabufheap-unit-tests-default"],
54    test_suites: [
55        "device-tests",
56    ],
57    require_root: true,
58}
59
60cc_test {
61    name: "dmabufheaptest",
62    srcs: ["dmabuf_heap_test.c"],
63    static_libs: [
64        "libion",
65        "libdmabufheap",
66        "liblog",
67        "libbase",
68    ],
69    cflags: [
70        "-Werror",
71        "-Wall",
72        "-Wextra",
73    ],
74}
75
76cc_test {
77    name: "dmabuf-heap-bench",
78    srcs: ["dmabuf_heap_bench.c"],
79    static_libs: [
80        "libion",
81        "liblog",
82        "libbase",
83    ],
84    cflags: [
85        "-Werror",
86        "-Wall",
87        "-Wextra",
88    ],
89}
90