fork/rules_rust

git clone https://git.julia.blue/fork/rules_rust

UebelAndreMoved rust extension rules into a separate `rules_rust_ext` workspace. (#3007)2bad96d9

cleanup
2.2 KiB114 linesraw
1# {version}
2
3Additional documentation can be found at: https://bazelbuild.github.io/rules_rust/#setup
4
5## Bzlmod
6
7```python
8bazel_dep(name = "rules_rust", version = "{version}")
9```
10
11## WORKSPACE
12
13```python
14load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
15http_archive(
16    name = "rules_rust",
17    integrity = "sha256-{sha256_base64}",
18    urls = ["https://github.com/bazelbuild/rules_rust/releases/download/{version}/rules_rust-{version}.tar.gz"],
19)
20```
21
22## Extensions
23
24### Bindgen
25
26<details>
27
28#### Bzlmod
29
30```python
31bazel_dep(name = "rules_rust_bindgen", version = "{version}")
32```
33
34#### WORKSPACE
35
36```python
37load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
38http_archive(
39    name = "rules_rust_bindgen",
40    integrity = "sha256-{ext_bindgen_sha256_base64}",
41    urls = ["https://github.com/bazelbuild/rules_rust/releases/download/{version}/rules_rust_bindgen-{version}.tar.gz"],
42)
43```
44
45</details>
46
47### Prost
48
49<details>
50
51#### Bzlmod
52
53```python
54bazel_dep(name = "rules_rust_prost", version = "{version}")
55```
56
57#### WORKSPACE
58
59```python
60load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
61http_archive(
62    name = "rules_rust_prost",
63    integrity = "sha256-{ext_prost_sha256_base64}",
64    urls = ["https://github.com/bazelbuild/rules_rust/releases/download/{version}/rules_rust_prost-{version}.tar.gz"],
65)
66```
67
68</details>
69
70### Protobuf
71
72<details>
73
74#### Bzlmod
75
76```python
77bazel_dep(name = "rules_rust_protobuf", version = "{version}")
78```
79
80#### WORKSPACE
81
82```python
83load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
84http_archive(
85    name = "rules_rust_protobuf",
86    integrity = "sha256-{ext_protobuf_sha256_base64}",
87    urls = ["https://github.com/bazelbuild/rules_rust/releases/download/{version}/rules_rust_protobuf-{version}.tar.gz"],
88)
89```
90
91</details>
92
93### Wasm-Bindgen
94
95<details>
96
97#### Bzlmod
98
99```python
100bazel_dep(name = "rules_rust_wasm_bindgen", version = "{version}")
101```
102
103#### WORKSPACE
104
105```python
106load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
107http_archive(
108    name = "rules_rust",
109    integrity = "sha256-{ext_wasm_bindgen_sha256_base64}",
110    urls = ["https://github.com/bazelbuild/rules_rust/releases/download/{version}/rules_rust_wasm_bindgen-{version}.tar.gz"],
111)
112```
113
114</details>