# Copyright 2018 The Dawn Authors
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
#     http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

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

group("all") {
  testonly = true
  deps = [
    "src/dawn/fuzzers",
    "src/dawn/native:webgpu_dawn",
    "src/dawn/tests",
    "src/tint/api",
    "src/tint/fuzzers",
  ]
  if (tint_build_unittests) {
    deps += [ "src/tint/cmd/test" ]
  }
  if (dawn_standalone) {
    deps += [
      "src/dawn/samples",
      "src/tint/cmd/tint",
    ]
  }
}

# This target is built when no specific target is specified on the command line.
group("default") {
  testonly = true
  deps = [ ":all" ]
}
