# Copyright 2023 The Dawn & Tint Authors
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# 1. Redistributions of source code must retain the above copyright notice, this
#    list of conditions and the following disclaimer.
#
# 2. Redistributions in binary form must reproduce the above copyright notice,
#    this list of conditions and the following disclaimer in the documentation
#    and/or other materials provided with the distribution.
#
# 3. Neither the name of the copyright holder nor the names of its
#    contributors may be used to endorse or promote products derived from
#    this software without specific prior written permission.
#
# THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
# AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
# DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
# SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
# CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
# OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

################################################################################
# File generated by 'tools/src/cmd/gen' using the template:
#   tools/src/cmd/gen/build/BUILD.gn.tmpl
#
# To regenerate run: './tools/run gen'
#
#                       Do not modify this file directly
################################################################################

import("../../../../../scripts/dawn_overrides_with_defaults.gni")
import("../../../../../scripts/tint_overrides_with_defaults.gni")

import("${tint_src_dir}/tint.gni")

if (tint_build_unittests || tint_build_benchmarks) {
  import("//testing/test.gni")
}

libtint_source_set("resolver") {
  sources = [
    "dependency_graph.cc",
    "dependency_graph.h",
    "incomplete_type.cc",
    "incomplete_type.h",
    "resolve.cc",
    "resolve.h",
    "resolver.cc",
    "resolver.h",
    "sem_helper.cc",
    "sem_helper.h",
    "uniformity.cc",
    "uniformity.h",
    "unresolved_identifier.cc",
    "unresolved_identifier.h",
    "validator.cc",
    "validator.h",
  ]
  deps = [
    "${dawn_root}/src/utils:utils",
    "${tint_src_dir}/api/common",
    "${tint_src_dir}/lang/core",
    "${tint_src_dir}/lang/core/constant",
    "${tint_src_dir}/lang/core/intrinsic",
    "${tint_src_dir}/lang/core/type",
    "${tint_src_dir}/lang/wgsl",
    "${tint_src_dir}/lang/wgsl/ast",
    "${tint_src_dir}/lang/wgsl/common",
    "${tint_src_dir}/lang/wgsl/features",
    "${tint_src_dir}/lang/wgsl/intrinsic",
    "${tint_src_dir}/lang/wgsl/program",
    "${tint_src_dir}/lang/wgsl/sem",
    "${tint_src_dir}/utils/constants",
    "${tint_src_dir}/utils/containers",
    "${tint_src_dir}/utils/diagnostic",
    "${tint_src_dir}/utils/ice",
    "${tint_src_dir}/utils/id",
    "${tint_src_dir}/utils/macros",
    "${tint_src_dir}/utils/math",
    "${tint_src_dir}/utils/memory",
    "${tint_src_dir}/utils/reflection",
    "${tint_src_dir}/utils/result",
    "${tint_src_dir}/utils/rtti",
    "${tint_src_dir}/utils/symbol",
    "${tint_src_dir}/utils/text",
    "${tint_src_dir}/utils/traits",
  ]
}
if (tint_build_unittests) {
  tint_unittests_source_set("unittests") {
    sources = [
      "address_space_layout_validation_test.cc",
      "address_space_validation_test.cc",
      "alias_analysis_test.cc",
      "array_accessor_test.cc",
      "assignment_validation_test.cc",
      "atomics_test.cc",
      "atomics_validation_test.cc",
      "attribute_validation_test.cc",
      "bitcast_validation_test.cc",
      "builtin_enum_test.cc",
      "builtin_structs_test.cc",
      "builtin_test.cc",
      "builtin_validation_test.cc",
      "builtins_validation_test.cc",
      "call_test.cc",
      "call_validation_test.cc",
      "clip_distances_extension_test.cc",
      "compound_assignment_validation_test.cc",
      "compound_statement_test.cc",
      "const_assert_test.cc",
      "control_block_validation_test.cc",
      "dependency_graph_test.cc",
      "diagnostic_control_test.cc",
      "dual_source_blending_extension_test.cc",
      "entry_point_validation_test.cc",
      "evaluation_stage_test.cc",
      "expression_kind_test.cc",
      "f16_extension_test.cc",
      "framebuffer_fetch_extension_test.cc",
      "function_validation_test.cc",
      "graphite_extension_test.cc",
      "host_shareable_validation_test.cc",
      "increment_decrement_validation_test.cc",
      "inferred_type_test.cc",
      "input_attachments_extension_test.cc",
      "is_host_shareable_test.cc",
      "is_storeable_test.cc",
      "language_features_test.cc",
      "load_test.cc",
      "materialize_test.cc",
      "override_test.cc",
      "pixel_local_extension_test.cc",
      "ptr_ref_test.cc",
      "ptr_ref_validation_test.cc",
      "resolver_behavior_test.cc",
      "resolver_helper_test.cc",
      "resolver_helper_test.h",
      "resolver_test.cc",
      "root_identifier_test.cc",
      "side_effects_test.cc",
      "struct_address_space_use_test.cc",
      "struct_layout_test.cc",
      "struct_pipeline_stage_use_test.cc",
      "subgroups_extension_test.cc",
      "type_validation_test.cc",
      "unresolved_identifier_test.cc",
      "validation_test.cc",
      "validator_is_storeable_test.cc",
      "value_constructor_validation_test.cc",
      "variable_test.cc",
      "variable_validation_test.cc",
    ]
    deps = [
      "${dawn_root}/src/utils:utils",
      "${tint_src_dir}:gmock_and_gtest",
      "${tint_src_dir}/api/common",
      "${tint_src_dir}/lang/core",
      "${tint_src_dir}/lang/core/constant",
      "${tint_src_dir}/lang/core/intrinsic",
      "${tint_src_dir}/lang/core/ir",
      "${tint_src_dir}/lang/core/type",
      "${tint_src_dir}/lang/core/type:unittests",
      "${tint_src_dir}/lang/wgsl",
      "${tint_src_dir}/lang/wgsl/ast",
      "${tint_src_dir}/lang/wgsl/ast:unittests",
      "${tint_src_dir}/lang/wgsl/common",
      "${tint_src_dir}/lang/wgsl/features",
      "${tint_src_dir}/lang/wgsl/intrinsic",
      "${tint_src_dir}/lang/wgsl/program",
      "${tint_src_dir}/lang/wgsl/resolver",
      "${tint_src_dir}/lang/wgsl/sem",
      "${tint_src_dir}/lang/wgsl/sem:unittests",
      "${tint_src_dir}/utils/containers",
      "${tint_src_dir}/utils/diagnostic",
      "${tint_src_dir}/utils/ice",
      "${tint_src_dir}/utils/id",
      "${tint_src_dir}/utils/macros",
      "${tint_src_dir}/utils/math",
      "${tint_src_dir}/utils/memory",
      "${tint_src_dir}/utils/reflection",
      "${tint_src_dir}/utils/result",
      "${tint_src_dir}/utils/rtti",
      "${tint_src_dir}/utils/symbol",
      "${tint_src_dir}/utils/text",
      "${tint_src_dir}/utils/traits",
    ]

    if (tint_build_wgsl_reader) {
      sources += [ "uniformity_test.cc" ]
      deps += [ "${tint_src_dir}/lang/wgsl/reader" ]
    }
  }
}
