1# Copyright (c) 2022 Shenzhen Kaihong Digital Industry Development 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 14# external modules common build 15 16import("//build/ohos.gni") 17import("//third_party/vk-gl-cts/vk_gl_cts.gni") 18 19config("glcts-common_config") { 20 cflags_cc = [ 21 "-Wno-conversion", 22 "-Wno-unused-function", 23 ] 24 25 cflags_cc += deqp_common_cflags_cc 26 defines = deqp_common_defines 27} 28 29ohos_source_set("glcts-common_source") { 30 sources = [ 31 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcAggressiveShaderOptimizationsTests.cpp", 32 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcBlendEquationAdvancedTests.cpp", 33 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcCompressedFormatTests.cpp", 34 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcConfigList.cpp", 35 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcConfigListCase.cpp", 36 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcConfigListEGL.cpp", 37 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcConfigListWGL.cpp", 38 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcConfigPackage.cpp", 39 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcContext.cpp", 40 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcContextFlagsTests.cpp", 41 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcExposedExtensionsTests.cpp", 42 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcExtTokens.cpp", 43 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcFragDepthTests.cpp", 44 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcFramebufferCompleteness.cpp", 45 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcGLSLVectorConstructorTests.cpp", 46 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcInfoTests.cpp", 47 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcInternalformatTests.cpp", 48 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcKHRDebugTests.cpp", 49 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcLayoutLocationTests.cpp", 50 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcMisc.cpp", 51 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcMultipleContextsTests.cpp", 52 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcNearestEdgeTests.cpp", 53 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcNoErrorTests.cpp", 54 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcPackedDepthStencilTests.cpp", 55 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcPackedPixelsTests.cpp", 56 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcParallelShaderCompileTests.cpp", 57 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcPixelStorageModesTests.cpp", 58 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcPolygonOffsetClampTests.cpp", 59 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcRobustBufferAccessBehaviorTests.cpp", 60 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcRobustnessTests.cpp", 61 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcSampleVariablesTests.cpp", 62 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcSeparableProgramsTransformFeedbackTests.cpp", 63 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderConstExprTests.cpp", 64 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderGroupVoteTests.cpp", 65 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderIndexingTests.cpp", 66 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderIntegerMixTests.cpp", 67 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderLibrary.cpp", 68 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderLibraryCase.cpp", 69 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderLoopTests.cpp", 70 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderMacroTests.cpp", 71 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderMultisampleInterpolationTests.cpp", 72 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderNegativeTests.cpp", 73 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderRenderCase.cpp", 74 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcShaderStructTests.cpp", 75 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcSpirvUtils.cpp", 76 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTestCase.cpp", 77 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTestCaseWrapper.cpp", 78 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTestPackage.cpp", 79 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTestSubcase.cpp", 80 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTextureCompatibilityTests.cpp", 81 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTextureFilterAnisotropicTests.cpp", 82 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcTextureRepeatModeTests.cpp", 83 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcUniformBlockCase.cpp", 84 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcUniformBlockTests.cpp", 85 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcViewportArrayTests.cpp", 86 ] 87 include_dirs = [ 88 "//third_party/zlib/src", 89 "//third_party/spirv-headers/include", 90 91 #"//third_party/vk-gl-cts/external/amber", 92 #"//third_party/vk-gl-cts/external/renderdoc/src", 93 94 #"//third_party/vk-gl-cts/external/vulkancts/framework/vulkan", 95 "//third_party/vk-gl-cts/external/openglcts/include", 96 "//third_party/vk-gl-cts/external/openglcts/framework/egl/wrapper", 97 "//third_party/vk-gl-cts/external/openglcts/modules/common", 98 "//third_party/vk-gl-cts/external/openglcts/modules/gl", 99 "//third_party/vk-gl-cts/external/openglcts/modules/gles2", 100 "//third_party/vk-gl-cts/external/openglcts/modules/gles3", 101 "//third_party/vk-gl-cts/external/openglcts/modules/gles31", 102 "//third_party/vk-gl-cts/external/openglcts/modules/gles32", 103 "//third_party/vk-gl-cts/external/openglcts/modules/glesext", 104 "//third_party/vk-gl-cts/external/openglcts/modules", 105 "//third_party/vk-gl-cts/modules/glshared", 106 "//third_party/vk-gl-cts/external/openglcts/modules/common/subgroups", 107 "//third_party/glslang", 108 "//third_party/spirv-tools/include", 109 "//third_party/spirv-tools/external/include", 110 "//third_party/vk-gl-cts/build/external/vulkancts/framework/vulkan", 111 "//third_party/glslang/glslang", 112 "//third_party/vk-gl-cts/build/include", 113 "//third_party/glslang/SPIRV", 114 ] 115 include_dirs += deqp_common_include_dirs 116 117 deps = [ 118 "//third_party/glslang/OGLCompilersDLL:libdeqp_OGLCompiler", 119 "//third_party/glslang/SPIRV:libdeqp_spirv", 120 "//third_party/glslang/SPIRV:libdeqp_spvremapper", 121 "//third_party/glslang/glslang:libdeqp_GenericCodeGen", 122 "//third_party/glslang/glslang:libdeqp_MachineIndependent", 123 "//third_party/glslang/glslang:libdeqp_OSDependent", 124 "//third_party/glslang/glslang:libdeqp_glslang", 125 "//third_party/libpng:libpng", 126 "//third_party/spirv-tools:libdeqp_spirvtools", 127 "//third_party/spirv-tools/source/link:libdeqp_spirvtools-link", 128 "//third_party/spirv-tools/source/lint:libdeqp_spirvtools-lint", 129 "//third_party/spirv-tools/source/opt:libdeqp_spirvtools-opt", 130 "//third_party/spirv-tools/source/reduce:libdeqp_spirvtools-reduce", 131 "//third_party/vk-gl-cts/external/openglcts/modules/common/subgroups:libdeqp-gl-subgroups", 132 "//third_party/vk-gl-cts/framework/common:libdeqp_tcutil", 133 "//third_party/vk-gl-cts/framework/egl:libdeqp_eglutil", 134 "//third_party/vk-gl-cts/framework/opengl:libdeqp_glutil", 135 ] 136 137 # lib_dirs = [ 138 # "//third_party/vk-gl-cts/outlibs" 139 # ] 140 # libs = [ 141 # "glslang", 142 # "SPIRV", 143 # "SPVRemapper", 144 # "spirv-tools", 145 # "spirv-tools-link", 146 # "spirv-tools-lint", 147 # "spirv-tools-opt", 148 # "spirv-tools-reduce", 149 # "MachineIndependent", 150 # "OGLCompiler", 151 # "OSDependent", 152 # "GenericCodeGen", 153 # ] 154 155 configs = [ ":glcts-common_config" ] 156} 157 158ohos_static_library("libdeqp_glcts-common") { 159 deps = [ ":glcts-common_source" ] 160 part_name = "graphic_2d" 161 subsystem_name = "graphic" 162} 163 164ohos_source_set("glcts-common-nocontext-package_source") { 165 sources = [ 166 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcNoDefaultContextPackage.cpp", 167 "//third_party/vk-gl-cts/external/openglcts/modules/common/glcSingleConfigTestPackage.cpp", 168 ] 169 include_dirs = [ 170 "//third_party/zlib/src", 171 "//third_party/spirv-headers/include", 172 173 #"//third_party/vk-gl-cts/external/amber", 174 #"//third_party/vk-gl-cts/external/renderdoc/src", 175 176 #"//third_party/vk-gl-cts/external/vulkancts/framework/vulkan", 177 "//third_party/vk-gl-cts/external/openglcts/include", 178 "//third_party/vk-gl-cts/external/openglcts/framework/egl/wrapper", 179 "//third_party/vk-gl-cts/external/openglcts/modules/common", 180 "//third_party/vk-gl-cts/external/openglcts/modules/gl", 181 "//third_party/vk-gl-cts/external/openglcts/modules/gles2", 182 "//third_party/vk-gl-cts/external/openglcts/modules/gles3", 183 "//third_party/vk-gl-cts/external/openglcts/modules/gles31", 184 "//third_party/vk-gl-cts/external/openglcts/modules/gles32", 185 "//third_party/vk-gl-cts/external/openglcts/modules/glesext", 186 "//third_party/vk-gl-cts/external/openglcts/modules/.", 187 "//third_party/vk-gl-cts/modules/glshared", 188 "//third_party/vk-gl-cts/external/openglcts/modules/common/subgroups", 189 "//third_party/glslang", 190 "//third_party/spirv-tools/include", 191 "//third_party/spirv-tools/external/include", 192 "//third_party/vk-gl-cts/build/external/vulkancts/framework/vulkan", 193 ] 194 include_dirs += deqp_common_include_dirs 195 196 deps = [ 197 "//third_party/libpng:libpng", 198 "//third_party/vk-gl-cts/framework/common:libdeqp_tcutil", 199 "//third_party/vk-gl-cts/framework/egl:libdeqp_eglutil", 200 "//third_party/vk-gl-cts/framework/opengl:libdeqp_glutil", 201 ] 202 203 configs = [ ":glcts-common_config" ] 204} 205 206ohos_static_library("libdeqp_glcts-common-nocontext-package") { 207 deps = [ ":glcts-common-nocontext-package_source" ] 208 part_name = "graphic_2d" 209 subsystem_name = "graphic" 210} 211