# 使用 Homebrew, apk, dnf, Nix, pacman, apt, zypper 安装 libcpuid

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

## 安装

```sh
sudo av install brew:libcpuid
```

其他安装命令:

### macOS

- Homebrew (100%):

```sh
brew install libcpuid
```

  证据: local Homebrew formula metadata

### Linux

- apk (92%):

```sh
sudo apk add libcpuid
```

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

- dnf (92%):

```sh
sudo dnf install libcpuid
```

  证据: Fedora Rawhide package metadata: libcpuid 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#libcpuid
```

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

- pacman (92%):

```sh
sudo pacman -S libcpuid
```

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

- Debian apt (92%):

```sh
sudo apt install cpuidtool
```

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

- zypper (92%):

```sh
sudo zypper install libcpuid-devel
```

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

## 软件包事实

- **软件包键:** brew:libcpuid
- **软件包管理器:** Homebrew
- **版本:** 0.8.1
- **来源摘要:** Small C library for x86 CPU detection and feature extraction
- **主页:** <https://github.com/anrieff/libcpuid>
- **仓库:** <https://github.com/anrieff/libcpuid>
- **已生成:** 2026-08-03T19:37:03+00:00

## 可执行文件

- cpuid_tool (别名)

## 安装行为

- Bottle: 不可用

## 版本和新鲜度

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

LibCPUID is a C library and tool for identifying x86 CPUs and extracting CPUID-derived feature information. It wraps low-level CPUID and RDTSC access behind a portable API for Windows, Linux, and macOS.

### 项目历史

The official SourceForge project page describes LibCPUID as a small C library for x86 CPU detection and feature extraction, including vendor, model, brand string, code name, core counts, cache sizes, clock information, instruction-set checks, CPUID, and RDTSC.

The Doxygen introduction records version 0.1.0 on 2008-10-15 as an initial adaptation from wxfractgui sources. Early releases added Intel Core i7 topology fields, Win32 MSR-reading support, improved CPU-clock measurement, AMD Bulldozer support, Ivy Bridge support, and RdRand detection.

### 采用历史

LibCPUID fits the distribution niche for programs that need CPU model and feature detection without carrying their own CPUID tables. It is packaged by Homebrew, Debian and Ubuntu as `cpuidtool`, Fedora-family distributions, Arch, Alpine, Nix, and openSUSE-derived systems.

### 使用方式

Developers link against libcpuid to ask whether a processor supports features such as SSE2, 3DNow!, RdRand, or vendor/model-specific capabilities. Users can also run the packaged `cpuid_tool` executable to inspect CPU information from the command line.

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

LibCPUID is a classic system-library package: tiny surface area, architecture-specific knowledge, and a constant need for updates as Intel and AMD ship new models. It is valuable because every downstream project does not need to parse raw CPUID leaves and maintain marketing names itself.

### 时间线

- 2008-10-15: 0.1.0 released as an adaptation from wxfractgui sources.
- 2009-07-06: 0.1.1 added fields for Intel Core i7 topology enumeration.
- 2009-09-26: 0.1.2 added Win32 MSR-reading support.
- 2010-04-20: 0.1.3 improved CPU clock measurements.
- 2011-10-11: 0.2.0 added AMD Bulldozer support and changed `cpu_id_t` size.
- 2012-05-26: 0.2.1 added Ivy Bridge and RdRand detection.
- 2015-11-04: 0.2.2 added support for newer processors up to Haswell and Vishera.

### Related projects

- Related projects and interfaces include wxfractgui, the x86 CPUID instruction, RDTSC, MSR access, `cpuid_tool`, and CPU feature dispatch code in compilers and performance-sensitive libraries.

### 来源

- <https://formulae.brew.sh/formula/libcpuid>
- <https://github.com/anrieff/libcpuid>
- <https://libcpuid.sourceforge.net/>
- <https://libcpuid.sourceforge.net/doxy/index.html>


## 安全说明

library-like package without higher-risk signals.

- **Geiger 风险:** 绿色 / 低
- library-like package without higher-risk signals

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

- Debian apt - cpuidtool - 0.7.1+repack1-0.2: normalized package name match | Debian stable package indexes: cpuidtool from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | C library for x86/x86_64 CPU detection and feature extraction (tool) | https://github.com/anrieff/libcpuid
- Debian apt - libcpuid-dev - 0.7.1+repack1-0.2: normalized package name match | Debian stable package indexes: libcpuid-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | C library for x86/x86_64 CPU detection and feature extraction (headers) | https://github.com/anrieff/libcpuid
- Debian apt - libcpuid17 - 0.7.1+repack1-0.2: normalized package name match | Debian stable package indexes: libcpuid17 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | C library for x86/x86_64 CPU detection and feature extraction (shared lib) | https://github.com/anrieff/libcpuid
- Nix - libcpuid: normalized package name match | nixpkgs package indexes: pkgs/by-name/li/libcpuid/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - cpuidtool - 0.6.4+repack1-1: normalized package name match | Ubuntu 24.04 LTS package indexes: cpuidtool from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | C library for x86/x86_64 CPU detection and feature extraction (tool) | https://github.com/anrieff/libcpuid
- Ubuntu apt - libcpuid-dev - 0.6.4+repack1-1: normalized package name match | Ubuntu 24.04 LTS package indexes: libcpuid-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | C library for x86/x86_64 CPU detection and feature extraction (headers) | https://github.com/anrieff/libcpuid
- Ubuntu apt - libcpuid16 - 0.6.4+repack1-1: normalized package name match | Ubuntu 24.04 LTS package indexes: libcpuid16 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | C library for x86/x86_64 CPU detection and feature extraction (shared lib) | https://github.com/anrieff/libcpuid
- apk - libcpuid - 0.8.0-r0: normalized package name match | Alpine Linux edge package indexes: libcpuid from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | C library for x86 CPU detection and feature extraction | https://github.com/anrieff/libcpuid
- apk - libcpuid-dev - 0.8.0-r0: normalized package name match | Alpine Linux edge package indexes: libcpuid-dev from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | C library for x86 CPU detection and feature extraction (development files) | https://github.com/anrieff/libcpuid
- apk - libcpuid-tool - 0.8.0-r0: normalized package name match | Alpine Linux edge package indexes: libcpuid-tool from https://dl-cdn.alpinelinux.org/alpine/edge/community/x86_64/APKINDEX.tar.gz | C library for x86 CPU detection and feature extraction (CLI tool) | https://github.com/anrieff/libcpuid
- dnf - libcpuid - 0.8.1-8.fc45: normalized package name match | Fedora Rawhide package metadata: libcpuid from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Provides CPU identification for x86 and ARM | https://github.com/anrieff/libcpuid
- dnf - libcpuid-devel - 0.8.1-8.fc45: normalized package name match | Fedora Rawhide package metadata: libcpuid-devel from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Development files for libcpuid | https://github.com/anrieff/libcpuid
- dnf - libcpuid-static - 0.8.1-8.fc45: normalized package name match | Fedora Rawhide package metadata: libcpuid-static from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Static development files for libcpuid | https://github.com/anrieff/libcpuid
- dnf - python3-libcpuid - 0.8.1-8.fc45: normalized package name match | Fedora Rawhide package metadata: python3-libcpuid from https://dl.fedoraproject.org/pub/fedora/linux/development/rawhide/Everything/x86_64/os/repodata/07190dc5ae9f35ae73866675fed6d95fe6e8d9fe22c9d7cdf85862cb2ed24a4c-primary.xml.zst | Python bindings for the libcpuid library | https://github.com/anrieff/libcpuid
- pacman - libcpuid - 0.8.1-1: normalized package name match | Arch Linux sync databases: libcpuid from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz | A small C library for x86 CPU detection and feature extraction | http://libcpuid.sourceforge.net
- zypper - libcpuid-devel - 0.8.1-2.3: normalized package name match | openSUSE Tumbleweed package metadata: libcpuid-devel from https://download.opensuse.org/tumbleweed/repo/oss/repodata/50b07339cb64c8ed4091bdbabddadc1ff5737b090e478818a195b40d8a3292861a879139b4a3987c31109699fde9fbf4a716367ddf4eef77da75f96e3193d6ed-primary.xml.zst | Development files for libcpuid | https://github.com/anrieff/libcpuid


## Combined YAML source

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