xref: /third_party/opencl-headers/tests/BUILD.gn (revision 80d59932)
1# Copyright (c) 2022 Huawei Device Co., Ltd.
2# Licensed under the Apache License, Version 2.0 (the "License");
3# you may not use this file except in compliance with the License.
4# You may obtain a copy of the License at
5#
6#     http://www.apache.org/licenses/LICENSE-2.0
7#
8# Unless required by applicable law or agreed to in writing, software
9# distributed under the License is distributed on an "AS IS" BASIS,
10# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
11# See the License for the specific language governing permissions and
12# limitations under the License.
13
14import("//build/ohos.gni")
15
16config("cl_test_config") {
17  visibility = [ "*" ]
18  include_dirs = [
19    "../",
20    "include",
21  ]
22}
23
24ohos_executable("test_cl_egl") {
25  sources = [ "test_cl_egl.h.c" ]
26  configs = [ ":cl_test_config" ]
27  part_name = "opencl-headers"
28  subsystem_name = "thirdparty"
29}
30
31ohos_executable("test_cl_ext_intel") {
32  sources = [ "test_cl_ext_intel.h.c" ]
33  configs = [ ":cl_test_config" ]
34  part_name = "opencl-headers"
35  subsystem_name = "thirdparty"
36}
37
38ohos_executable("test_cl_ext") {
39  sources = [ "test_cl_ext.h.c" ]
40  configs = [ ":cl_test_config" ]
41  part_name = "opencl-headers"
42  subsystem_name = "thirdparty"
43}
44
45ohos_executable("test_cl_gl_ext") {
46  sources = [ "test_cl_gl_ext.h.c" ]
47  configs = [ ":cl_test_config" ]
48  part_name = "opencl-headers"
49  subsystem_name = "thirdparty"
50}
51
52ohos_executable("test_cl_gl") {
53  sources = [ "test_cl_gl.h.c" ]
54  configs = [ ":cl_test_config" ]
55  part_name = "opencl-headers"
56  subsystem_name = "thirdparty"
57}
58
59ohos_executable("test_cl_half") {
60  sources = [ "test_cl_half.h.c" ]
61  configs = [ ":cl_test_config" ]
62  part_name = "opencl-headers"
63  subsystem_name = "thirdparty"
64}
65
66ohos_executable("test_cl_icd") {
67  sources = [ "test_cl_icd.h.c" ]
68  configs = [ ":cl_test_config" ]
69  part_name = "opencl-headers"
70  subsystem_name = "thirdparty"
71}
72
73ohos_executable("test_cl_platform") {
74  sources = [ "test_cl_platform.h.c" ]
75  configs = [ ":cl_test_config" ]
76  part_name = "opencl-headers"
77  subsystem_name = "thirdparty"
78}
79
80ohos_executable("test_cl_version") {
81  sources = [ "test_cl_version.h.c" ]
82  configs = [ ":cl_test_config" ]
83  part_name = "opencl-headers"
84  subsystem_name = "thirdparty"
85}
86
87ohos_executable("test_cl") {
88  sources = [ "test_cl.h.c" ]
89  configs = [ ":cl_test_config" ]
90  part_name = "opencl-headers"
91  subsystem_name = "thirdparty"
92}
93
94ohos_executable("test_headers") {
95  sources = [ "test_headers.c" ]
96  configs = [ ":cl_test_config" ]
97  part_name = "opencl-headers"
98  subsystem_name = "thirdparty"
99}
100
101ohos_executable("test_opencl") {
102  sources = [ "test_opencl.h.c" ]
103  configs = [ ":cl_test_config" ]
104  part_name = "opencl-headers"
105  subsystem_name = "thirdparty"
106}
107
108ohos_executable("test_cl_d3d10") {
109  sources = [ "test_cl_d3d10.h.c" ]
110  configs = [ ":cl_test_config" ]
111  part_name = "opencl-headers"
112  subsystem_name = "thirdparty"
113}
114
115ohos_executable("test_cl_d3d11") {
116  sources = [ "test_cl_d3d11.h.c" ]
117  configs = [ ":cl_test_config" ]
118  part_name = "opencl-headers"
119  subsystem_name = "thirdparty"
120}
121
122ohos_executable("test_cl_dx9_media_sharing") {
123  sources = [ "test_cl_dx9_media_sharing.h.c" ]
124  configs = [ ":cl_test_config" ]
125  part_name = "opencl-headers"
126  subsystem_name = "thirdparty"
127}
128
129ohos_executable("test_cl_dx9_media_sharing_intel") {
130  sources = [ "test_cl_dx9_media_sharing_intel.h.c" ]
131  configs = [ ":cl_test_config" ]
132  part_name = "opencl-headers"
133  subsystem_name = "thirdparty"
134}
135
136ohos_executable("test_cl_layer") {
137  sources = [ "test_cl_layer.h.c" ]
138  configs = [ ":cl_test_config" ]
139  part_name = "opencl-headers"
140  subsystem_name = "thirdparty"
141}
142
143group("tests") {
144  deps = [
145    ":test_cl",
146    ":test_cl_d3d10",
147    ":test_cl_d3d11",
148    ":test_cl_dx9_media_sharing",
149    ":test_cl_dx9_media_sharing_intel",
150    ":test_cl_egl",
151    ":test_cl_ext",
152    ":test_cl_ext_intel",
153    ":test_cl_gl",
154    ":test_cl_gl_ext",
155    ":test_cl_half",
156    ":test_cl_icd",
157    ":test_cl_layer",
158    ":test_cl_platform",
159    ":test_cl_version",
160    ":test_headers",
161    ":test_opencl",
162  ]
163}
164