# 使用 Homebrew, apk, apt, MacPorts, Nix, pacman, zypper 安装 mruby

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

## 安装

```sh
sudo av install brew:mruby
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install mruby
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install mruby
```

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

### Linux

- apk (92%):

```sh
sudo apk add mruby
```

  证据: Alpine Linux edge package indexes: mruby from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install mruby
```

  证据: Debian stable package indexes: mruby from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- Nix (92%):

```sh
nix profile install nixpkgs#mruby
```

  证据: nixpkgs package indexes: pkgs/by-name/mr/mruby/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S mruby
```

  证据: Arch Linux sync databases: mruby from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install mruby
```

  证据: openSUSE Tumbleweed package metadata: mruby from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst

## 软件包事实

- **软件包键:** brew:mruby
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/mruby>
- **版本:** 4.0.0
- **来源摘要:** Lightweight implementation of the Ruby language
- **主页:** <https://mruby.org/>
- **仓库:** <https://github.com/mruby/mruby>
- **上游文档:** <https://mruby.org/>
- **许可证:** MIT
- **源码归档:** <https://github.com/mruby/mruby/archive/refs/tags/4.0.0.tar.gz>
- **已生成:** 2026-08-04T22:13:35+00:00

## 可执行文件

- mirb (cli)
- mrbc (cli)
- mruby (cli)
- mruby-config (cli)
- mruby-strip (cli)
- mirb (别名)
- mrbc (别名)
- mruby (别名)
- mruby-config (别名)
- mruby-strip (别名)

## 构建依赖

- bison

## 安装行为

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

## 版本和新鲜度

- 页面生成时间: 2026-08-04
- 管理器版本: 4.0.0
- 本地数据: OK
- 上游仓库: https://github.com/mruby/mruby
- 检测到的最新版本: 4.0.0 (当前)
- 信息: No package-manager update timestamp was available.
## 项目历史与用法

mruby is a lightweight, embeddable implementation of Ruby associated with Ruby creator Yukihiro Matsumoto and the mruby contributors. The official site describes it as complying with part of the ISO/IEC 30170 Ruby specification and designed to be linked into applications where MRI Ruby is too heavy. The project also acknowledges sponsorship by Japan's Ministry of Economy, Trade and Industry Regional Innovation Creation R&D Programs.

### 项目历史

The toolchain is deliberately small and embeddable. It provides the mruby interpreter, the mirb interactive shell, and mrbc, a compiler that emits mruby bytecode and can generate bytecode as a C source file. The GitHub README describes linking mruby into C or C++ applications, using the bin tools as examples, and customizing builds with mrbgems.

### 使用方式

mruby's ecosystem role differs from the main Ruby implementation. It targets constrained environments, native applications, firmware-like embeddings, and products that want Ruby syntax without shipping a full MRI runtime. The release history on the official site records 1.0.0 in February 2014 and later 2.x, 3.x, and 4.x lines, reflecting a long-running compatibility and maintenance effort. Package managers expose the command-line tools and development library for developers embedding Ruby behavior or compiling scripts into bytecode.

### 来源

- <https://formulae.brew.sh/formula/mruby>
- <https://github.com/mruby/mruby>
- <https://mruby.org/>
- <https://mruby.org/about/>


## 安全说明

narrow executable package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- narrow executable package without higher-risk signals

## 源数据库详情

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

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

- Debian apt - libmruby-dev - 3.3.0-1: normalized package name match | Debian stable package indexes: libmruby-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | lightweight implementation of the Ruby language (development files) | https://mruby.org/
- Debian apt - mruby - 3.3.0-1: normalized package name match | Debian stable package indexes: mruby from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | lightweight implementation of the Ruby language | https://mruby.org/
- Nix - mruby: normalized package name match | nixpkgs package indexes: pkgs/by-name/mr/mruby/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - libmruby-dev - 3.2.0-2: normalized package name match | Ubuntu 24.04 LTS package indexes: libmruby-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | lightweight implementation of the Ruby language (development files) | https://mruby.org/
- Ubuntu apt - mruby - 3.2.0-2: normalized package name match | Ubuntu 24.04 LTS package indexes: mruby from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | lightweight implementation of the Ruby language | https://mruby.org/
- apk - mruby - 3.3.0-r0: normalized package name match | Alpine Linux edge package indexes: mruby from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Lightweight Ruby | https://mruby.org
- apk - mruby-dev - 3.3.0-r0: normalized package name match | Alpine Linux edge package indexes: mruby-dev from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Lightweight Ruby (development files) | https://mruby.org
- apk - mruby-tools - 3.3.0-r0: normalized package name match | Alpine Linux edge package indexes: mruby-tools from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Lightweight Ruby (tools) | https://mruby.org
- pacman - mruby - 3.3.0-2: normalized package name match | Arch Linux sync databases: mruby from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | An interpreter for the Ruby programming language with the intention of being lightweight and easily embeddable | https://github.com/mruby/mruby
- zypper - libmruby3_4_0 - 3.4.0-1.6: normalized package name match | openSUSE Tumbleweed package metadata: libmruby3_4_0 from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Lightweight Ruby Embedded Environment | https://github.com/mruby/mruby/
- zypper - libmruby_core3_4_0 - 3.4.0-1.6: normalized package name match | openSUSE Tumbleweed package metadata: libmruby_core3_4_0 from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Lightweight Ruby Embedded Environment | https://github.com/mruby/mruby/
- zypper - mruby - 3.4.0-1.6: normalized package name match | openSUSE Tumbleweed package metadata: mruby from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Lightweight Ruby | https://github.com/mruby/mruby/
- zypper - mruby-devel - 3.4.0-1.6: normalized package name match | openSUSE Tumbleweed package metadata: mruby-devel from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Lightweight Ruby Embedded Environment | https://github.com/mruby/mruby/
- MacPorts - mruby: normalized package name match | MacPorts ports tree: lang/mruby/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## 相关链接

- [Package publisher tools](https://pkg.so/zh-hans/package-publishers/) - Belongs to a package publishing or registry command family.
- [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.
- [bison](https://pkg.so/zh-hans/brew/bison/) - Build dependency declared by Homebrew.
- [qsoas](https://pkg.so/zh-hans/brew/qsoas/) - Popular package that depends on this formula.
- [jruby](https://pkg.so/zh-hans/brew/jruby/) - Shares pkgdb curated category or tags: cli, language-runtime, ruby.
- [picoruby](https://pkg.so/zh-hans/brew/picoruby/) - Shares pkgdb curated category or tags: cli, embedded, language-runtime, ruby.
- [ruby-build](https://pkg.so/zh-hans/brew/ruby-build/) - Shares pkgdb curated category or tags: cli, language-runtime, ruby.
- [ruby@3.3](https://pkg.so/zh-hans/brew/ruby-3-3/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, ruby.
- [ruby-install](https://pkg.so/zh-hans/brew/ruby-install/) - Shares pkgdb curated category or tags: cli, language-runtime, ruby.
- [ruby@3.2](https://pkg.so/zh-hans/brew/ruby-3-2/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, ruby.
- [ruby@3.4](https://pkg.so/zh-hans/brew/ruby-3-4/) - Shares pkgdb curated category or tags: cli, interpreter, language-runtime, ruby.
- [opal](https://pkg.so/zh-hans/brew/opal/) - Shares pkgdb curated category or tags: cli, language-runtime, ruby.
- [jimtcl](https://pkg.so/zh-hans/brew/jimtcl/) - Local package facts share a topical domain. Shared terms: cli, embedded, implementation, interpreter, language.

## Combined YAML source

View the package source record on GitHub. [combined/mruby.yml](https://github.com/mxcl/pkgdb/blob/main/combined/mruby.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
