зеркало из https://github.com/AvaloniaUI/angle.git
Revert "Re-land "Vulkan: Roll loader/validation layers SDK. (2/2)""
This reverts commit 755a9317ff
.
Reason for revert: Broke local win build. crbug.com/797253
Original change's description:
> Re-land "Vulkan: Roll loader/validation layers SDK. (2/2)"
>
> Re-landing with upstream fixes to the layers so they no longer
> need to copy the parameter validation errors to the current
> working directory of the layer generation. Also includes fixes
> for the GCC build.
>
> This hasn't been updated in a while, so there are many changes.
> It should also include better validation for memory barriers.
>
> Also includes updated builds for SPIRV Tools and glslang.
> A few pull requests need to land before landing this in ANGLE.
>
> This second step re-enables Vulkan and includes the updated build.
>
> Includes a workaround for parameter_validation.h no longer being
> auto-generated, and the stale file clobbering the build.
>
> Also includes a fix for an incorrect memory barrier.
>
> Bug: angleproject:2237
> Change-Id: I1ed87ecfa84f51ee1edf6a8581d9b3c8f9a6f26e
> Reviewed-on: https://chromium-review.googlesource.com/834429
> Commit-Queue: Jamie Madill <jmadill@chromium.org>
> Reviewed-by: Jamie Madill <jmadill@chromium.org>
TBR=fjhenigman@chromium.org,jmadill@chromium.org
Change-Id: I605d72207d64c7d0853678595e255b74ad69d887
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: angleproject:2237
Reviewed-on: https://chromium-review.googlesource.com/842918
Reviewed-by: Zhenyao Mo <zmo@chromium.org>
Commit-Queue: Zhenyao Mo <zmo@chromium.org>
This commit is contained in:
Родитель
2b7bbc2822
Коммит
06f8637740
|
@ -29,13 +29,17 @@ if (is_win) {
|
|||
angle_enable_d3d11 = true
|
||||
angle_enable_gl = true
|
||||
angle_enable_gl_null = true
|
||||
angle_enable_vulkan = true
|
||||
|
||||
# TODO(jmadill): Re-enable after roll.
|
||||
# angle_enable_vulkan = true
|
||||
|
||||
import("//build/config/win/visual_studio_version.gni")
|
||||
} else if (is_linux && use_x11 && !is_chromeos) {
|
||||
angle_enable_gl = true
|
||||
angle_enable_gl_null = true
|
||||
angle_enable_vulkan = true
|
||||
|
||||
# TODO(jmadill): Re-enable after roll.
|
||||
# angle_enable_vulkan = true
|
||||
} else if (is_mac || ozone_platform_gbm) {
|
||||
angle_enable_gl = true
|
||||
angle_enable_gl_null = true
|
||||
|
|
|
@ -29,13 +29,8 @@ for json_fname in glob.glob(os.path.join(source_dir, "*.json")):
|
|||
data = json.load(infile)
|
||||
|
||||
# update the path
|
||||
if not 'layer' in data:
|
||||
raise Exception("Could not find a layer key in " + json_fname)
|
||||
|
||||
# The standard validation layer has no library path.
|
||||
if 'library_path' in data['layer']:
|
||||
prev_name = os.path.basename(data['layer']['library_path'])
|
||||
data['layer']['library_path'] = prev_name
|
||||
prev_name = os.path.basename(data['layer']['library_path'])
|
||||
data['layer']['library_path'] = prev_name
|
||||
|
||||
target_fname = os.path.join(target_dir, os.path.basename(json_fname))
|
||||
with open(target_fname, "w") as outfile:
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
#!/usr/bin/python2
|
||||
#
|
||||
# Copyright 2017 The ANGLE Project Authors. All rights reserved.
|
||||
# Use of this source code is governed by a BSD-style license that can be
|
||||
# found in the LICENSE file.
|
||||
#
|
||||
# remove_file_if_exists.py:
|
||||
# This special action is needed to remove generated headers.
|
||||
# Otherwise ANGLE will pick up the old file(s) and the build will fail.
|
||||
#
|
||||
|
||||
import sys
|
||||
import os
|
||||
|
||||
if len(sys.argv) < 3:
|
||||
print("Usage: " + sys.argv[0] + " <remove_file> <stamp_file>")
|
||||
|
||||
remove_file = sys.argv[1]
|
||||
if os.path.isfile(remove_file):
|
||||
os.remove(remove_file)
|
||||
|
||||
# touch a dummy file to keep a timestamp
|
||||
with open(sys.argv[2], "w") as f:
|
||||
f.write("blah")
|
||||
f.close()
|
|
@ -211,7 +211,7 @@ vk::Error BufferVk::setDataImpl(ContextVk *contextVk,
|
|||
bufferBarrier.size = static_cast<VkDeviceSize>(size);
|
||||
|
||||
commandBuffer->singleBufferBarrier(VK_PIPELINE_STAGE_ALL_COMMANDS_BIT,
|
||||
VK_PIPELINE_STAGE_TRANSFER_BIT, 0, bufferBarrier);
|
||||
VK_PIPELINE_STAGE_TOP_OF_PIPE_BIT, 0, bufferBarrier);
|
||||
|
||||
VkBufferCopy copyRegion = {offset, 0, size};
|
||||
commandBuffer->copyBuffer(stagingBuffer.getBuffer(), mBuffer, 1, ©Region);
|
||||
|
|
|
@ -31,7 +31,6 @@ if (is_win) {
|
|||
|
||||
vulkan_gen_dir = "$target_gen_dir/angle/vulkan"
|
||||
raw_vulkan_gen_dir = rebase_path(vulkan_gen_dir, root_build_dir)
|
||||
raw_spirv_tools_dir = rebase_path(spirv_tools_dir, root_build_dir)
|
||||
|
||||
# Vulkan helper scripts
|
||||
# ---------------------
|
||||
|
@ -47,11 +46,6 @@ helper_script_and_deps = [
|
|||
"vk_enum_string_helper.h",
|
||||
"helper_file_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_extension_helper",
|
||||
"vk_extension_helper.h",
|
||||
"helper_file_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_layer_dispatch_table_h",
|
||||
"vk_layer_dispatch_table.h",
|
||||
|
@ -67,11 +61,6 @@ helper_script_and_deps = [
|
|||
"vk_loader_extensions.h",
|
||||
"loader_extension_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_object_types_h",
|
||||
"vk_object_types.h",
|
||||
"helper_file_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_safe_struct_cpp",
|
||||
"vk_safe_struct.cpp",
|
||||
|
@ -98,18 +87,8 @@ helper_script_and_deps = [
|
|||
"threading_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_typemap_helper",
|
||||
"vk_typemap_helper.h",
|
||||
"helper_file_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_object_tracker_cpp",
|
||||
"object_tracker.cpp",
|
||||
"object_tracker_generator.py",
|
||||
],
|
||||
[
|
||||
"vulkan_gen_parameter_validation_cpp",
|
||||
"parameter_validation.cpp",
|
||||
"vulkan_gen_parameter_validation_helper",
|
||||
"parameter_validation.h",
|
||||
"parameter_validation_generator.py",
|
||||
],
|
||||
[
|
||||
|
@ -145,23 +124,6 @@ foreach(script_and_dep, helper_script_and_deps) {
|
|||
}
|
||||
}
|
||||
|
||||
# This could be generalized to a foreach if other revisions are added.
|
||||
action("spirv_tools_external_revision_generate") {
|
||||
script = "$vulkan_layers_dir/scripts/external_revision_generator.py"
|
||||
inputs = [
|
||||
"$spirv_tools_dir/.git/HEAD",
|
||||
"$spirv_tools_dir/.git/index",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/spirv_tools_commit_id.h",
|
||||
]
|
||||
args = [
|
||||
"$raw_spirv_tools_dir",
|
||||
"SPIRV_TOOLS_COMMIT_ID",
|
||||
"$raw_vulkan_gen_dir/spirv_tools_commit_id.h",
|
||||
]
|
||||
}
|
||||
|
||||
config("vulkan_generate_helper_files_config") {
|
||||
include_dirs = [
|
||||
vulkan_gen_dir,
|
||||
|
@ -170,9 +132,7 @@ config("vulkan_generate_helper_files_config") {
|
|||
}
|
||||
|
||||
group("vulkan_generate_helper_files") {
|
||||
public_deps = [
|
||||
":spirv_tools_external_revision_generate",
|
||||
]
|
||||
public_deps = []
|
||||
public_configs = [ ":vulkan_generate_helper_files_config" ]
|
||||
foreach(script_and_dep, helper_script_and_deps) {
|
||||
target_name = script_and_dep[0]
|
||||
|
@ -252,9 +212,6 @@ static_library("vulkan_loader") {
|
|||
"$vulkan_layers_dir/loader/murmurhash.h",
|
||||
"$vulkan_layers_dir/loader/phys_dev_ext.c",
|
||||
"$vulkan_layers_dir/loader/trampoline.c",
|
||||
|
||||
# TODO(jmadill): Use assembler where available.
|
||||
"$vulkan_layers_dir/loader/unknown_ext_chain.c",
|
||||
"$vulkan_layers_dir/loader/vk_loader_platform.h",
|
||||
"$vulkan_layers_dir/loader/wsi.c",
|
||||
"$vulkan_layers_dir/loader/wsi.h",
|
||||
|
@ -299,77 +256,43 @@ raw_spirv_source_dir = rebase_path(spirv_source_dir, root_build_dir)
|
|||
raw_spirv_include_dir = rebase_path(spirv_include_dir, root_build_dir)
|
||||
raw_spirv_headers_dir = rebase_path(spirv_headers_dir, root_build_dir)
|
||||
|
||||
grammar_processing_script = "$spirv_tools_dir/utils/generate_grammar_tables.py"
|
||||
|
||||
action("spirv_tools_gen_enum_string_mapping") {
|
||||
script = grammar_processing_script
|
||||
sources = [
|
||||
"$spirv_include_dir/1.2/spirv.core.grammar.json",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/extension_enum.inc",
|
||||
"$vulkan_gen_dir/enum_string_mapping.inc",
|
||||
]
|
||||
args = [
|
||||
"--spirv-core-grammar=$raw_spirv_include_dir/1.2/spirv.core.grammar.json",
|
||||
"--extension-enum-output=$raw_vulkan_gen_dir/extension_enum.inc",
|
||||
"--enum-string-mapping-output=$raw_vulkan_gen_dir/enum_string_mapping.inc",
|
||||
]
|
||||
}
|
||||
|
||||
spvtools_core_tables = [
|
||||
"1.0",
|
||||
"1.1",
|
||||
"1.2",
|
||||
]
|
||||
|
||||
foreach(version, spvtools_core_tables) {
|
||||
action("spirv_tools_gen_core_tables_" + version) {
|
||||
script = grammar_processing_script
|
||||
sources = [
|
||||
"$spirv_include_dir/$version/spirv.core.grammar.json",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/core.insts-$version.inc",
|
||||
"$vulkan_gen_dir/operand.kinds-$version.inc",
|
||||
]
|
||||
args = [
|
||||
"--spirv-core-grammar=$raw_spirv_include_dir/$version/spirv.core.grammar.json",
|
||||
"--core-insts-output=$raw_vulkan_gen_dir/core.insts-$version.inc",
|
||||
"--operand-kinds-output=$raw_vulkan_gen_dir/operand.kinds-$version.inc",
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
action("spirv_tools_gen_glsl_tables") {
|
||||
script = grammar_processing_script
|
||||
action("spirv_tools_gen_tables_1_0") {
|
||||
script = "$spirv_tools_dir/utils/generate_grammar_tables.py"
|
||||
sources = [
|
||||
"$spirv_include_dir/1.0/extinst.glsl.std.450.grammar.json",
|
||||
"$spirv_include_dir/1.0/spirv.core.grammar.json",
|
||||
"$spirv_source_dir/extinst-1.0.opencl.std.grammar.json",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/core.insts-1.0.inc",
|
||||
"$vulkan_gen_dir/glsl.std.450.insts-1.0.inc",
|
||||
"$vulkan_gen_dir/opencl.std.insts-1.0.inc",
|
||||
"$vulkan_gen_dir/operand.kinds-1.0.inc",
|
||||
]
|
||||
args = [
|
||||
"--spirv-core-grammar=$raw_spirv_include_dir/1.0/spirv.core.grammar.json",
|
||||
"--extinst-glsl-grammar=$raw_spirv_include_dir/1.0/extinst.glsl.std.450.grammar.json",
|
||||
"--extinst-opencl-grammar=$raw_spirv_source_dir/extinst-1.0.opencl.std.grammar.json",
|
||||
"--core-insts-output=$raw_vulkan_gen_dir/core.insts-1.0.inc",
|
||||
"--glsl-insts-output=$raw_vulkan_gen_dir/glsl.std.450.insts-1.0.inc",
|
||||
"--opencl-insts-output=$raw_vulkan_gen_dir/opencl.std.insts-1.0.inc",
|
||||
"--operand-kinds-output=$raw_vulkan_gen_dir/operand.kinds-1.0.inc",
|
||||
]
|
||||
}
|
||||
|
||||
action("spirv_tools_gen_opencl_tables") {
|
||||
script = grammar_processing_script
|
||||
action("spirv_tools_gen_tables_1_1") {
|
||||
script = "$spirv_tools_dir/utils/generate_grammar_tables.py"
|
||||
sources = [
|
||||
"$spirv_include_dir/1.0/extinst.opencl.std.100.grammar.json",
|
||||
"$spirv_include_dir/1.0/spirv.core.grammar.json",
|
||||
"$spirv_include_dir/1.1/spirv.core.grammar.json",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/opencl.std.insts-1.0.inc",
|
||||
"$vulkan_gen_dir/core.insts-1.1.inc",
|
||||
"$vulkan_gen_dir/operand.kinds-1.1.inc",
|
||||
]
|
||||
args = [
|
||||
"--spirv-core-grammar=$raw_spirv_include_dir/1.0/spirv.core.grammar.json",
|
||||
"--extinst-opencl-grammar=$raw_spirv_include_dir/1.0/extinst.opencl.std.100.grammar.json",
|
||||
"--opencl-insts-output=$raw_vulkan_gen_dir/opencl.std.insts-1.0.inc",
|
||||
"--spirv-core-grammar=$raw_spirv_include_dir/1.1/spirv.core.grammar.json",
|
||||
"--core-insts-output=$raw_vulkan_gen_dir/core.insts-1.1.inc",
|
||||
"--operand-kinds-output=$raw_vulkan_gen_dir/operand.kinds-1.1.inc",
|
||||
]
|
||||
}
|
||||
|
||||
|
@ -387,35 +310,6 @@ action("spirv_tools_gen_generators_inc") {
|
|||
]
|
||||
}
|
||||
|
||||
spvtools_vendor_tables = [
|
||||
"spv-amd-shader-explicit-vertex-parameter",
|
||||
"spv-amd-shader-trinary-minmax",
|
||||
"spv-amd-gcn-shader",
|
||||
"spv-amd-shader-ballot",
|
||||
]
|
||||
|
||||
foreach(target_name, spvtools_vendor_tables) {
|
||||
insts_file = "$target_name.insts.inc"
|
||||
grammar_file = "extinst.$target_name.grammar.json"
|
||||
|
||||
action(target_name) {
|
||||
script = grammar_processing_script
|
||||
|
||||
sources = [
|
||||
"$spirv_source_dir/$grammar_file",
|
||||
]
|
||||
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/$insts_file",
|
||||
]
|
||||
|
||||
args = [
|
||||
"--extinst-vendor-grammar=$raw_spirv_source_dir/$grammar_file",
|
||||
"--vendor-insts-output=$raw_vulkan_gen_dir/$insts_file",
|
||||
]
|
||||
}
|
||||
}
|
||||
|
||||
config("spirv_tools_config") {
|
||||
include_dirs = [ "$spirv_tools_dir/include" ]
|
||||
if (is_win) {
|
||||
|
@ -432,13 +326,9 @@ config("spirv_tools_config") {
|
|||
|
||||
static_library("spirv_tools") {
|
||||
deps = [
|
||||
":spirv_tools_gen_core_tables_1.0",
|
||||
":spirv_tools_gen_core_tables_1.1",
|
||||
":spirv_tools_gen_core_tables_1.2",
|
||||
":spirv_tools_gen_enum_string_mapping",
|
||||
":spirv_tools_gen_generators_inc",
|
||||
":spirv_tools_gen_glsl_tables",
|
||||
":spirv_tools_gen_opencl_tables",
|
||||
":spirv_tools_gen_tables_1_0",
|
||||
":spirv_tools_gen_tables_1_1",
|
||||
]
|
||||
include_dirs = [
|
||||
vulkan_gen_dir,
|
||||
|
@ -473,17 +363,12 @@ static_library("spirv_tools") {
|
|||
|
||||
# TODO(jmadill): Determine if this is ever needed.
|
||||
#"$spirv_tools_dir/source/software_version.cpp",
|
||||
"$spirv_tools_dir/source/enum_string_mapping.cpp",
|
||||
"$spirv_tools_dir/source/extensions.cpp",
|
||||
"$spirv_tools_dir/source/extensions.h",
|
||||
"$spirv_tools_dir/source/spirv_constant.h",
|
||||
"$spirv_tools_dir/source/spirv_definition.h",
|
||||
"$spirv_tools_dir/source/spirv_endian.cpp",
|
||||
"$spirv_tools_dir/source/spirv_endian.h",
|
||||
"$spirv_tools_dir/source/spirv_target_env.cpp",
|
||||
"$spirv_tools_dir/source/spirv_target_env.h",
|
||||
"$spirv_tools_dir/source/spirv_validator_options.cpp",
|
||||
"$spirv_tools_dir/source/spirv_validator_options.h",
|
||||
"$spirv_tools_dir/source/table.cpp",
|
||||
"$spirv_tools_dir/source/table.h",
|
||||
"$spirv_tools_dir/source/text.cpp",
|
||||
|
@ -494,8 +379,6 @@ static_library("spirv_tools") {
|
|||
"$spirv_tools_dir/source/util/hex_float.h",
|
||||
"$spirv_tools_dir/source/util/parse_number.cpp",
|
||||
"$spirv_tools_dir/source/util/parse_number.h",
|
||||
"$spirv_tools_dir/source/util/string_utils.cpp",
|
||||
"$spirv_tools_dir/source/util/string_utils.h",
|
||||
"$spirv_tools_dir/source/val/basic_block.cpp",
|
||||
"$spirv_tools_dir/source/val/construct.cpp",
|
||||
"$spirv_tools_dir/source/val/function.cpp",
|
||||
|
@ -503,26 +386,13 @@ static_library("spirv_tools") {
|
|||
"$spirv_tools_dir/source/val/validation_state.cpp",
|
||||
"$spirv_tools_dir/source/validate.cpp",
|
||||
"$spirv_tools_dir/source/validate.h",
|
||||
"$spirv_tools_dir/source/validate_arithmetics.cpp",
|
||||
"$spirv_tools_dir/source/validate_bitwise.cpp",
|
||||
"$spirv_tools_dir/source/validate_capability.cpp",
|
||||
"$spirv_tools_dir/source/validate_cfg.cpp",
|
||||
"$spirv_tools_dir/source/validate_conversion.cpp",
|
||||
"$spirv_tools_dir/source/validate_datarules.cpp",
|
||||
"$spirv_tools_dir/source/validate_decorations.cpp",
|
||||
"$spirv_tools_dir/source/validate_derivatives.cpp",
|
||||
"$spirv_tools_dir/source/validate_id.cpp",
|
||||
"$spirv_tools_dir/source/validate_image.cpp",
|
||||
"$spirv_tools_dir/source/validate_instruction.cpp",
|
||||
"$spirv_tools_dir/source/validate_layout.cpp",
|
||||
"$spirv_tools_dir/source/validate_logicals.cpp",
|
||||
"$spirv_tools_dir/source/validate_type_unique.cpp",
|
||||
]
|
||||
public_configs = [ ":spirv_tools_config" ]
|
||||
|
||||
foreach(target_name, spvtools_vendor_tables) {
|
||||
deps += [ ":$target_name" ]
|
||||
}
|
||||
}
|
||||
|
||||
# glslang
|
||||
|
@ -618,7 +488,9 @@ static_library("glslang") {
|
|||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpAtom.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpContext.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpContext.h",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpMemory.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpScanner.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpSymbols.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpTokens.cpp",
|
||||
"$glslang_dir/glslang/MachineIndependent/preprocessor/PpTokens.h",
|
||||
"$glslang_dir/glslang/MachineIndependent/propagateNoContraction.cpp",
|
||||
|
@ -627,6 +499,21 @@ static_library("glslang") {
|
|||
"$glslang_dir/glslang/MachineIndependent/reflection.h",
|
||||
"$glslang_dir/glslang/OSDependent/osinclude.h",
|
||||
"$glslang_dir/glslang/Public/ShaderLang.h",
|
||||
"$glslang_dir/hlsl/hlslAttributes.cpp",
|
||||
"$glslang_dir/hlsl/hlslAttributes.h",
|
||||
"$glslang_dir/hlsl/hlslGrammar.cpp",
|
||||
"$glslang_dir/hlsl/hlslGrammar.h",
|
||||
"$glslang_dir/hlsl/hlslOpMap.cpp",
|
||||
"$glslang_dir/hlsl/hlslOpMap.h",
|
||||
"$glslang_dir/hlsl/hlslParseHelper.cpp",
|
||||
"$glslang_dir/hlsl/hlslParseHelper.h",
|
||||
"$glslang_dir/hlsl/hlslParseables.cpp",
|
||||
"$glslang_dir/hlsl/hlslParseables.h",
|
||||
"$glslang_dir/hlsl/hlslScanContext.cpp",
|
||||
"$glslang_dir/hlsl/hlslScanContext.h",
|
||||
"$glslang_dir/hlsl/hlslTokenStream.cpp",
|
||||
"$glslang_dir/hlsl/hlslTokenStream.h",
|
||||
"$glslang_dir/hlsl/hlslTokens.h",
|
||||
]
|
||||
public_configs = [ ":glslang_config" ]
|
||||
configs += [ ":glslang_internal_config" ]
|
||||
|
@ -674,8 +561,6 @@ source_set("vulkan_layer_table") {
|
|||
}
|
||||
|
||||
core_validation_sources = [
|
||||
# This file is manually included in the layer
|
||||
# "$vulkan_gen_dir/vk_safe_struct.cpp",
|
||||
"$vulkan_gen_dir/vk_safe_struct.h",
|
||||
"$vulkan_layers_dir/layers/buffer_validation.cpp",
|
||||
"$vulkan_layers_dir/layers/buffer_validation.h",
|
||||
|
@ -683,30 +568,24 @@ core_validation_sources = [
|
|||
"$vulkan_layers_dir/layers/core_validation.h",
|
||||
"$vulkan_layers_dir/layers/descriptor_sets.cpp",
|
||||
"$vulkan_layers_dir/layers/descriptor_sets.h",
|
||||
"$vulkan_layers_dir/layers/shader_validation.cpp",
|
||||
"$vulkan_layers_dir/layers/shader_validation.h",
|
||||
"$vulkan_layers_dir/layers/xxhash.c",
|
||||
"$vulkan_layers_dir/layers/xxhash.h",
|
||||
]
|
||||
|
||||
object_tracker_sources = [
|
||||
"$vulkan_gen_dir/object_tracker.cpp",
|
||||
"$vulkan_layers_dir/layers/object_tracker.cpp",
|
||||
"$vulkan_layers_dir/layers/object_tracker.h",
|
||||
"$vulkan_layers_dir/layers/object_tracker_utils.cpp",
|
||||
]
|
||||
|
||||
parameter_validation_sources = [
|
||||
"$vulkan_gen_dir/parameter_validation.cpp",
|
||||
"$vulkan_layers_dir/layers/parameter_validation.h",
|
||||
"$vulkan_layers_dir/layers/parameter_validation_utils.cpp",
|
||||
"$vulkan_gen_dir/parameter_validation.h",
|
||||
"$vulkan_layers_dir/layers/parameter_validation.cpp",
|
||||
]
|
||||
swapchain_sources = [
|
||||
"$vulkan_layers_dir/layers/swapchain.cpp",
|
||||
"$vulkan_layers_dir/layers/swapchain.h",
|
||||
]
|
||||
|
||||
threading_sources = [
|
||||
"$vulkan_gen_dir/thread_check.h",
|
||||
"$vulkan_layers_dir/layers/threading.cpp",
|
||||
"$vulkan_layers_dir/layers/threading.h",
|
||||
]
|
||||
|
||||
unique_objects_sources = [
|
||||
"$vulkan_gen_dir/unique_objects_wrappers.h",
|
||||
|
||||
|
@ -726,12 +605,17 @@ layers = [
|
|||
[
|
||||
"object_tracker",
|
||||
object_tracker_sources,
|
||||
":vulkan_gen_object_tracker_cpp",
|
||||
"",
|
||||
],
|
||||
[
|
||||
"parameter_validation",
|
||||
parameter_validation_sources,
|
||||
":vulkan_gen_parameter_validation",
|
||||
":vulkan_gen_parameter_validation_helper",
|
||||
],
|
||||
[
|
||||
"swapchain",
|
||||
swapchain_sources,
|
||||
"",
|
||||
],
|
||||
[
|
||||
"threading",
|
||||
|
@ -749,6 +633,7 @@ vulkan_gen_json_files_outputs = [
|
|||
"$root_out_dir/$data_dir/VkLayer_core_validation.json",
|
||||
"$root_out_dir/$data_dir/VkLayer_object_tracker.json",
|
||||
"$root_out_dir/$data_dir/VkLayer_parameter_validation.json",
|
||||
"$root_out_dir/$data_dir/VkLayer_swapchain.json",
|
||||
"$root_out_dir/$data_dir/VkLayer_threading.json",
|
||||
"$root_out_dir/$data_dir/VkLayer_unique_objects.json",
|
||||
]
|
||||
|
@ -760,6 +645,7 @@ action("vulkan_gen_json_files") {
|
|||
"$vulkan_layers_dir/layers/windows/VkLayer_core_validation.json",
|
||||
"$vulkan_layers_dir/layers/windows/VkLayer_object_tracker.json",
|
||||
"$vulkan_layers_dir/layers/windows/VkLayer_parameter_validation.json",
|
||||
"$vulkan_layers_dir/layers/windows/VkLayer_swapchain.json",
|
||||
"$vulkan_layers_dir/layers/windows/VkLayer_threading.json",
|
||||
"$vulkan_layers_dir/layers/windows/VkLayer_unique_objects.json",
|
||||
]
|
||||
|
@ -770,6 +656,7 @@ action("vulkan_gen_json_files") {
|
|||
"$vulkan_layers_dir/layers/linux/VkLayer_core_validation.json",
|
||||
"$vulkan_layers_dir/layers/linux/VkLayer_object_tracker.json",
|
||||
"$vulkan_layers_dir/layers/linux/VkLayer_parameter_validation.json",
|
||||
"$vulkan_layers_dir/layers/linux/VkLayer_swapchain.json",
|
||||
"$vulkan_layers_dir/layers/linux/VkLayer_threading.json",
|
||||
"$vulkan_layers_dir/layers/linux/VkLayer_unique_objects.json",
|
||||
]
|
||||
|
@ -784,8 +671,6 @@ action("vulkan_gen_json_files") {
|
|||
|
||||
source_set("vulkan_layer_utils") {
|
||||
sources = [
|
||||
"$vulkan_layers_dir/layers/vk_format_utils.cpp",
|
||||
"$vulkan_layers_dir/layers/vk_format_utils.h",
|
||||
"$vulkan_layers_dir/layers/vk_layer_config.cpp",
|
||||
"$vulkan_layers_dir/layers/vk_layer_config.h",
|
||||
"$vulkan_layers_dir/layers/vk_layer_extension_utils.cpp",
|
||||
|
@ -815,38 +700,6 @@ source_set("vulkan_core_validation_glslang") {
|
|||
public_configs = [ ":vulkan_core_validation_config" ]
|
||||
}
|
||||
|
||||
config("vulkan_parameter_validation_config") {
|
||||
if (is_clang) {
|
||||
cflags_cc = [ "-Wno-unused-const-variable" ]
|
||||
}
|
||||
}
|
||||
|
||||
# This special action is needed to remove the generated param header.
|
||||
# Otherwise the param gen cpp file will pick up the old file and the
|
||||
# build will fail. It's a bit unfortunate but necessary.
|
||||
action("vulkan_clean_parameter_gen_header") {
|
||||
script = "$angle_root/scripts/remove_file_if_exists.py"
|
||||
inputs = parameter_validation_sources
|
||||
deps = [
|
||||
":vulkan_gen_parameter_validation_cpp",
|
||||
]
|
||||
outputs = [
|
||||
"$vulkan_gen_dir/parameter_validation_h_is_removed",
|
||||
]
|
||||
args = [
|
||||
"$raw_vulkan_gen_dir/parameter_validation.h",
|
||||
"$raw_vulkan_gen_dir/parameter_validation_h_is_removed",
|
||||
]
|
||||
}
|
||||
|
||||
source_set("vulkan_gen_parameter_validation") {
|
||||
deps = [
|
||||
":vulkan_clean_parameter_gen_header",
|
||||
":vulkan_gen_parameter_validation_cpp",
|
||||
]
|
||||
public_configs = [ ":vulkan_parameter_validation_config" ]
|
||||
}
|
||||
|
||||
foreach(layer_info, layers) {
|
||||
name = layer_info[0]
|
||||
shared_library("VkLayer_$name") {
|
||||
|
|
Загрузка…
Ссылка в новой задаче