# 使用 Homebrew, apk, pacman, zypper 安装 crosstool-ng

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

## 安装

```sh
sudo av install brew:crosstool-ng
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install crosstool-ng
```

  证据: local Homebrew formula metadata

### Linux

- apk (92%):

```sh
sudo apk add crosstool-ng
```

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

- pacman (92%):

```sh
sudo pacman -S crosstool-ng
```

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

- zypper (92%):

```sh
sudo zypper install crosstool-ng
```

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

## 软件包事实

- **软件包键:** brew:crosstool-ng
- **软件包管理器:** Homebrew
- **版本:** 1.28.0
- **来源摘要:** Tool for building toolchains
- **主页:** <https://crosstool-ng.github.io/>
- **仓库:** <https://github.com/crosstool-ng/crosstool-ng>
- **最后更新:** 2026-06-22T14:03:06-07:00
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- ct-ng (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

- 页面生成时间: 2026-08-03
- 管理器版本: 1.28.0
## 项目历史与用法

crosstool-NG is a configurable toolchain builder focused on producing cross-compilation toolchains. It is a package-nerd staple because it automates the otherwise tedious assembly of binutils, GCC, C libraries, kernel headers, debuggers, and target-specific patches.

### 项目历史

The project traces its lineage to Dan Kegel's original crosstool scripts, patch repository, and prepared configuration files. Yann E. Morin later reorganized that work, added uClibc and menu-driven configuration support, and released the new implementation as crosstool-NG, short for crosstool Next Generation.

The official documentation says Yann Morin became busy with Buildroot and other projects in late 2014, after which Bryan Hundven became the new maintainer. The GitHub README also records older Mercurial repositories as read-only and points current development to GitHub.

### 采用历史

crosstool-NG grew around embedded Linux and cross-compilation communities, where prebuilt toolchains are often either too generic, too old, or mismatched to a target. Its documentation keeps a direct connection to the crossgcc mailing list and to projects such as Buildroot, ptxdist, and OpenEmbedded.

### 使用方式

Users configure crosstool-NG through a Linux-kernel-style menuconfig flow, producing a `.config` file that controls target architecture, component versions, installation prefix, samples, and options. Typical workflows start from a sample tuple, run `ct-ng menuconfig`, and then build a native, cross, cross-native, or Canadian Cross toolchain.

Because `ct-ng` is implemented as a make script, the project is familiar to source-based packaging users: it downloads and builds upstream components, applies version-specific patches, and installs an isolated toolchain such as under `/opt/x-tools/${CT_TARGET}`.

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

crosstool-NG matters in package history because it turns a compiler stack into a reproducible configurable artifact. It sits between full root filesystem builders and ad hoc compiler builds: unlike Buildroot or OpenEmbedded, its stated target is only the toolchain, leaving the resulting compiler usable by other build systems and package workflows.

### 时间线

- 2000s: Dan Kegel's crosstool provides the precursor scripts and patches
- 2000s: Yann E. Morin releases crosstool-NG with uClibc and menu-driven configuration support
- 2014: Bryan Hundven becomes maintainer
- 2025: crosstool-ng 1.28.0 release

### Related projects

- The documentation compares crosstool-NG with Buildroot, ptxdist, and OpenEmbedded, and credits the original crosstool project as its direct ancestor.

### 来源

- <https://crosstool-ng.github.io/docs/introduction/>
- <https://crosstool-ng.github.io/docs/configuration/>
- <https://crosstool-ng.github.io/docs/toolchain-types/>
- <https://crosstool-ng.github.io/docs/credits/>
- <https://github.com/crosstool-ng/crosstool-ng#readme>
- <https://github.com/crosstool-ng/crosstool-ng/releases>
- <https://formulae.brew.sh/formula/crosstool-ng>


## 安全说明

narrow executable package without higher-risk signals.

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


## Configuration and credential file locations

These source-backed paths show where this package keeps local settings or durable credentials. Automic Vault can use them as review targets for secret scanning, migration, and command approval.


## Configuration files

- Unix: .config
## 其他软件包管理器记录

- apk - crosstool-ng - 1.28.0-r1: normalized package name match | Alpine Linux edge package indexes: crosstool-ng from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Versatile tool for building (cross-)toolchains | https://crosstool-ng.github.io/
- apk - crosstool-ng-bash-completion - 1.28.0-r1: normalized package name match | Alpine Linux edge package indexes: crosstool-ng-bash-completion from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Bash completions for crosstool-ng | https://crosstool-ng.github.io/
- apk - crosstool-ng-doc - 1.28.0-r1: normalized package name match | Alpine Linux edge package indexes: crosstool-ng-doc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Versatile tool for building (cross-)toolchains (documentation) | https://crosstool-ng.github.io/
- pacman - crosstool-ng - 1.28.0-1: normalized package name match | Arch Linux sync databases: crosstool-ng from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A versatile (cross-)toolchain generator | https://crosstool-ng.github.io/
- zypper - crosstool-ng - 1.25.0-1.13: normalized package name match | openSUSE Tumbleweed package metadata: crosstool-ng from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Toolchain building framework | http://crosstool-ng.org


## Combined YAML source

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


## 来源

- pkg.so package database
- Geiger risk classifier
- curated configuration and credential file locations
- curated package history
- pkgdb category and tag curation
- external package-manager database matches
- cross-ecosystem install command graph
