Runfiles for `rust_wasm_bindgen` targets
维护者通常 3 天内回复
还没有人认领这个 Issue。
评估
- 难度
- 4/5
- 预计耗时
- 3-5 天
- 新手友好度
- 48/100
- Issue 类型
- 功能
- 描述清晰度
- 基本清楚
- 活跃度
- 冷清
- 技术栈
- rust, wasm
- 领域
- build-system, tooling
调研方向
从 rust_wasm_bindgen 规则及其 wasm_file 目标开始,使用提供的 tar 示例来了解预期的构件布局。调查底层 rust_binary 的 runfiles 是如何生成的,以及生成的应用是如何打包的。当示例可以在 tar 中包含 app.runfiles/,而不需要含义不明确的可执行入口点时,即视为完成。
由索引模型根据 Issue 内容生成。
描述
Currently, rust_wasm_bindgen doesn't include runfiles of the underlying wasm_file target which in some cases is a rust_binary that uses the runfiles API as the common way to look up data files at runtime. For example:
load("@tar.bzl", "tar")
load("@rules_rust_wasm_bindgen//:defs.bzl", "rust_wasm_bindgen")
rust_wasm_bindgen(
name = "app",
target = "web",
wasm_file = "//:app",
)
tar(
name = "archive",
srcs = [
"index.html",
":app",
],
include_runfiles = True,
)
Currently app is only the generated web files from wasm-bindgen and the .wasm file itself but there is no runfiles tree rendered next to it. I believe this is because rust_wasm_bindgen is not executable and therefore no runfiles tree is created. It would be easy to convert this to an executable but it's unclear what the "entrypoint" would be or if this makes sense semantically as the wasm file nor any of the javascript is directly executable. It would be nice though to have a way to author something like the example and have app.runfiles/ in the tar.
- 主要语言
- Starlark
- 星标
- 857
- 派生
- 701
- 平均合并
- 4 天 7 小时
- 30 天内合并 PR
- 46
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 没有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
bazelbuild/rules_rust 的其他 Issue
-
`rust_test(crate = ...)` does not stage the crate's transitive dynamic libraries into runfiles可能已有人在做 @Wito-1 于 66 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 88/100
bazelbuild/rules_rust#4309 ·
维护者通常 3 天内回复
-
Windows (no-symlink path): drain_runfiles_dir_windows deletes retained runfiles — inverted filename_suffixes_to_retain condition可能已有人在做 @Mattbusel 于 17 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
bazelbuild/rules_rust#4266 ·
维护者通常 3 天内回复
-
rust.toolchain(strip_level = ...) is silently ignored可能已有人在做 @Mattbusel 于 17 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
bazelbuild/rules_rust#4223 ·
维护者通常 3 天内回复
-
难度 1/5 1-3 小时 新手友好度 90/100
bazelbuild/rules_rust#4152 · 1 个 reaction ·
维护者通常 3 天内回复
-
awaiting-response
难度 2/5 1-3 小时 新手友好度 76/100
bazelbuild/rules_rust#3599 · 1 条评论 ·
维护者通常 3 天内回复
查看 bazelbuild/rules_rust 的全部 Issue
相似的 Issue
-
难度 2/5 1-3 小时 新手友好度 65/100
bazelbuild/apple_support#707 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 92/100
-
out-of-date
难度 2/5 1-3 小时 新手友好度 68/100
CachyOS/CachyOS-PKGBUILDS#2232 ·
维护者通常 1 天内回复
-
blast/large refactor risk/low spend-dem
难度 2/5 1-3 小时 新手友好度 68/100
chriskelly/MusicWall#87 · 2 条评论 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
neilotoole/sq#1503 ·
维护者通常 1 天内回复