void-packages/srcpkgs/wasmtime/template

50 lines
1.9 KiB
Bash

# Template file for 'wasmtime'
pkgname=wasmtime
version=0.25.0
revision=1
create_wrksrc=yes
archs="x86_64* i686* aarch64*"
build_style=cargo
short_desc="Standalone JIT-style runtime for WebAssembly, using Cranelift"
maintainer="Isaac Freund <ifreund@ifreund.xyz>"
license="Apache-2.0"
homepage="https://github.com/bytecodealliance/wasmtime"
_spec_testsuite_commit=9994915e0cca8b42a16c577e4c85491822367dde
_wasm_c_api_commit=c9d31284651b975f05ac27cee0bab1377560b87e
_WASI_commit=ef8c1a53feb2dfb763d4ea5c7d9e0a0126b45579
_wasi_crypto_commit=1f3078088bd0de36a0bc96859a1724e7d338a832
distfiles="${homepage}/archive/v${version}.tar.gz
https://github.com/WebAssembly/testsuite/archive/${_spec_testsuite_commit}.tar.gz
https://github.com/WebAssembly/wasm-c-api/archive/${_wasm_c_api_commit}.tar.gz
https://github.com/WebAssembly/WASI/archive/${_WASI_commit}.tar.gz
https://github.com/WebAssembly/wasi-crypto/archive/${_wasi_crypto_commit}.tar.gz"
checksum="219b79db4084a0f9d720d430d625a676d68dd0228b11cab46fd6c2a649f77034
baf8a7f68ddd21fb7ad255acc765391c972c12f3857af8e9a979342b160e6a5a
c774044f51431429e878bd1b9e2a4e38932f861f9211df72f75e9427eb6b8d32
1527f437df282a98b1c708ba7848835a0bbc252d78ae8f9f90b384ce20462e7a
a5f791d6c5a025869b4d9512a9f98e6befacf3124135e492182df57297fb227a"
case ${XBPS_TARGET_MACHINE} in
aarch64-musl)
broken="https://github.com/bytecodealliance/wasmtime/issues/2133";;
esac
# skip, as they require the wasm32-wasi rust target
do_check() {
:
}
post_extract() {
mv wasmtime-${version}/* .
# move submodules to the proper location
rmdir tests/spec_testsuite
rmdir crates/c-api/wasm-c-api
rmdir crates/wasi-common/WASI
rmdir crates/wasi-crypto/spec
mv -v testsuite-${_spec_testsuite_commit} tests/spec_testsuite
mv -v wasm-c-api-${_wasm_c_api_commit} crates/c-api/wasm-c-api
mv -v WASI-${_WASI_commit} crates/wasi-common/WASI
mv -v wasi-crypto-${_wasi_crypto_commit} crates/wasi-crypto/spec
}