macOS
brew install gperfprovider-native install command
brew / rank 673
Perfect hash function generator. Version 3.3 via Homebrew; verified from local package data.
install
brew install gperfprovider-native install command
overview
Perfect hash function generator
history
GNU gperf is the GNU perfect hash function generator: it reads a static set of keywords and emits C or C++ lookup code designed for collision-free recognition with one string comparison.
The GNU manual says the gperf utility was written in GNU C++ by Douglas C. Schmidt, with the general idea inspired by Keith Bostic's C algorithm distributed to net.sources around 1984. The manual frames the GNU program as a heavily modified, enhanced, and extended implementation created at the University of California, Irvine.
gperf belongs to the classic Unix compiler-tool family. Its input format resembles tools such as lex in using declarations and `%%` separators, while its output is ordinary C or C++ source that can be checked into or generated during builds.
GNU documents gperf as useful for static search sets such as compiler reserved words, assembler instruction opcodes, and shell built-ins. That made it attractive in source-based packaging ecosystems because generated lookup tables can be fast, deterministic, and dependency-light.
The GNU project page distributes gperf through the GNU FTP mirror network and points development to the Savannah project, placing it in the same distribution pattern as many older GNU build-time utilities. Homebrew, Debian, Ubuntu, Fedora, Arch, Nix, MacPorts, Chocolatey, and other package systems carry packages for it in the input metadata, reflecting its role as a small but widely available build dependency.
A user supplies a keyword file, optionally including struct declarations and gperf declarations, and gperf writes generated lookup code. The GNU page describes options for C or C++ output, switch statements or nested if statements instead of a hash table, and algorithm tuning.
Typical use is not interactive end-user work but build-time code generation. Projects use it when a fixed vocabulary needs fast membership tests without maintaining handwritten hash tables.
Package maintainers care about gperf because it often appears as a small build requirement that is easy to miss when bootstrapping language runtimes, compilers, and parser-heavy tools. It is old, tiny, and boring in the good way: a generated C file is easier to ship than a runtime dependency.
It also illustrates a packaging distinction between generated artifacts and generators. Some upstreams ship generated source, while others require gperf at build time, so package recipes need to know whether gperf is a native build tool or merely an optional maintainer tool.
security posture
narrow executable 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 |
|---|---|---|---|
gperf | 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:gperf |
|---|---|
| Version | 3.3 |
| Package manager | Homebrew |
| Homepage | https://www.gnu.org/software/gperf/ |
| Bottle | not recorded |
| Service | none declared |
source 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.