22a6b3ebe7
- Choose providers better (RHBZ#1266918). - Use autopatch.
63 lines
1.9 KiB
Diff
63 lines
1.9 KiB
Diff
From 9515c554ca9e725c4094cbbcd9f37bb316a2529f Mon Sep 17 00:00:00 2001
|
|
From: "Richard W.M. Jones" <rjones@redhat.com>
|
|
Date: Tue, 13 Oct 2015 12:48:03 +0100
|
|
Subject: [PATCH 5/7] rpm: Add some documentation to librpm.mli.
|
|
|
|
---
|
|
src/librpm.mli | 21 +++++++++++++++++++++
|
|
1 file changed, 21 insertions(+)
|
|
|
|
diff --git a/src/librpm.mli b/src/librpm.mli
|
|
index da73911..5229be6 100644
|
|
--- a/src/librpm.mli
|
|
+++ b/src/librpm.mli
|
|
@@ -16,17 +16,28 @@
|
|
* Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
|
|
*)
|
|
|
|
+(** Wrappers around [librpm] functions. *)
|
|
+
|
|
val rpm_is_available : unit -> bool
|
|
+(** Returns [true] iff librpm is supported. If this returns [false],
|
|
+ then all other functions will abort. *)
|
|
|
|
val rpm_version : unit -> string
|
|
+(** The linked version of librpm. *)
|
|
+
|
|
val rpm_vercmp : string -> string -> int
|
|
+(** Compare two RPM version strings using RPM version compare rules. *)
|
|
|
|
type t
|
|
+(** The librpm handle. *)
|
|
|
|
exception Multiple_matches of int
|
|
|
|
val rpm_open : ?debug:int -> t
|
|
+(** Open the librpm (transaction set) handle. *)
|
|
val rpm_close : t -> unit
|
|
+(** Explicitly close the handle. The handle can also be closed by
|
|
+ the garbage collector if it becomes unreachable. *)
|
|
|
|
type rpm_t = {
|
|
name : string;
|
|
@@ -44,6 +55,16 @@ type rpmfile_t = {
|
|
| FileConfig
|
|
|
|
val rpm_installed : t -> string -> rpm_t array
|
|
+(** Return the list of packages matching the name
|
|
+ (similar to [rpm -q name]). *)
|
|
+
|
|
val rpm_pkg_requires : t -> string -> string array
|
|
+(** Return the requires of a package (similar to [rpm -qR]). *)
|
|
+
|
|
val rpm_pkg_whatprovides : t -> string -> string array
|
|
+(** Return what package(s) provide a particular requirement
|
|
+ (similar to [rpm -q --whatprovides]). *)
|
|
+
|
|
val rpm_pkg_filelist : t -> string -> rpmfile_t array
|
|
+(** Return the list of files contained in a package, and attributes of
|
|
+ those files (similar to [rpm -ql]). *)
|
|
--
|
|
2.5.0
|
|
|