Update build scripts and documents of workload samples for wasi-sdk-12.0 (#484)
Update the build scripts of sample workloads (meshoptimizer/bwa/wasm-av1) to use the wasi-sdk-12.0 firstly to build the workload and discard clang-11, as wasi-sdk-12 supports wasi, simd and pthread better. And update the related documents. Also modify wasm mini loader to sync up with the change of wasm normal loader. Signed-off-by: Wenyong Huang <wenyong.huang@intel.com>
This commit is contained in:
@ -1,8 +1,8 @@
|
||||
All workloads have similar a requirment of software dependencies. It includes
|
||||
**wasi-sdk**, **clang-11**, **emsdk**, **wabt** and **binaryen**
|
||||
All workloads have similar requirment of software dependencies, including
|
||||
**wasi-sdk**, **emsdk**, **wabt** and **binaryen**
|
||||
|
||||
> It might slightly different when using MacOS, and other linux distro than Ubuntu. This document only target
|
||||
Ubuntu 18.04 as an example.
|
||||
> There might be slight differences when using MacOS and other Linux distro than Ubuntu. This document only target
|
||||
Ubuntu 18.04 as example.
|
||||
|
||||
## Installation instructions
|
||||
|
||||
@ -11,28 +11,16 @@ use [preparation.sh](./preparation.sh) to install all dependencies before compil
|
||||
for details, the script includes below steps:
|
||||
|
||||
- **wasi-sdk**. Install
|
||||
[latest release](https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-11/wasi-sdk-11.0-linux.tar.gz)
|
||||
in */opt/wasi-sdk* or */opt/wasi-sdk-11*
|
||||
[latest release](https://github.com/WebAssembly/wasi-sdk/releases/download/wasi-sdk-12/wasi-sdk-12.0-linux.tar.gz)
|
||||
to */opt/wasi-sdk*
|
||||
|
||||
- **wabt**. Install
|
||||
[latest release](https://github.com/WebAssembly/wabt/releases/download/${WABT_VER}/wabt-1.0.19-ubuntu.tar.gz)
|
||||
in */opt/wabt* or */opt/wabt-1.0.19*
|
||||
|
||||
- **clang-11**. Refer to [the guide](https://apt.llvm.org/).
|
||||
[latest release](https://github.com/WebAssembly/wabt/releases/download/1.0.20/wabt-1.0.20-ubuntu.tar.gz)
|
||||
to */opt/wabt* or */opt/wabt-1.0.20*
|
||||
|
||||
- **emsdk**. Refer to [the guide](https://emscripten.org/docs/getting_started/downloads.html). Don't forget to activate
|
||||
emsdk and set up environment variables. Verify it with `echo ${EMSDK}`.
|
||||
|
||||
- **libclang_rt.builtins-wasm32.a**. *wasi* has its private rt library. Put it under clang search path
|
||||
|
||||
``` shell
|
||||
# copy it
|
||||
$ cp -r /opt/wasi-sdk-11.0/lib/clang/10.0.0/lib/wasi /usr/lib/llvm-11/lib/clang/11.0.0/lib/
|
||||
|
||||
# or just link it
|
||||
$ ln -sf /opt/wasi-sdk-11.0/lib/clang/10.0.0/lib/wasi/ /usr/lib/llvm-11/lib/clang/11.0.0/lib/
|
||||
```
|
||||
|
||||
- **binaryen**. Install
|
||||
[latest release](https://github.com/WebAssembly/binaryen/releases/download/version_97/binaryen-version_97-x86_64-linux.tar.gz)
|
||||
in */opt/binaryen* or */opt/binaryen-version_97*
|
||||
to */opt/binaryen* or */opt/binaryen-version_97*
|
||||
|
||||
Reference in New Issue
Block a user