From 25b95f1c46d9a36f261cd2b1e0cb4a22409ebae5 Mon Sep 17 00:00:00 2001 From: Zhao-PengFei35 Date: Sun, 23 Apr 2023 11:08:16 +0800 Subject: [PATCH] =?UTF-8?q?=E9=83=A8=E4=BB=B6=E5=8C=96=E6=95=B4=E6=94=B9?= =?UTF-8?q?=EF=BC=8C=E4=BF=AE=E6=94=B9part=5Fname?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Zhao-PengFei35 --- BUILD.gn | 8 ++-- tests/BUILD.gn | 102 +++++++++++++++++++------------------------------ 2 files changed, 42 insertions(+), 68 deletions(-) diff --git a/BUILD.gn b/BUILD.gn index 3142e76..e1a050f 100644 --- a/BUILD.gn +++ b/BUILD.gn @@ -30,17 +30,15 @@ config("cl_public_config") { ohos_shared_library("libcl") { visibility = [ "*" ] - sources = [ - "src/opencl_wrapper.cpp", - ] + sources = [ "src/opencl_wrapper.cpp" ] configs = [ ":cl_config" ] public_configs = [ ":cl_public_config" ] output_name = "OpenCL" output_extension = "so" - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } group("cl_tests") { deps = [ "tests:tests" ] -} \ No newline at end of file +} diff --git a/tests/BUILD.gn b/tests/BUILD.gn index 0885c9c..182f746 100644 --- a/tests/BUILD.gn +++ b/tests/BUILD.gn @@ -22,126 +22,102 @@ config("cl_test_config") { } ohos_executable("test_cl_egl") { - sources = [ - "test_cl_egl.h.c", - ] + sources = [ "test_cl_egl.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_ext_intel") { - sources = [ - "test_cl_ext_intel.h.c", - ] + sources = [ "test_cl_ext_intel.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_ext") { - sources = [ - "test_cl_ext.h.c", - ] + sources = [ "test_cl_ext.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_gl_ext") { - sources = [ - "test_cl_gl_ext.h.c", - ] + sources = [ "test_cl_gl_ext.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_gl") { - sources = [ - "test_cl_gl.h.c", - ] + sources = [ "test_cl_gl.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_half") { - sources = [ - "test_cl_half.h.c", - ] + sources = [ "test_cl_half.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_icd") { - sources = [ - "test_cl_icd.h.c", - ] + sources = [ "test_cl_icd.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_platform") { - sources = [ - "test_cl_platform.h.c", - ] + sources = [ "test_cl_platform.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl_version") { - sources = [ - "test_cl_version.h.c", - ] + sources = [ "test_cl_version.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_cl") { - sources = [ - "test_cl.h.c", - ] + sources = [ "test_cl.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_headers") { - sources = [ - "test_headers.c", - ] + sources = [ "test_headers.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } ohos_executable("test_opencl") { - sources = [ - "test_opencl.h.c", - ] + sources = [ "test_opencl.h.c" ] configs = [ ":cl_test_config" ] - part_name = "opencl" + part_name = "opencl-headers" subsystem_name = "thirdparty" } group("tests") { - deps = [ - ":test_cl_egl", - ":test_cl_ext_intel", - ":test_cl_ext", - ":test_cl_gl_ext", - ":test_cl_gl", - ":test_cl_half", - ":test_cl_icd", - ":test_cl_platform", - ":test_cl_version", - ":test_cl", - ":test_headers", - ":test_opencl", - ] -} \ No newline at end of file + deps = [ + ":test_cl", + ":test_cl_egl", + ":test_cl_ext", + ":test_cl_ext_intel", + ":test_cl_gl", + ":test_cl_gl_ext", + ":test_cl_half", + ":test_cl_icd", + ":test_cl_platform", + ":test_cl_version", + ":test_headers", + ":test_opencl", + ] +}