From 2cc0b14d1f67990e575d94a1b196e15aee722b3f Mon Sep 17 00:00:00 2001 From: Austin Seipp Date: Sun, 6 Aug 2023 17:50:00 -0500 Subject: [PATCH] proc-macros: add BUILD files Signed-off-by: Austin Seipp --- BUILD | 1 + lib/proc-macros/BUILD | 22 ++++++++++++++++++++++ lib/proc-macros/Cargo.toml | 3 +++ 3 files changed, 26 insertions(+) create mode 100644 lib/proc-macros/BUILD diff --git a/BUILD b/BUILD index abe51bdc79..a256decc88 100644 --- a/BUILD +++ b/BUILD @@ -4,5 +4,6 @@ for (name, actual) in [ # (top-level name, fully-qualified target name) ("gen-protos", "//lib/gen-protos:gen-protos"), + ("proc-macros", "//lib/proc-macros:proc-macros"), ] ] diff --git a/lib/proc-macros/BUILD b/lib/proc-macros/BUILD new file mode 100644 index 0000000000..5b7d9d3d62 --- /dev/null +++ b/lib/proc-macros/BUILD @@ -0,0 +1,22 @@ + +load("//buck/shims/jj.bzl", "jj") + +alias( + # NOTE: default target for this package + name = 'proc-macros', + actual = ':jj-lib-proc-macros', +) + +jj.rust_library( + name = 'jj-lib-proc-macros', + srcs = glob(["src/**/*.rs"]), + proc_macro = True, + deps = [ + # CARGO-SYNC-START: dependencies + 'third-party//rust:proc-macro2', + 'third-party//rust:quote', + 'third-party//rust:syn', + # CARGO-SYNC-END + ], + visibility = ['PUBLIC'], # XXX FIXME (aseipp): why is this needed? +) diff --git a/lib/proc-macros/Cargo.toml b/lib/proc-macros/Cargo.toml index e26bfa26ba..a1d21be46b 100644 --- a/lib/proc-macros/Cargo.toml +++ b/lib/proc-macros/Cargo.toml @@ -13,6 +13,9 @@ readme = { workspace = true } include = ["/LICENSE", "/src/"] +[lints] +workspace = true + [lib] proc-macro = true