Skip to content

Commit 10ac0f8

Browse files
committed
Review tweaks
* Update to use defs.bzl * Fix up some tests * Remove pseudo-attempt at bootstrapping
1 parent 09272cc commit 10ac0f8

File tree

10 files changed

+127
-98
lines changed

10 files changed

+127
-98
lines changed

cargo/crate_universe_resolver/src/templates/crate.BUILD.template

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
# buildifier: disable=load
22
load(
3-
"@rules_rust//rust:rust.bzl",
3+
"@rules_rust//rust:defs.bzl",
44
"rust_binary",
55
"rust_library",
6+
"rust_proc_macro",
67
"rust_test",
78
)
89

cargo/crate_universe_resolver/src/templates/partials/rust_library.template

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,12 @@ alias(
1111

1212
{% endif -%}
1313
# buildifier: leave-alone
14+
{%- if target.kind == "proc-macro" %}
15+
rust_proc_macro(
16+
{%- else %}
1417
rust_library(
18+
{%- endif %}
1519
name = "{{ target_name_sanitized }}",
16-
crate_type = "{{ target.kind }}",
1720
deps = [
1821
{%- if crate.build_script_target %}
1922
":{{ crate_name_sanitized }}_build_script",

0 commit comments

Comments
 (0)