From 7993e352279afef2caa40f32854c9b745f2af7d7 Mon Sep 17 00:00:00 2001 From: Frank Denis Date: Mon, 22 Apr 2019 23:53:43 +0200 Subject: [PATCH] Try wasmer and lucet as alternatives to wasmtime However: - wasmer seems to have issues with signals, causing some tests to fail - lucet's --dir option doesn't seem to work with relative paths These are temporary limitations, that are likely to be fixed soon. --- test/default/wasi-test-wrapper.sh | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/test/default/wasi-test-wrapper.sh b/test/default/wasi-test-wrapper.sh index 07634efd..e7092107 100755 --- a/test/default/wasi-test-wrapper.sh +++ b/test/default/wasi-test-wrapper.sh @@ -1,4 +1,11 @@ #! /bin/sh -wasmtime -o --dir=. "$1" - +if command -v wasmtime >/dev/null; then + wasmtime -o --dir=. "$1" && exit 0 +fi +if command -v wasmer >/dev/null; then + wasmer run "$1" --dir=. && exit 0 +fi +if command -v lucetc-wasi >/dev/null && command -v lucet-wasi >/dev/null; then + lucetc-wasi -o "${1}.so" --opt-level best "$1" && lucet-wasi "$1.so" && exit 0 +fi