summarylogtreecommitdiffstats
diff options
context:
space:
mode:
authorChocobo12020-02-28 03:13:39 +0800
committerChocobo12020-02-28 03:30:11 +0800
commit5c5434c9215b2e3326590ec3c640921c9076b4e6 (patch)
tree81456e00d59798446abdf006f6bb40723a401912
downloadaur-5c5434c9215b2e3326590ec3c640921c9076b4e6.tar.gz
newpkg: wasmtime-git 0.12.0.r20.g35d5c6bd-1
-rw-r--r--.SRCINFO18
-rw-r--r--PKGBUILD46
2 files changed, 64 insertions, 0 deletions
diff --git a/.SRCINFO b/.SRCINFO
new file mode 100644
index 000000000000..9593236a6418
--- /dev/null
+++ b/.SRCINFO
@@ -0,0 +1,18 @@
+pkgbase = wasmtime-git
+ pkgdesc = Standalone JIT-style runtime for WebAssembly
+ pkgver = 0.12.0.r20.g35d5c6bd
+ pkgrel = 1
+ url = https://wasmtime.dev/
+ arch = i686
+ arch = x86_64
+ license = apache
+ makedepends = git
+ makedepends = rust
+ depends = gcc-libs
+ provides = wasmtime
+ conflicts = wasmtime
+ source = git+https://github.com/bytecodealliance/wasmtime.git
+ sha256sums = SKIP
+
+pkgname = wasmtime-git
+
diff --git a/PKGBUILD b/PKGBUILD
new file mode 100644
index 000000000000..0d8f0bb52ca7
--- /dev/null
+++ b/PKGBUILD
@@ -0,0 +1,46 @@
+# Maintainer: Chocobo1 <chocobo1 AT archlinux DOT net>
+
+pkgname=wasmtime-git
+pkgver=0.12.0.r20.g35d5c6bd
+pkgrel=1
+pkgdesc="Standalone JIT-style runtime for WebAssembly"
+arch=('i686' 'x86_64')
+url="https://wasmtime.dev/"
+license=('apache')
+depends=('gcc-libs')
+makedepends=('git' 'rust')
+provides=('wasmtime')
+conflicts=('wasmtime')
+source=("git+https://github.com/bytecodealliance/wasmtime.git")
+sha256sums=('SKIP')
+
+
+prepare() {
+ cd "wasmtime"
+
+ git submodule update --init
+}
+
+pkgver() {
+ cd "wasmtime"
+
+ _tag=$(git tag -l --sort -v:refname | head -n1)
+ _rev=$(git rev-list --count $_tag..HEAD)
+ _hash=$(git rev-parse --short HEAD)
+ printf "%s.r%s.g%s" "$_tag" "$_rev" "$_hash" | sed 's/v//'
+}
+
+check() {
+ cd "wasmtime"
+
+ #cargo test --release
+}
+
+package() {
+ cd "wasmtime"
+
+ cargo install --root "$pkgdir/usr" --path "$srcdir/wasmtime"
+ install -Dm644 "README.md" -t "$pkgdir/usr/share/doc/wasmtime"
+
+ rm -f "$pkgdir/usr"/.crates*
+}