aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYecheng Zhao <zyecheng@google.com>2023-10-09 01:36:53 +0000
committerYecheng Zhao <zyecheng@google.com>2023-10-09 18:32:19 +0000
commit360d11b97f31518640ef212ba9b21f14b6b77668 (patch)
tree9bf6f34e621b2040d7d567b69c01358eb314ef9e
parentf11a2c385707f6c9e59d59b32b15783b2d300636 (diff)
downloadbyteorder-360d11b97f31518640ef212ba9b21f14b6b77668.tar.gz
Add BUILD file for kleaf bazel build
Test: touch external/rust/crates/byteorder/WORKSPACE && \ b build @byteorder \ --override_repository=byteorder=external/rust/crates/byteorder/ Change-Id: I717ce1f0510e7c14584c3d86928ede47809d158b
-rw-r--r--BUILD37
1 files changed, 37 insertions, 0 deletions
diff --git a/BUILD b/BUILD
new file mode 100644
index 0000000..8340446
--- /dev/null
+++ b/BUILD
@@ -0,0 +1,37 @@
+load("@rules_license//rules:license.bzl", "license")
+load("@rules_license//rules:license_kind.bzl", "license_kind")
+load("@rules_rust//rust:defs.bzl", "rust_library")
+
+package(
+ default_applicable_licenses = [":license"],
+ default_visibility = ["//visibility:public"],
+)
+
+license(
+ name = "license",
+ license_kinds = [
+ ":SPDX-license-identifier-Apache-2.0",
+ ":SPDX-license-identifier-MIT",
+ ],
+ license_text = "LICENSE-APACHE",
+ visibility = [":__subpackages__"],
+)
+
+license_kind(
+ name = "SPDX-license-identifier-Apache-2.0",
+ conditions = ["notice"],
+ url = "https://spdx.org/licenses/Apache-2.0.html",
+)
+
+license_kind(
+ name = "SPDX-license-identifier-MIT",
+ conditions = ["notice"],
+ url = "",
+)
+
+rust_library(
+ name = "byteorder",
+ srcs = glob(["**/*.rs"]),
+ edition = "2021",
+ visibility = ["//visibility:public"],
+)