(bazel) Set @platforms//os:emscripten for platform_wasm (#1363)
* (bazel) Set @platforms//os:emscripten for platform_wasm * (bazel) Set @platforms//os:emscripten for platform_wasm * (bazel) Set @platforms//os:emscripten for platform_wasm
This commit is contained in:
@@ -82,6 +82,7 @@ platform(
|
||||
name = "platform_wasm",
|
||||
constraint_values = [
|
||||
"@platforms//cpu:wasm32",
|
||||
"@platforms//os:emscripten",
|
||||
],
|
||||
)
|
||||
|
||||
|
||||
1
bazel/MODULE.bazel
Normal file
1
bazel/MODULE.bazel
Normal file
@@ -0,0 +1 @@
|
||||
bazel_dep(name = "platforms", version = "0.0.9")
|
||||
@@ -26,6 +26,11 @@ The SHA1 hash in the above `strip_prefix` and `url` parameters correspond to the
|
||||
newer versions, you'll need to update those. To make use of older versions, change the
|
||||
parameter of `emsdk_emscripten_deps()`. Supported versions are listed in `revisions.bzl`
|
||||
|
||||
Bazel 7+ additionally requires `platforms` dependencies in the `MODULE.bazel` file.
|
||||
```starlark
|
||||
bazel_dep(name = "platforms", version = "0.0.9")
|
||||
```
|
||||
|
||||
|
||||
## Building
|
||||
|
||||
|
||||
@@ -2,6 +2,15 @@ load("@bazel_tools//tools/build_defs/repo:http.bzl", "http_archive")
|
||||
load("@bazel_tools//tools/build_defs/repo:utils.bzl", "maybe")
|
||||
|
||||
def deps():
|
||||
maybe(
|
||||
http_archive,
|
||||
name = "platforms",
|
||||
urls = [
|
||||
"https://mirror.bazel.build/github.com/bazelbuild/platforms/releases/download/0.0.9/platforms-0.0.9.tar.gz",
|
||||
"https://github.com/bazelbuild/platforms/releases/download/0.0.9/platforms-0.0.9.tar.gz",
|
||||
],
|
||||
sha256 = "5eda539c841265031c2f82d8ae7a3a6490bd62176e0c038fc469eabf91f6149b",
|
||||
)
|
||||
maybe(
|
||||
http_archive,
|
||||
name = "bazel_skylib",
|
||||
|
||||
1
bazel/test_external/MODULE.bazel
Normal file
1
bazel/test_external/MODULE.bazel
Normal file
@@ -0,0 +1 @@
|
||||
bazel_dep(name = "platforms", version = "0.0.9")
|
||||
Reference in New Issue
Block a user