add patch to wasmer

This commit is contained in:
auronandace 2026-07-01 20:22:59 +01:00
parent f9e7cff363
commit 51effa7ec4
2 changed files with 26 additions and 2 deletions

View File

@ -1,8 +1,21 @@
# TODO region crate error (https://gitlab.redox-os.org/redox-os/redox/-/work_items/1837)
# TODO remove region crate patch when ready (https://gitlab.redox-os.org/redox-os/redox/-/work_items/1837)
# TODO add redox support to termios-rs
[source]
git = "https://github.com/wasmerio/wasmer"
patches = [
"redox.patch"
]
shallow_clone = true
[build]
template = "custom"
script = """
cookbook_cargo_packages wasmer-cli
package=wasmer-cli
"${COOKBOOK_CARGO}" build \
--manifest-path "${COOKBOOK_SOURCE}/Cargo.toml" \
--package "${package}" \
--release
mkdir -pv "${COOKBOOK_STAGE}/usr/bin"
cp -v \
"target/${TARGET}/release/${package}" \
"${COOKBOOK_STAGE}/usr/bin/${package}"
"""

View File

@ -0,0 +1,11 @@
diff --git a/Cargo.toml b/Cargo.toml
index 1366f717291..1b8e2f1a480 100644
--- a/Cargo.toml
+++ b/Cargo.toml
@@ -606,3 +606,6 @@ required-features = ["cranelift"]
name = "throw-exception"
path = "examples/throw_exception.rs"
required-features = ["llvm"]
+
+[patch.crates-io]
+region = { git = 'https://github.com/willnode/region-rs', branch = 'redox' }