# 使用 Homebrew, apt, dnf, MacPorts, Nix 安装 gnu-prolog

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

## 安装

```sh
sudo av install brew:gnu-prolog
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install gnu-prolog
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install gprolog
```

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

### Linux

- Debian apt (92%):

```sh
sudo apt install gprolog
```

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

- dnf (92%):

```sh
sudo dnf install gprolog
```

  证据: Fedora Rawhide package metadata: gprolog from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst

- Nix (92%):

```sh
nix profile install nixpkgs#gprolog
```

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

## 软件包事实

- **软件包键:** brew:gnu-prolog
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/gnu-prolog>
- **版本:** 1.5.0
- **来源摘要:** Prolog compiler with constraint solving
- **主页:** <http://www.gprolog.org/>
- **仓库:** <https://github.com/didoudiaz/gprolog>
- **上游文档:** <https://www.gprolog.org/manual/gprolog.html>
- **许可证:** LGPL-3.0-or-later OR GPL-2.0-or-later
- **源码归档:** <https://ftpmirror.gnu.org/gnu/gprolog/gprolog-1.5.0.tar.gz>
- **已生成:** 2026-07-08T18:08:21+00:00

## 可执行文件

- fd2c (cli)
- gplc (cli)
- gprolog (cli)
- hexgplc (cli)
- ma2asm (cli)
- pl2wam (cli)
- wam2ma (cli)
- fd2c (别名)
- gplc (别名)
- gprolog (别名)
- hexgplc (别名)
- ma2asm (别名)
- pl2wam (别名)
- wam2ma (别名)

## 安装行为

- post-install 钩子: 未定义
- Bottle: 可用 于 arm64_big_sur, arm64_linux, arm64_monterey, arm64_sequoia, arm64_sonoma, arm64_tahoe, arm64_ventura, big_sur, catalina, monterey, sonoma, ventura

## 版本和新鲜度

- 页面生成时间: 2026-07-08
- 管理器版本: 1.5.0
- 本地数据: OK
- 上游仓库: http://www.gprolog.org/
- 信息: No package-manager update timestamp was available.
- 信息: Release/tag comparison is only available for GitHub repositories.
## 项目历史与用法

GNU Prolog is Daniel Diaz's free Prolog compiler with finite-domain constraint solving. Its defining trait is native-code compilation to small standalone executables, alongside an interactive top-level and debugger.

### 项目历史

The official GNU Prolog site says development began in January 1996 under the name Calypso. The design drew from two earlier Diaz systems: wamcc, a Prolog-to-C compiler based on the Warren Abstract Machine, and clp(FD), a finite-domain constraint system built around a low-level primitive for defining higher-level constraints.

### 采用历史

GNU Prolog occupies a practical niche among Prolog implementations: it emphasizes ISO Prolog compatibility, native executables, command-line compilation, C interoperability, and an integrated finite-domain solver. Those traits made it useful for logic-programming teaching, constraint examples, embeddable tools, and users who prefer a compiler-style workflow over a large image-based environment.

### 使用方式

Practitioners run gprolog for the interactive top-level and gplc to compile Prolog files, C files, WAM files, and related inputs into native programs. Constraint programmers use its FD predicates for arithmetic, Boolean, symbolic, and reified constraints, often paired with enumeration heuristics.

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

GNU Prolog matters in package ecosystems because it is both a language runtime and a compiler toolchain: packages install several helper binaries, architecture support matters, and releases document low-level ports across Unix, macOS, Windows, ARM, and RISC-V targets.

### 时间线

- 1996: Development started in January under the name Calypso.
- 1999: Manual copyright years begin for GNU Prolog documentation.
- 2010: Diaz, Abreu, and Codognet published an implementation paper describing GNU Prolog's native compiler and FD solver.
- 2021: Version 1.5.0 notes record the move of the source repository to GitHub.

### Related projects

- GNU Prolog is related to wamcc, clp(FD), the Warren Abstract Machine tradition, ISO Prolog systems, SWI-Prolog, and constraint-logic programming tools.

### 来源

- <http://www.gprolog.org/>
- <https://arxiv.org/abs/1012.2496>
- <https://github.com/didoudiaz/gprolog>
- <https://www.gprolog.org/manual/gprolog.html>


## 安全说明

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:** gnu-prolog
- **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 - gprolog: installed executable or alias match | MacPorts ports tree: lang/gprolog/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1
- Debian apt - gprolog - 1.4.5.0-3: installed executable or alias match | Debian stable package indexes: gprolog from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | GNU Prolog compiler | http://www.gprolog.org/
- Debian apt - gprolog-doc - 1.4.5.0-3: installed executable or alias match | Debian stable package indexes: gprolog-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | documentation for the GNU Prolog compiler | http://www.gprolog.org/
- Nix - gprolog: installed executable or alias match | nixpkgs package indexes: pkgs/by-name/gp/gprolog/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - gprolog - 1.4.5.0-3: installed executable or alias match | Ubuntu 24.04 LTS package indexes: gprolog from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | GNU Prolog compiler | http://www.gprolog.org/
- Ubuntu apt - gprolog-doc - 1.4.5.0-3: installed executable or alias match | Ubuntu 24.04 LTS package indexes: gprolog-doc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | documentation for the GNU Prolog compiler | http://www.gprolog.org/
- dnf - gprolog - 1.5.0-15.fc43: installed executable or alias match | Fedora Rawhide package metadata: gprolog from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | GNU Prolog is a free Prolog compiler | http://www.gprolog.org
- dnf - gprolog-docs - 1.5.0-15.fc43: installed executable or alias match | Fedora Rawhide package metadata: gprolog-docs from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/e5ca8ce900cd68f5419e1c39ae517343100b306336cbaeb70a3c153121d95094-primary.xml.zst | Documentation for GNU Prolog | http://www.gprolog.org


## 相关链接

- [Terminal utility packages](https://www.automicvault.com/zh-hans/pkg/terminal-utilities/) - Matched terminal and command-line workflow metadata.
- [Developer build packages](https://www.automicvault.com/zh-hans/pkg/developer-build-tools/) - Matched build, compiler, generator, or developer workflow metadata.
- [Language runtime packages](https://www.automicvault.com/zh-hans/pkg/language-runtime-packages/) - Matched language runtime, compiler, or interpreter metadata.
- [Networking and protocol packages](https://www.automicvault.com/zh-hans/pkg/networking-protocol-tools/) - Matched network, protocol, or remote-service metadata.
- [logtalk](https://www.automicvault.com/zh-hans/pkg/brew/logtalk/) - Popular package that depends on this formula.
- [swi-prolog](https://www.automicvault.com/zh-hans/pkg/brew/swi-prolog/) - Shares av.db curated category or tags: cli, compiler, language-runtime, logic-programming, prolog.
- [scryer-prolog](https://www.automicvault.com/zh-hans/pkg/brew/scryer-prolog/) - Shares av.db curated category or tags: cli, language-runtime, logic-programming, prolog.
- [mercury](https://www.automicvault.com/zh-hans/pkg/brew/mercury/) - Shares av.db curated category or tags: cli, compiler, language-runtime, logic-programming.
- [picat](https://www.automicvault.com/zh-hans/pkg/brew/picat/) - Shares av.db curated category or tags: cli, constraint-solving, language-runtime, logic-programming.
- [abcl](https://www.automicvault.com/zh-hans/pkg/brew/abcl/) - Shares av.db curated category or tags: cli, compiler, language-runtime.
- [algol68g](https://www.automicvault.com/zh-hans/pkg/brew/algol68g/) - Shares av.db curated category or tags: cli, compiler, language-runtime.
- [ats2-postiats](https://www.automicvault.com/zh-hans/pkg/brew/ats2-postiats/) - Shares av.db curated category or tags: cli, compiler, language-runtime.

## Combined YAML source

View the package source record on GitHub. [combined/gnu-prolog.yml](https://github.com/automic-vault/db/blob/main/combined/gnu-prolog.yml)


## 来源

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