| # Copyright 2017 The Fuchsia Authors. All rights reserved. |
| # Use of this source code is governed by a BSD-style license that can be |
| # found in the LICENSE file. |
| |
| import("//build/dart/toolchain.gni") |
| import("//build/python/python_binary.gni") |
| import("//build/toolchain/basic_toolchain.gni") |
| |
| group("dart_allowlist") { |
| # ________ _________ ________ ________ |
| # |\ ____\|\___ ___\\ __ \|\ __ \ |
| # \ \ \___|\|___ \ \_\ \ \|\ \ \ \|\ \ |
| # \ \_____ \ \ \ \ \ \ \\\ \ \ ____\ |
| # \|____|\ \ \ \ \ \ \ \\\ \ \ \___| |
| # ____\_\ \ \ \__\ \ \_______\ \__\ |
| # |\_________\ \|__| \|_______|\|__| |
| # \|_________| |
| # |
| # This allowlist is set up as part of RFC-0176: Disallow New Dart |
| # programs in the Fuchsia Source Tree. |
| # https://fuchsia.dev/fuchsia-src/contribute/governance/rfcs/0176_disallow_new_dart_programs |
| # |
| # This contains the full list of dart_libraries in the build. |
| # If you add a new dart program, you must add it to this list. |
| # |
| # To add targets to this allowlist, please send a change to one of the OWNERS |
| # of this file. |
| # |
| # We will ignore variance in targets added/deleted from //third_part/dart-pkg and //src/tests/end_to_end/perf. |
| visibility = [] |
| |
| # Remaining host tools which still use Dart. |
| visibility += [ |
| "//scripts/fxtest:*", |
| "//scripts/fxutils:*", |
| "//scripts/status:*", |
| ] |
| |
| # SL4F dart client library and tests which use it. |
| visibility += [ |
| "//sdk/testing/gcloud_lib:gcloud_lib", |
| "//sdk/testing/sl4f/client:*", |
| "//src/tests/end_to_end/package_manager:*", |
| "//src/tests/end_to_end/package_manager/util/net:*", |
| "//src/tests/end_to_end/package_manager/util/pkg:*", |
| "//src/tests/end_to_end/package_manager/util/pm:*", |
| "//src/tests/end_to_end/perf:*", |
| "//src/tests/end_to_end/sl4f:*", |
| "//src/tests/end_to_end/time_sync:*", |
| ] |
| |
| # Third_party dart programs/libraries must continue to be built as dart libraries. |
| visibility += [ "//third_party/dart-pkg/pub/*" ] |
| |
| # Catch-all for //vendor repos. |
| visibility += [ "//vendor/*" ] |
| } |
| |
| python_binary("gen_dart_package_config") { |
| main_source = "gen_dart_package_config.py" |
| deps = [ "//third_party/pyyaml:yaml" ] |
| } |
| |
| python_binary("gen_meta_file") { |
| main_source = "sdk/gen_meta_file.py" |
| deps = [ "//third_party/pyyaml:yaml" ] |
| } |
| |
| # A toolchain dedicated to processing and analyzing Dart packages. |
| # The only targets in this toolchain are action() targets, so it |
| # has no real tools. But every toolchain needs stamp and copy. |
| basic_toolchain("dartlang") { |
| expected_label = dart_toolchain |
| } |