mirror of
https://github.com/bytecodealliance/wasm-micro-runtime.git
synced 2025-05-08 20:56:13 +00:00

- Merge unused field `used_to_be_wasi_ctx` in `AOTModuleInstance` into `reserved` area - Add field `memory_lock` in `WASMMemoryInstance` for future refactor - Go binding: fix type error https://github.com/bytecodealliance/wasm-micro-runtime/issues/3220 - Python binding: type annotation uses the union operator "|", which requires Python version >=3.10
30 lines
679 B
Markdown
30 lines
679 B
Markdown
# WARM API
|
|
|
|
* **Notice**: The python package `wamr.wamrapi.wamr` need python >= `3.10`.
|
|
|
|
## Setup
|
|
|
|
### Pre-requisites
|
|
|
|
Install requirements,
|
|
|
|
```shell
|
|
pip install -r requirements.txt
|
|
```
|
|
|
|
### Build native lib and update bindings
|
|
|
|
The following command builds the iwasm library and generates the Python bindings,
|
|
|
|
```sh
|
|
# In WAMR root directory
|
|
bash language-bindings/python/utils/create_lib.sh
|
|
```
|
|
|
|
This will build and copy libiwasm into the package.
|
|
|
|
## Samples
|
|
|
|
- **[basic](./samples/basic)**: Demonstrating how to use basic python bindings.
|
|
- **[native-symbol](./samples/native-symbol)**: Desmostrate how to call WASM from Python and how to export Python functions into WASM.
|