| load("@bazel_skylib//:bzl_library.bzl", "bzl_library") |
| load("@bazel_skylib//rules:common_settings.bzl", "bool_flag", "string_flag") |
| load(":incompatible.bzl", "incompatible_flag") |
| |
| package(default_visibility = ["//visibility:public"]) |
| |
| incompatible_flag( |
| name = "incompatible_remove_transitive_libs_from_dep_info", |
| build_setting_default = True, |
| issue = "https://github.com/bazelbuild/rules_rust/issues/1051", |
| ) |
| |
| # A flag controlling whether to rename first-party crates such that their names |
| # encode the Bazel package and target name, instead of just the target name. |
| # |
| # First-party vs. third-party crates are identified using the value of |
| # //settings:third_party_dir. |
| bool_flag( |
| name = "rename_first_party_crates", |
| build_setting_default = False, |
| ) |
| |
| # A flag specifying the location of vendored third-party rust crates within this |
| # repository that must not be renamed when `rename_1p_crates` is enabled. |
| # |
| # Must be specified as a Bazel package, e.g. "//some/location/in/repo". |
| string_flag( |
| name = "third_party_dir", |
| build_setting_default = "//third_party/rust", |
| ) |
| |
| bzl_library( |
| name = "bzl_lib", |
| srcs = glob(["**/*.bzl"]), |
| ) |
| |
| alias( |
| name = "rules", |
| actual = ":bzl_lib", |
| deprecation = "Please use the `@rules_rust//settings:bzl_lib` target instead", |
| visibility = ["//rust:__subpackages__"], |
| ) |