swiftwasm / carton

📦 Watcher, bundler, and test runner for your SwiftWasm apps
Apache License 2.0
406 stars 44 forks source link

Make Wasmer an optional dependency? #177

Open MaxDesiatov opened 3 years ago

MaxDesiatov commented 3 years ago

After https://github.com/swiftwasm/carton/issues/42 is resolved, we'll be able to run tests in browsers. We should still allow using Wasmer, but I think it's easier to expect that people have a browser installed than Wasmer? Especially as currently it's not as easy to install Wasmer on Apple Silicon via Homebrew. WDYT?

kateinoigakukun commented 3 years ago

I think if we can embed a Wasm runtime in carton, it would be easier to install carton. For example, linking libwasmtime.a.

syrusakbary commented 3 years ago

Just seen this. Wasmer also should be easily embedded via linking if that's where the needs are (you can find libwasmer.dylib/a in the Wasmer releases).

Note: Wasmer fully supports Apple Silicon (writing this reply from a new M1 macbook, where Wasmer is successfully built and tested). The main reason Wasmer can't yet be installed via brew have nothing to do with Wasmer itself, but mainly because brew itself doesn't yet fully support Big Sur nor Rust. I have hopes they will be able to fix it soon!

syrusakbary commented 3 years ago

Note: we just discovered a small but on Wasmer when using it on M1 in the latest Rust nightly (via rustup nightly). We are working on fixing it!

Update: the bug is now solved and M1 is fully supported again!