package rpmfile
All checked builds passInstall
dune-project
Dependency
Authors
Maintainers
Sources
md5=0eb303a5fa95fd0988b01735281a0ef7
sha512=7997c364529c676c7be3fa121b9d3115302d528919a4528a1f94d76ae6f0a8610fdb72e4e6cb8ce30ae7c05beae5a60d0b9a3141ae7186abae2edb5efc4dd713
Description
A library for processing (reading and writing) RPM files, supporting version 3.0 and partly 4.0.
README

Rpmfile
A pure OCaml library for parsing RPM files (supports V3 and partly V4 package versions).
Quick start
You can install the rpmfile library using the OPAM package manager or any other method you prefer.
$ opam install rpmfile.1.1.0You can also get the latest version of the upstream (developer) branch.
$ opam pin rpmfile.dev https://github.com/dx3mod/rpmfile.gitIf you are using Dune, please add the rpmfile library to your dependencies.
In use
Each RPM package consists of four sections: Lead, Signature, Header, and Payload. The first three are meta information about the package. It contains a description, a dependency list, and so on.
The information in the Signature and Header sections is stored on a key-value basis, where the key is called a tag. The value can be a number, a string or an array. The Payload section usually contains a compressed Cpio archive that already contains the package's files.
For more information, please see the materials.
Below is an example of simply reading an RPM file and obtaining the package name and version.
let () =
let metadata =
In_channel.with_open_bin
"hello.rpm"
Rpmfile.metadata_from_channel
in
let name, release = Rpmfile.View.(name metadata, release metadata) in
Printf.printf "%s.%s\n" name release
(* hello.1.3 *)For more details, see API references and examples/ directory.
References
Package format specification:
Reference implementations in other languages:
- https://github.com/rpm-rs/rpm/ written in Rust
License
The project is licensed under the MIT License, which allows for all permissions. Just use it and enjoy yourself without fear. We are always open to pull requests!
Dev Dependencies (1)
-
odoc
with-doc
Optional Dependencies
None
Used by
None
Conflicts
None
Build status
Results of building rpmfile with each compiler on check.ci.ocaml.org, run of against opam-repository 8a77e58. All results for this package.
Each result links to its build log. To keep crawlers from overloading the site, build logs require a GitHub sign-in (see ocurrent/opam-health-check). On your first log, GitHub asks you to “Authorize opam-health-check”, the OCurrent app that runs these checks; it sees only your public profile, not your repositories. The sign-in lasts 30 days.
| Version | OCaml 4.11 | OCaml 4.14 | OCaml 5.2 | OCaml 5.4 | OCaml 5.5 |
|---|---|---|---|---|---|
| 1.1.0 (this version) | n/a | n/a | n/a | good | good |
| 0.8.0 | n/a | good | good | good | good |
- good Package successfully built
- partial One of the dependencies failed to build
- bad Package failed to build
- n/a Package is not available in this environment
- internal Internal failure