# 使用 Homebrew, apt, dnf, MacPorts, Nix, pacman, zypper 安装 kcov

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

## 安装

```sh
sudo av install brew:kcov
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install kcov
```

  证据: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install kcov
```

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

### Linux

- Debian apt (92%):

```sh
sudo apt install kcov
```

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

- dnf (92%):

```sh
sudo dnf install kcov
```

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

- Nix (92%):

```sh
nix profile install nixpkgs#kcov
```

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

- pacman (92%):

```sh
sudo pacman -S kcov
```

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

- zypper (92%):

```sh
sudo zypper install kcov
```

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

## 软件包事实

- **软件包键:** brew:kcov
- **软件包管理器:** Homebrew
- **软件包管理器页面:** <https://formulae.brew.sh/formula/kcov>
- **版本:** 43
- **来源摘要:** Code coverage tester for compiled programs, Python, and shell scripts
- **主页:** <https://simonkagstrom.github.io/kcov/>
- **仓库:** <https://github.com/SimonKagstrom/kcov>
- **上游文档:** <https://simonkagstrom.github.io/kcov/>
- **许可证:** GPL-2.0-or-later
- **源码归档:** <https://github.com/SimonKagstrom/kcov/archive/refs/tags/v43.tar.gz>
- **最后更新:** 2026-07-27T15:44:48+02:00
- **已生成:** 2026-08-04T22:13:35+00:00

## 可执行文件

- kcov (cli)
- kcov-system-daemon (cli)
- kcov (别名)
- kcov-system-daemon (别名)

## 依赖

- dwarfutils
- openssl@3

## 构建依赖

- cmake
- pkgconf

## macOS 提供的库

- curl

## 安装行为

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

## 版本和新鲜度

- 页面生成时间: 2026-08-04
- 管理器版本: 43
- 管理器更新时间: 2026-07-27
- 本地数据: OK
- 上游仓库: https://github.com/SimonKagstrom/kcov
- 信息: No cached GitHub release or tag data was available.
## 项目历史与用法

kcov is a code coverage tool for compiled programs, Python, and shell scripts. Its README says it began as a fork of Bcov and uses DWARF debugging information so programs can be measured without special compiler switches.

### 项目历史

Simon Kagstrom created the GitHub repository in August 2010. From the README's account, kcov started with Bcov's idea of using debug information for coverage and then expanded into a broader coverage-reporting tool with HTML, lcov-style output, Cobertura XML, JSON output, and CI integrations.

Release history documents platform and integration work through the 2010s and 2020s, including Docker images from v31, macOS binaries in v32, FreeBSD and macOS build work in v36, AArch64 support in release 38, RISC-V and Codecov updates in v41, and Cobertura/Jenkins fixes in v43.

### 采用历史

The batch input records packages in Homebrew, Debian, Fedora, MacPorts, Nix, Arch, and openSUSE. Upstream docs also point to an official Docker image, making kcov available through both traditional package managers and container workflows.

### 使用方式

A typical invocation runs kcov with an output directory and an executable plus arguments. Users filter included or excluded paths, merge multiple coverage runs, and publish reports to CI services such as Coveralls, Codecov, Jenkins, SonarQube, GitHub Actions, and GitLab CI.

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

kcov is notable because it brings coverage to binaries and scripts without requiring the build to be compiled with coverage instrumentation. For distro packagers and CI maintainers, that makes it useful for testing shell-heavy or mixed-language projects where gcov-style workflows are awkward.

### 时间线

- 2010-08-23: GitHub repository created.
- 2015-11-02: v29 release published.
- 2016-04-28: v31 release published; README documents official Docker images for releases since v31.
- 2018-08-23: v36 release included FreeBSD port and macOS build fixes.
- 2020-01-17: release 38 added AArch64 support.
- 2024-07-23: v43 release included Cobertura and Jenkins fixes.

### Related projects

- kcov descends from Bcov and integrates with coverage-reporting services including Coveralls, Codecov, Jenkins, SonarQube, GitHub Actions, and GitLab CI.

### 来源

- <https://bcov.sourceforge.net/>
- <https://github.com/SimonKagstrom/kcov>
- <https://github.com/SimonKagstrom/kcov/releases>
- <https://simonkagstrom.github.io/kcov>


## 安全说明

generalized runtime or code generation signal.

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

## 源数据库详情

- **Source Database:** Homebrew formula API
- **Tap:** homebrew/core
- **Full Name:** kcov
- **Version Scheme:** 0
- **Revision:** 1
- **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 - kcov - 43+dfsg-1+b4: normalized package name match | Debian stable package indexes: kcov from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Code coverage analysis using DWARF debugging information | https://simonkagstrom.github.io/kcov/
- Nix - kcov: normalized package name match | nixpkgs package indexes: pkgs/by-name/kc/kcov/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- dnf - kcov - 43-6.fc45: normalized package name match | Fedora Rawhide package metadata: kcov from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/210a2053c8e007daf9ae39c2a21daaed9b2ddd07d63ecffa597050361e73650c-primary.xml.zst | Code coverage tool without special compilation options | https://simonkagstrom.github.io/kcov
- pacman - kcov - 43-1: normalized package name match | Arch Linux sync databases: kcov from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | Code coverage tester for compiled programs, Python scripts and shell scripts | https://simonkagstrom.github.io/kcov
- zypper - kcov - 42-4.5: normalized package name match | openSUSE Tumbleweed package metadata: kcov from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Code coverage tool without special compilation options | https://github.com/SimonKagstrom/kcov
- MacPorts - kcov: normalized package name match | MacPorts ports tree: devel/kcov/Portfile from https://api.github.com/repos/macports/macports-ports/git/trees/master?recursive=1


## 相关链接

- [Source-control packages](https://pkg.so/zh-hans/source-control-tools/) - Belongs to a source-control command family.
- [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.
- [Text processing packages](https://pkg.so/zh-hans/text-processing-tools/) - Matched text, document, or structured-data processing metadata.
- [openssl@3](https://pkg.so/zh-hans/brew/openssl-3/) - Runtime dependency declared by Homebrew.
- [dwarfutils](https://pkg.so/zh-hans/brew/dwarfutils/) - Runtime dependency declared by Homebrew.
- [pkgconf](https://pkg.so/zh-hans/brew/pkgconf/) - Build dependency declared by Homebrew.
- [cmake](https://pkg.so/zh-hans/brew/cmake/) - Build dependency declared by Homebrew.
- [lcov](https://pkg.so/zh-hans/brew/lcov/) - Shares pkgdb curated category or tags: cli, coverage, developer-tools, testing.
- [bats-core](https://pkg.so/zh-hans/brew/bats-core/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [allure](https://pkg.so/zh-hans/brew/allure/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [mockolo](https://pkg.so/zh-hans/brew/mockolo/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [mockery](https://pkg.so/zh-hans/brew/mockery/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [pytest](https://pkg.so/zh-hans/brew/pytest/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [conftest](https://pkg.so/zh-hans/brew/conftest/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [tox](https://pkg.so/zh-hans/brew/tox/) - Shares pkgdb curated category or tags: cli, developer-tools, testing.
- [apib](https://pkg.so/zh-hans/brew/apib/) - Local package facts share a topical domain. Shared terms: cli, developer, developer-tools, openssl, openssl-3.
- [cargo-llvm-cov](https://pkg.so/zh-hans/brew/cargo-llvm-cov/) - Local package facts share a topical domain. Shared terms: cli, code, code-coverage, coverage, developer.

## Combined YAML source

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