macOS
brew install libcmphlocal Homebrew formula metadata
sudo port install cmphMacPorts ports tree · textproc/cmph/Portfile · source: api.github.com
brew / rank 14623
C minimal perfect hashing library. Version 2.0.2 via Homebrew; verified from local package data. Also installable with apk: sudo apk add libcmph.
install
brew install libcmphlocal Homebrew formula metadata
sudo port install cmphMacPorts ports tree · textproc/cmph/Portfile · source: api.github.com
sudo apk add libcmphAlpine Linux edge package indexes · libcmph · source: dl-cdn.alpinelinux.org
nix profile install nixpkgs#cmphnixpkgs package indexes · pkgs/by-name/cm/cmph/package.nix · source: api.github.com
sudo apt install libcmph-devDebian stable package indexes · libcmph-dev · source: deb.debian.org
overview
C minimal perfect hashing library
history
CMPH is a C library and command-line tool for building minimal perfect hash functions. It targets static key sets where compact storage and collision-free lookup matter more than insertion or deletion.
The CMPH site frames the project around a gap in free software support for minimal perfect hashing, distinguishing it from GNU gperf by emphasizing very large key sets rather than small generated perfect-hash functions. Its documentation collects several algorithms, including CHD, BDZ, BMZ, BRZ, CHM, and FCH.
By the 1.x and 2.x news entries, CMPH had grown beyond a single algorithm implementation into a practical library with packed-function support, memory-mappable output, an external-memory BRZ path for very large sets, and an experimental C++ interface for map-like use cases.
CMPH has remained a niche but durable package because minimal perfect hashes are a specialized data-structure tool. It appears in Homebrew, Debian and Ubuntu development packages, MacPorts, Nix, Alpine, and other package collections for developers who need static dictionary or key-index construction.
Typical usage is offline construction of a hash function from a fixed key set, followed by storage or embedding of the generated function. The official examples show the C API creating a minimal perfect hash from an in-memory vector and dumping it to a file.
CMPH is the kind of package that matters disproportionately to systems and search developers: it packages academic minimal-perfect-hashing algorithms into a reusable C interface and a small CLI. Its appeal is that it turns a static corpus into dense one-probe lookup tables without hauling in a database.
security posture
library-like package without higher-risk signals.
green risk · low confidence · appliance
Before unattended agent use, check whether the tool reads plaintext credentials, writes remote state, publishes artifacts, or shells out to plugins.
executables
| Command | Kind | Exposure | Note |
|---|---|---|---|
cmph | executable | indexed executable | Discovered from the local executable index. |
freshness
These signals separate page generation age, package-manager activity, and upstream release comparison. Version lag is warned only when an evidence URL and comparable versions are present.
install metadata
| Package key | brew:libcmph |
|---|---|
| Version | 2.0.2 |
| Package manager | Homebrew |
| Homepage | https://cmph.sourceforge.net/ |
| Bottle | not recorded |
| Service | none declared |
source database matches
Matches are pulled from external package-manager indexes and kept separate from local Automic Vault package links.
libcmph 2.0.2-r6
A minimal perfect hash C library
sudo apk add libcmphcmph
sudo port install cmphlibcmph-dev 2.0.2-3.1
C Minimal Perfect Hashing Library development files
sudo apt install libcmph-devlibcmph-tools 2.0.2-3.1
C Minimal Perfect Hashing Library command line utilities
sudo apt install libcmph-toolslibcmph0t64 2.0.2-3.1
C Minimal Perfect Hashing Library
sudo apt install libcmph0t64cmph
nix profile install nixpkgs#cmphlibcmph-dev 2.0.2-3.1build1
C Minimal Perfect Hashing Library development files
sudo apt install libcmph-devlibcmph-tools 2.0.2-3.1build1
C Minimal Perfect Hashing Library command line utilities
sudo apt install libcmph-toolslibcmph0t64 2.0.2-3.1build1
C Minimal Perfect Hashing Library
sudo apt install libcmph0t64cmph 2.0.2-r6
A minimal hash C library - utility application
sudo apk add cmphcmph-dev 2.0.2-r6
A minimal hash C library - utility application (development files)
sudo apk add cmph-devcmph-doc 2.0.2-r6
A minimal hash C library - utility application (documentation)
sudo apk add cmph-docsource trail
This page is generated by av-web from the private package SQLite artifact built by scripts/generate-pkg-sqlite.py.
View the package source record on GitHub.