# 使用 Homebrew, apk, apt, dnf, MacPorts, Nix 安装 cproto

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

## 安装

```sh
sudo av install brew:cproto
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install cproto
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install cproto
```

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

### Linux

- apk (92%):

```sh
sudo apk add cproto
```

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

- Debian apt (92%):

```sh
sudo apt install cproto
```

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

- dnf (92%):

```sh
sudo dnf install cproto
```

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

- Nix (92%):

```sh
nix profile install nixpkgs#cproto
```

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

## 软件包事实

- **软件包键:** brew:cproto
- **软件包管理器:** Homebrew
- **版本:** 4.8a
- **来源摘要:** Generate function prototypes for functions in input files
- **主页:** <https://invisible-island.net/cproto/>
- **最后更新:** 2026-07-27T01:51:16Z
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- cproto (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

cproto is a long-lived C source utility for generating function prototypes and declarations from C input files. It also supports conversions between old-style K&R function definitions and ANSI C style, plus lint-library generation.

### 项目历史

The official history says Chin Huang wrote and maintained cproto while at the University of Waterloo, with the first public version posted to comp.sources.unix in October 1989. Updates followed on comp.sources.misc through the early 1990s.

Thomas E. Dickey began working on cproto in June 1993, sending fixes and improvements to Huang. His work added lint-library support, GNU configure support, regression tests, diagnostics, and ports including VAX/VMS and HP/Apollo.

The modern Invisible Island page documents Dickey's continued maintenance, occasional fixes, generated documentation, release archives, and an official GitHub snapshots repository.

### 采用历史

cproto spread through the Unix source-sharing ecosystem before modern package managers, with releases posted to comp.sources.unix and comp.sources.misc. The official page later cataloged downstream package references for Debian, RPM-based systems, SlackBuilds, FreshPorts, NetBSD pkgsrc, AIX, HP-UX, and Repology.

### 使用方式

The manpage describes cproto as reading C source files or standard input and writing generated function prototypes to standard output. It can process K&R or ANSI-style definitions, optionally emit variable declarations, convert source forms, and generate lint-library source.

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

cproto is a classic small Unix development tool: it predates Git hosting, has Usenet-release provenance, uses generated manpage documentation, and remains packaged because it solves a narrow C maintenance problem that still appears in legacy codebases.

### 时间线

- 1989: Chin Huang's first cproto release was posted to comp.sources.unix volume 20, issue 39.
- 1991: cproto 2.0 and 2.2 updates appeared on comp.sources.misc.
- 1992: cproto 3.x updates continued on comp.sources.misc.
- 1993: Thomas E. Dickey began contributing fixes and improvements.
- 1994: cproto 4.0 appeared with Dickey's contributions including lint-library work, configure support, and additional ports.
- 2016: Thomas Dickey's cproto-snapshots GitHub repository was created for release and interim labels.

### Related projects

- The official history contrasts cproto with protoize and notes cproto's role in generating lint libraries.
- Dickey's page says he currently uses cproto to generate lint libraries for ncurses.

### 来源

- <https://invisible-island.net/cproto/cproto.html>
- <https://invisible-island.net/cproto/manpage/cproto.html>
- <https://github.com/ThomasDickey/cproto-snapshots>
- <https://api.github.com/repos/ThomasDickey/cproto-snapshots>


## 安全说明

没有找到 cproto 的匹配本地密钥处理 manifest。Nucleus 软件包元数据仍在此发布，以便未来覆盖拥有稳定的软件包 URL。


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

- Debian apt - cproto - 4.7x-1: normalized package name match | Debian stable package indexes: cproto from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | utilities to generate C function prototypes from C source code | https://invisible-island.net/cproto/cproto.html
- Nix - cproto: normalized package name match | nixpkgs package indexes: pkgs/by-name/cp/cproto/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - cproto - 4.7v-2: normalized package name match | Ubuntu 24.04 LTS package indexes: cproto from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | utilities to generate C function prototypes from C source code | https://invisible-island.net/cproto/cproto.html
- apk - cproto - 4.8a-r0: normalized package name match | Alpine Linux edge package indexes: cproto from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Generate C function prototypes from C source code | https://invisible-island.net/cproto/
- apk - cproto-doc - 4.8a-r0: normalized package name match | Alpine Linux edge package indexes: cproto-doc from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | Generate C function prototypes from C source code (documentation) | https://invisible-island.net/cproto/
- dnf - cproto - 4.8-2.fc45: normalized package name match | Fedora Rawhide package metadata: cproto from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Generates function prototypes and variable declarations from C code | http://invisible-island.net/
- MacPorts - cproto: normalized package name match | MacPorts ports tree: devel/cproto/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## Combined YAML source

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


## 来源

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