From 23923200c3e34563c8124a1b098bc0866f4e92e5 Mon Sep 17 00:00:00 2001 From: Allan McRae Date: Wed, 16 Oct 2013 12:23:11 +1000 Subject: Expose alpm_pkg_should_ignore This function is useful for frontends to annotate package upgrades that will be ignored. Signed-off-by: Allan McRae --- lib/libalpm/alpm.h | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'lib/libalpm/alpm.h') diff --git a/lib/libalpm/alpm.h b/lib/libalpm/alpm.h index 29b9f378..2c8c1e61 100644 --- a/lib/libalpm/alpm.h +++ b/lib/libalpm/alpm.h @@ -793,6 +793,15 @@ alpm_list_t *alpm_pkg_compute_requiredby(alpm_pkg_t *pkg); */ alpm_list_t *alpm_pkg_compute_optionalfor(alpm_pkg_t *pkg); +/** Test if a package should be ignored. + * Checks if the package is ignored via IgnorePkg, or if the package is + * in a group ignored via IgnoreGroup. + * @param handle the context handle + * @param pkg the package to test + * @return 1 if the package should be ignored, 0 otherwise + */ +int alpm_pkg_should_ignore(alpm_handle_t *handle, alpm_pkg_t *pkg); + /** @name Package Property Accessors * Any pointer returned by these functions points to internal structures * allocated by libalpm. They should not be freed nor modified in any -- cgit v1.2.3-24-g4f1b