# 使用 Homebrew, MacPorts 安装 wasm3

查看 wasm3 的安装路径、可执行文件、元数据以及面向 AI 代理工作流的安全说明。

## 安装

```sh
sudo av install brew:wasm3
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install wasm3
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install wasm3
```

  证据: MacPorts ports tree: lang/wasm3/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1

## 软件包事实

- **软件包键:** brew:wasm3
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/wasm3>
- **版本:** 0.5.0
- **来源摘要:** High performance WebAssembly interpreter
- **主页:** <https://twitter.com/wasm3_engine>
- **仓库:** <https://github.com/wasm3/wasm3>
- **上游文档:** <https://twitter.com/wasm3_engine>
- **许可证:** MIT
- **源码归档:** <https://github.com/wasm3/wasm3/archive/refs/tags/v0.5.0.tar.gz>
- **最后更新:** 2026-06-15T10:21:23-04:00
- **已生成:** 2026-08-04T22:13:35+00:00

## 可执行文件

- wasm3 (cli)
- wasm3 (别名)

## 依赖

- uvwasi

## 构建依赖

- cmake

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 arm64_linux, arm64_sequoia, arm64_sonoma, arm64_tahoe, sonoma, x86_64_linux

## 版本和新鲜度

- 页面生成时间: 2026-08-04
- 管理器版本: 0.5.0
- 管理器更新时间: 2026-06-15
- 本地数据: OK
- 上游仓库: https://github.com/wasm3/wasm3
- 检测到的最新版本: v0.5.0 (当前)
## 项目历史与用法

Wasm3 is a compact WebAssembly interpreter written in C, positioned by its maintainers as a fast and highly portable runtime rather than a JIT compiler. Its niche is running Wasm in places where engines such as V8, Wasmtime, or Wasmer are too large, unavailable, or unsuitable because dynamic code generation is restricted.

### 项目历史

The source tree identifies Wasm3 as a high-performance WebAssembly interpreter with 2019 copyrights for Steven Massey and Volodymyr Shymanskyy. The project documentation explains that its M3 interpreter strategy existed before this specific Wasm runtime and was adapted because the approach fit WebAssembly's bytecode structure.

The interpreter documentation describes M3 as a C implementation using a novel high-performance topology. Instead of emphasizing ahead-of-time or just-in-time compilation, Wasm3 translates WebAssembly opcodes into internal operations intended to execute efficiently in an interpreter, making it a useful counterpoint to the compiler-heavy runtimes that dominate server-side Wasm.

### 采用历史

Wasm3's adoption story is strongest in embedded and constrained-device circles. The companion Arduino repository says the runtime needs roughly 64 KB of flash and 10 KB of RAM for minimal functionality and lists devices such as ESP32, ESP8266, Arduino MKR, Particle, ST Nucleo, BluePill, Nordic nRF5, and Teensy as verified targets.

The main repository also frames Wasm3 as universal, with topics covering embedded, IoT, serverless, containers, sandboxing, smart contracts, and edge computing. That breadth reflects its role as a small embeddable engine: developers use it when they want Wasm as a portable plugin or scripting format but cannot afford a heavier optimizing runtime.

### 使用方式

Command-line users run wasm3 against a .wasm file to execute a module locally. Embedded users more often link the C runtime into firmware or an application host, load a Wasm module from flash, storage, or a network update path, and expose only a small set of host functions to the guest module.

Package-nerd usage tends to compare Wasm3 with WAMR, wasmi, wasm-interp, and JIT runtimes. Wasm3 is chosen for portability and low memory ceilings; Wasmtime or Wasmer are usually chosen when standard WASI coverage, component-model support, or peak JIT/AOT performance matters more.

### 为什么软件包爱好者会关心

Wasm3 is significant because it keeps the interpreter design space visible in a WebAssembly ecosystem often led by optimizing compilers. For package maintainers, it is a reminder that the same .wasm artifact can target browsers, server runtimes, and tiny boards, but that the host ABI and resource budget determine which runtime is realistic.

It also matters as a minimal embeddable dependency: a C runtime with a CLI and microcontroller examples is easier to fit into unusual packaging environments than a larger Rust or C++ runtime stack.

### 时间线

- 2019: Wasm3 source files identify the project as a high-performance WebAssembly interpreter by Steven Massey and Volodymyr Shymanskyy.
- 2020: Wasm3 was discussed publicly as a fast WebAssembly interpreter in C, with attention on its M3 execution model.
- 2020s: The Arduino and embedded repositories documented operation on small microcontrollers, giving Wasm3 a durable niche among constrained-device Wasm runtimes.

### Related projects

- WAMR is a related lightweight WebAssembly runtime aimed at embedded, IoT, edge, and trusted-execution use cases.
- Wasmtime and Wasmer are heavier standalone runtimes with stronger WASI, embedding, and compiler stories.
- The WebAssembly reference interpreter and wasm-interp are useful comparison points for correctness and testing rather than minimal embedded deployment.

### 来源

- <https://github.com/wasm3/wasm3>
- <https://github.com/wasm3/wasm3-arduino>
- <https://github.com/wasm3/wasm3/blob/main/docs/Interpreter.md>
- <https://github.com/wasm3/wasm3/blob/main/source/wasm3.h>


## 安全说明

generalized runtime or code generation signal.

- **Geiger 风险:** yellow / 中
- generalized runtime or code generation signal

## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** wasm3
- **Version Scheme:** 0
- **Revision:** 0
- **Bottle Stable Root URL:** <https://ghcr.io/v2/homebrew/core>
- **Deprecated:** no
- **Disabled:** no
- **Keg Only:** no
- **URL Keys:** stable

## 其他软件包管理器记录

- MacPorts - wasm3: normalized package name match | MacPorts ports tree: lang/wasm3/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## 相关链接

- [Secret-risk packages](https://pkg.so/zh-hans/secret-risk-packages/) - Has protected-tool coverage, approval-gate, or non-low Geiger security signals.
- [Terminal utility packages](https://pkg.so/zh-hans/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Language runtime packages](https://pkg.so/zh-hans/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [Networking and protocol packages](https://pkg.so/zh-hans/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [cmake](https://pkg.so/zh-hans/brew/cmake/) - Build dependency declared by Homebrew.
- [wasm-tools](https://pkg.so/zh-hans/brew/wasm-tools/) - Package name indicates the same formula family.
- [wazero](https://pkg.so/zh-hans/brew/wazero/) - Shares pkgdb curated category or tags: cli, language-runtime, runtime, wasm, webassembly.
- [python@3.14](https://pkg.so/zh-hans/brew/python-3-14/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [python@3.13](https://pkg.so/zh-hans/brew/python-3-13/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [python@3.12](https://pkg.so/zh-hans/brew/python-3-12/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [python@3.11](https://pkg.so/zh-hans/brew/python-3-11/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [luajit](https://pkg.so/zh-hans/brew/luajit/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [python@3.10](https://pkg.so/zh-hans/brew/python-3-10/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [python@3.9](https://pkg.so/zh-hans/brew/python-3-9/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, runtime.
- [rustpython](https://pkg.so/zh-hans/brew/rustpython/) - Local package facts share a topical domain. Shared terms: cli, interpreter, language, language-runtime, runtime.
- [wasm-micro-runtime](https://pkg.so/zh-hans/brew/wasm-micro-runtime/) - Local package facts share a topical domain. Shared terms: cli, language, language-runtime, runtime, wasm.

## Combined YAML source

View the package source record on GitHub. [combined/wasm3.yml](https://github.com/mxcl/pkgdb/blob/main/combined/wasm3.yml)


## 来源

- pkg.so package database
- Geiger risk classifier
- package-page enrichment
- curated package history
- package version freshness
- pkgdb category and tag curation
- package relationship graph
- external package-manager database matches
- cross-ecosystem install command graph
