aboutsummaryrefslogtreecommitdiff
path: root/third-party/BUILD
diff options
context:
space:
mode:
Diffstat (limited to 'third-party/BUILD')
-rw-r--r--third-party/BUILD42
1 files changed, 33 insertions, 9 deletions
diff --git a/third-party/BUILD b/third-party/BUILD
index 57c584a7..1760b707 100644
--- a/third-party/BUILD
+++ b/third-party/BUILD
@@ -1,12 +1,13 @@
load(
- "//tools/bazel:rust.bzl",
+ "//tools/bazel:third_party.bzl",
+ cargo_build_script = "third_party_cargo_build_script",
glob = "third_party_glob",
rust_library = "third_party_rust_library",
)
rust_library(
name = "bitflags",
- srcs = glob(["vendor/bitflags-1.2.1/src/**"]),
+ srcs = glob(["vendor/bitflags-1.3.2/src/**"]),
)
rust_library(
@@ -50,13 +51,21 @@ rust_library(
"proc-macro",
"span-locations",
],
- rustc_flags = [
- "--cfg=span_locations",
- "--cfg=use_proc_macro",
- "--cfg=wrap_proc_macro",
- ],
visibility = ["//visibility:public"],
- deps = [":unicode-xid"],
+ deps = [
+ ":proc-macro2@build",
+ ":unicode-xid",
+ ],
+)
+
+cargo_build_script(
+ name = "proc-macro2@build",
+ srcs = ["vendor/proc-macro2-1.0.28/build.rs"],
+ crate_features = [
+ "proc-macro",
+ "span-locations",
+ ],
+ crate_name = "build",
)
rust_library(
@@ -76,7 +85,7 @@ rust_library(
rust_library(
name = "syn",
- srcs = glob(["vendor/syn-1.0.74/src/**"]),
+ srcs = glob(["vendor/syn-1.0.75/src/**"]),
crate_features = [
"clone-impls",
"derive",
@@ -89,10 +98,25 @@ rust_library(
deps = [
":proc-macro2",
":quote",
+ ":syn@build",
":unicode-xid",
],
)
+cargo_build_script(
+ name = "syn@build",
+ srcs = ["vendor/syn-1.0.75/build.rs"],
+ crate_features = [
+ "clone-impls",
+ "derive",
+ "full",
+ "parsing",
+ "printing",
+ "proc-macro",
+ ],
+ crate_name = "build",
+)
+
rust_library(
name = "termcolor",
srcs = glob(["vendor/termcolor-1.1.2/src/**"]),