17 stable releases (3 major)

3.0.0 Mar 5, 2024
2.1.3 Dec 4, 2023
2.1.2 Oct 11, 2021
2.1.0 Jul 1, 2021
0.1.2 Mar 12, 2017

#957 in Unix APIs

Download history 491/week @ 2024-01-22 450/week @ 2024-01-29 466/week @ 2024-02-05 547/week @ 2024-02-12 500/week @ 2024-02-19 559/week @ 2024-02-26 860/week @ 2024-03-04 1028/week @ 2024-03-11 884/week @ 2024-03-18 687/week @ 2024-03-25 522/week @ 2024-04-01 448/week @ 2024-04-08 450/week @ 2024-04-15 427/week @ 2024-04-22 374/week @ 2024-04-29 306/week @ 2024-05-06

1,616 downloads per month
Used in 24 crates (2 directly)

GPL-3.0 license


alpm.rs - rust bindings for libalpm

Latest version Documentation

alpm.rs provides complete, safe, ergonomic bindings to the libalpm API, the package management library used by pacman and other tools.


  • mtree - enables the alpm_pkg_mtree_* functions
  • generate - generate the raw alpm-sys bindings at build time
  • checkver - check that the version of libalpm installed is compatible with alpm.rs
  • git - target the git master API
  • static - statically link to libalpm

Note: checkver does not work with the git feature. You can instead use the generate feature to ensure alpm.rs builds against a compatible libalpm version.

libalpm compatibility

alpm.rs always targets the latest version of libalpm. It may also support previous versions if the API was not changed.

alpm.rs also supports the pacman git master via the git feature.

Currently alpm.rs supports libalpm v13.x.x.

Note: When using the git feature, alpm.rs is updated against the libalpm git master as commits happen. As the git version is not considered stable software, this is done without bumping the major version.


This crate just provides bindings for libalpm and hence does not document libalpm. You can find documentation for libalpm in the libalpm (3) man page or in alpm.h.

There are also examples on how to use the alpm crate in alpm/examples.


This repo also contains the alpm-sys crate, providing raw bindings for libalpm. Although you probably just want to use the alpm crate instead.

No runtime deps