# Install hwloc with Homebrew, apk, apt, dnf, MacPorts, Nix, pacman, zypper

Portable abstraction of the hierarchical topology of modern architectures. Version 2.14.0 via Homebrew; verified 2026-07-14. Also installable with debian: sudo apt install hwloc.

## Install

```sh
sudo av install brew:hwloc
```

Additional install commands:

### macOS

- Homebrew (100%):

```sh
brew install hwloc
```

  Evidence: local Homebrew formula metadata

- MacPorts (94%):

```sh
sudo port install hwloc
```

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

### Linux

- apk (92%):

```sh
sudo apk add hwloc
```

  Evidence: Alpine Linux edge package indexes: hwloc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz

- Debian apt (92%):

```sh
sudo apt install hwloc
```

  Evidence: Debian stable package indexes: hwloc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz

- dnf (92%):

```sh
sudo dnf install hwloc
```

  Evidence: Fedora Rawhide package metadata: hwloc 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#hwloc
```

  Evidence: nixpkgs package indexes: pkgs/by-name/hw/hwloc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1

- pacman (92%):

```sh
sudo pacman -S hwloc
```

  Evidence: Arch Linux sync databases: hwloc from https://geo.mirror.pkgbuild.com/extra/os/x86_64/extra.db.tar.gz

- zypper (92%):

```sh
sudo zypper install hwloc
```

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

## Package facts

- **Package key:** brew:hwloc
- **Package manager:** Homebrew
- **Version:** 2.14.0
- **Source summary:** Portable abstraction of the hierarchical topology of modern architectures
- **Homepage:** <https://www.open-mpi.org/projects/hwloc/>
- **Repository:** <https://github.com/open-mpi/hwloc>
- **Last updated:** 2026-07-14T16:33:15Z
- **Generated:** 2026-08-03T19:37:03+00:00

## Executables

- hwloc-annotate (alias)
- hwloc-bind (alias)
- hwloc-calc (alias)
- hwloc-compress-dir (alias)
- hwloc-diff (alias)
- hwloc-distrib (alias)
- hwloc-gather-topology (alias)
- hwloc-info (alias)
- hwloc-ls (alias)
- hwloc-patch (alias)
- hwloc-ps (alias)
- lstopo (alias)
- lstopo-no-graphics (alias)

## Install behavior

- Bottle: not available

## Freshness

- Page generated: 2026-08-03
- Package-manager version: 2.14.0
## Project history and usage

hwloc, Hardware Locality, is a portable library and command-line tool suite for discovering and using machine topology: NUMA nodes, packages, cores, processing units, caches, I/O devices, and locality relationships. It is a system and HPC building block rather than a single end-user command.

### Project history

The Open MPI project history says hwloc evolved from and merged the libtopology and Portable Linux Processor Affinity projects because they overlapped functionally and ideologically. It was released under the hwloc name as an Open MPI sub-project and is mostly developed by the TADaaM team at Inria in Bordeaux.

The NEWS file covers features since version 0.9 and carries 2009 copyright notices for CNRS, Inria, Universite Bordeaux, and Cisco Systems. The 1.0.0 tag dates to May 2010. Later major lines expanded the API and the command-line suite while preserving the central promise: make topology discovery and binding portable across operating systems and hardware generations.

### Adoption history

Open MPI's project page lists downstream or related users including MPC, Newmadeleine, StarPU, Kokkos, oneTBB, memkind, H2M, Seastar, PaStiX, LIKWID, TensorFlow, GEOPM, and OpenPMIx. The package metadata shows broad distribution across Homebrew, Debian, Ubuntu, Fedora-family, Alpine, Arch, Nix, MacPorts, and openSUSE ecosystems.

### How it is used

Users run tools such as `lstopo`, `hwloc-info`, `hwloc-bind`, `hwloc-calc`, and related utilities to inspect topology, bind processes, calculate CPU or NUMA sets, export XML topologies, and debug locality issues. Developers use the C API to make runtime, scheduler, MPI, database, and performance tools topology-aware.

### Why package nerds care

hwloc is package-nerd-significant because it is often pulled in indirectly by high-performance and systems software. A package manager may present it as a small system formula, but it encodes hard-won portability across Linux, BSDs, macOS, Windows, Solaris, AIX, cpusets, NUMA, caches, GPUs, and other topology surfaces.

### Timeline

- 2009: NEWS history begins at version 0.9, with CNRS, Inria, Universite Bordeaux, and Cisco copyright notices.
- 2010: 1.0.0 release tag published.
- 2013: GitHub mirror/repository metadata begins for the Open MPI hwloc repo.
- 2018: 2.0.x line introduced a new major API era; 2.0.0 was marked as having a broken ABI, with 2.0.1 or later recommended.
- 2026: NEWS documents 3.0.0 API changes, removals, and topology-info updates.

### Related projects

- hwloc is historically related to libtopology and PLPA, and operationally related to Open MPI, PMIx, NUMA libraries, CPU binding APIs, StarPU, Kokkos, oneTBB, memkind, TensorFlow, and other software that needs hardware-locality knowledge.

### Sources

- Open MPI hwloc project history, README, NEWS, release archives, repository metadata, and Homebrew package metadata were used.


## Security Notes

broad file, network, media, or database tool signal.

- **Geiger risk:** blue / medium
- broad file, network, media, or database tool signal

## Other Package-Manager Records

- Debian apt - hwloc - 2.12.0-4: normalized package name match | Debian stable package indexes: hwloc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - utilities | https://www.open-mpi.org/projects/hwloc/
- Debian apt - hwloc-nox - 2.12.0-4: normalized package name match | Debian stable package indexes: hwloc-nox from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - non-X version of utilities | https://www.open-mpi.org/projects/hwloc/
- Debian apt - libhwloc-common - 2.12.0-4: normalized package name match | Debian stable package indexes: libhwloc-common from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - common files | https://www.open-mpi.org/projects/hwloc/
- Debian apt - libhwloc-dev - 2.12.0-4: normalized package name match | Debian stable package indexes: libhwloc-dev from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - static libs and headers | https://www.open-mpi.org/projects/hwloc/
- Debian apt - libhwloc-doc - 2.12.0-4: normalized package name match | Debian stable package indexes: libhwloc-doc from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - documentation | https://www.open-mpi.org/projects/hwloc/
- Debian apt - libhwloc-plugins - 2.12.0-4: normalized package name match | Debian stable package indexes: libhwloc-plugins from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - plugins | https://www.open-mpi.org/projects/hwloc/
- Debian apt - libhwloc15 - 2.12.0-4: normalized package name match | Debian stable package indexes: libhwloc15 from https://deb.debian.org/debian/dists/stable/main/binary-amd64/Packages.xz | Hierarchical view of the machine - shared libs | https://www.open-mpi.org/projects/hwloc/
- Nix - hwloc: normalized package name match | nixpkgs package indexes: pkgs/by-name/hw/hwloc/package.nix from https://api.github.com/repos/NixOS/nixpkgs/git/trees/master?recursive=1
- Ubuntu apt - hwloc - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: hwloc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - utilities | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - hwloc-nox - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: hwloc-nox from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - non-X version of utilities | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - libhwloc-common - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libhwloc-common from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - common files | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - libhwloc-dev - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libhwloc-dev from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - static libs and headers | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - libhwloc-doc - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libhwloc-doc from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - documentation | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - libhwloc-plugins - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libhwloc-plugins from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - plugins | https://www.open-mpi.org/projects/hwloc/
- Ubuntu apt - libhwloc15 - 2.10.0-1build1: normalized package name match | Ubuntu 24.04 LTS package indexes: libhwloc15 from https://archive.ubuntu.com/ubuntu/dists/noble/universe/binary-amd64/Packages.gz | Hierarchical view of the machine - shared libs | https://www.open-mpi.org/projects/hwloc/
- apk - hwloc - 2.12.2-r0: normalized package name match | Alpine Linux edge package indexes: hwloc from https://dl-cdn.alpinelinux.org/alpine/edge/main/x86_64/APKINDEX.tar.gz | Portable abstraction of hierarchical hardware architectures | https://www.open-mpi.org/


## Combined YAML source

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


## Sources

- 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
