Struct alpm_sys_ll::libalpm
source · [−]pub struct libalpm {Show 214 fields
pub alpm_list_free: unsafe extern "C" fn(list: *mut alpm_list_t),
pub alpm_list_free_inner: unsafe extern "C" fn(list: *mut alpm_list_t, fn_: alpm_list_fn_free),
pub alpm_list_add: unsafe extern "C" fn(list: *mut alpm_list_t, data: *mut c_void) -> *mut alpm_list_t,
pub alpm_list_append: unsafe extern "C" fn(list: *mut *mut alpm_list_t, data: *mut c_void) -> *mut alpm_list_t,
pub alpm_list_append_strdup: unsafe extern "C" fn(list: *mut *mut alpm_list_t, data: *const c_char) -> *mut alpm_list_t,
pub alpm_list_add_sorted: unsafe extern "C" fn(list: *mut alpm_list_t, data: *mut c_void, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t,
pub alpm_list_join: unsafe extern "C" fn(first: *mut alpm_list_t, second: *mut alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_mmerge: unsafe extern "C" fn(left: *mut alpm_list_t, right: *mut alpm_list_t, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t,
pub alpm_list_msort: unsafe extern "C" fn(list: *mut alpm_list_t, n: usize, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t,
pub alpm_list_remove_item: unsafe extern "C" fn(haystack: *mut alpm_list_t, item: *mut alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_remove: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_void, fn_: alpm_list_fn_cmp, data: *mut *mut c_void) -> *mut alpm_list_t,
pub alpm_list_remove_str: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_char, data: *mut *mut c_char) -> *mut alpm_list_t,
pub alpm_list_remove_dupes: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_strdup: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_copy: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_copy_data: unsafe extern "C" fn(list: *const alpm_list_t, size: usize) -> *mut alpm_list_t,
pub alpm_list_reverse: unsafe extern "C" fn(list: *mut alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_nth: unsafe extern "C" fn(list: *const alpm_list_t, n: usize) -> *mut alpm_list_t,
pub alpm_list_next: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_previous: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_last: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t,
pub alpm_list_count: unsafe extern "C" fn(list: *const alpm_list_t) -> usize,
pub alpm_list_find: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_void, fn_: alpm_list_fn_cmp) -> *mut c_void,
pub alpm_list_find_ptr: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_void) -> *mut c_void,
pub alpm_list_find_str: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_char) -> *mut c_char,
pub alpm_list_diff_sorted: unsafe extern "C" fn(left: *const alpm_list_t, right: *const alpm_list_t, fn_: alpm_list_fn_cmp, onlyleft: *mut *mut alpm_list_t, onlyright: *mut *mut alpm_list_t),
pub alpm_list_diff: unsafe extern "C" fn(lhs: *const alpm_list_t, rhs: *const alpm_list_t, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t,
pub alpm_list_to_array: unsafe extern "C" fn(list: *const alpm_list_t, n: usize, size: usize) -> *mut c_void,
pub alpm_filelist_contains: unsafe extern "C" fn(filelist: *mut alpm_filelist_t, path: *const c_char) -> *mut alpm_file_t,
pub alpm_find_group_pkgs: unsafe extern "C" fn(dbs: *mut alpm_list_t, name: *const c_char) -> *mut alpm_list_t,
pub alpm_errno: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_errno_t,
pub alpm_strerror: unsafe extern "C" fn(err: alpm_errno_t) -> *const c_char,
pub alpm_initialize: unsafe extern "C" fn(root: *const c_char, dbpath: *const c_char, err: *mut alpm_errno_t) -> *mut alpm_handle_t,
pub alpm_release: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_pkg_check_pgp_signature: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, siglist: *mut alpm_siglist_t) -> c_int,
pub alpm_db_check_pgp_signature: unsafe extern "C" fn(db: *mut alpm_db_t, siglist: *mut alpm_siglist_t) -> c_int,
pub alpm_siglist_cleanup: unsafe extern "C" fn(siglist: *mut alpm_siglist_t) -> c_int,
pub alpm_decode_signature: unsafe extern "C" fn(base64_data: *const c_char, data: *mut *mut c_uchar, data_len: *mut usize) -> c_int,
pub alpm_extract_keyid: unsafe extern "C" fn(handle: *mut alpm_handle_t, identifier: *const c_char, sig: *const c_uchar, len: usize, keys: *mut *mut alpm_list_t) -> c_int,
pub alpm_checkdeps: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkglist: *mut alpm_list_t, remove: *mut alpm_list_t, upgrade: *mut alpm_list_t, reversedeps: c_int) -> *mut alpm_list_t,
pub alpm_find_satisfier: unsafe extern "C" fn(pkgs: *mut alpm_list_t, depstring: *const c_char) -> *mut alpm_pkg_t,
pub alpm_find_dbs_satisfier: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbs: *mut alpm_list_t, depstring: *const c_char) -> *mut alpm_pkg_t,
pub alpm_checkconflicts: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkglist: *mut alpm_list_t) -> *mut alpm_list_t,
pub alpm_dep_compute_string: unsafe extern "C" fn(dep: *const alpm_depend_t) -> *mut c_char,
pub alpm_dep_from_string: unsafe extern "C" fn(depstring: *const c_char) -> *mut alpm_depend_t,
pub alpm_dep_free: unsafe extern "C" fn(dep: *mut alpm_depend_t),
pub alpm_fileconflict_free: unsafe extern "C" fn(conflict: *mut alpm_fileconflict_t),
pub alpm_depmissing_free: unsafe extern "C" fn(miss: *mut alpm_depmissing_t),
pub alpm_conflict_free: unsafe extern "C" fn(conflict: *mut alpm_conflict_t),
pub alpm_get_localdb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_db_t,
pub alpm_get_syncdbs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_register_syncdb: unsafe extern "C" fn(handle: *mut alpm_handle_t, treename: *const c_char, level: c_int) -> *mut alpm_db_t,
pub alpm_unregister_all_syncdbs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_db_unregister: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int,
pub alpm_db_get_name: unsafe extern "C" fn(db: *const alpm_db_t) -> *const c_char,
pub alpm_db_get_siglevel: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int,
pub alpm_db_get_valid: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int,
pub alpm_db_get_servers: unsafe extern "C" fn(db: *const alpm_db_t) -> *mut alpm_list_t,
pub alpm_db_set_servers: unsafe extern "C" fn(db: *mut alpm_db_t, servers: *mut alpm_list_t) -> c_int,
pub alpm_db_add_server: unsafe extern "C" fn(db: *mut alpm_db_t, url: *const c_char) -> c_int,
pub alpm_db_remove_server: unsafe extern "C" fn(db: *mut alpm_db_t, url: *const c_char) -> c_int,
pub alpm_db_update: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbs: *mut alpm_list_t, force: c_int) -> c_int,
pub alpm_db_get_pkg: unsafe extern "C" fn(db: *mut alpm_db_t, name: *const c_char) -> *mut alpm_pkg_t,
pub alpm_db_get_pkgcache: unsafe extern "C" fn(db: *mut alpm_db_t) -> *mut alpm_list_t,
pub alpm_db_get_group: unsafe extern "C" fn(db: *mut alpm_db_t, name: *const c_char) -> *mut alpm_group_t,
pub alpm_db_get_groupcache: unsafe extern "C" fn(db: *mut alpm_db_t) -> *mut alpm_list_t,
pub alpm_db_search: unsafe extern "C" fn(db: *mut alpm_db_t, needles: *const alpm_list_t, ret: *mut *mut alpm_list_t) -> c_int,
pub alpm_db_set_usage: unsafe extern "C" fn(db: *mut alpm_db_t, usage: c_int) -> c_int,
pub alpm_db_get_usage: unsafe extern "C" fn(db: *mut alpm_db_t, usage: *mut c_int) -> c_int,
pub alpm_logaction: unsafe extern "C" fn(handle: *mut alpm_handle_t, prefix: *const c_char, fmt: *const c_char, ...) -> c_int,
pub alpm_option_get_logcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_log,
pub alpm_option_get_logcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_logcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_log, ctx: *mut c_void) -> c_int,
pub alpm_option_get_dlcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_download,
pub alpm_option_get_dlcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_dlcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_download, ctx: *mut c_void) -> c_int,
pub alpm_option_get_fetchcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_fetch,
pub alpm_option_get_fetchcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_fetchcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_fetch, ctx: *mut c_void) -> c_int,
pub alpm_option_get_eventcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_event,
pub alpm_option_get_eventcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_eventcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_event, ctx: *mut c_void) -> c_int,
pub alpm_option_get_questioncb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_question,
pub alpm_option_get_questioncb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_questioncb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_question, ctx: *mut c_void) -> c_int,
pub alpm_option_get_progresscb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_progress,
pub alpm_option_get_progresscb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void,
pub alpm_option_set_progresscb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_progress, ctx: *mut c_void) -> c_int,
pub alpm_option_get_root: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_get_dbpath: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_get_lockfile: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_get_cachedirs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_set_cachedirs: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedirs: *mut alpm_list_t) -> c_int,
pub alpm_option_add_cachedir: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedir: *const c_char) -> c_int,
pub alpm_option_remove_cachedir: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedir: *const c_char) -> c_int,
pub alpm_option_get_hookdirs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_set_hookdirs: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdirs: *mut alpm_list_t) -> c_int,
pub alpm_option_add_hookdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdir: *const c_char) -> c_int,
pub alpm_option_remove_hookdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdir: *const c_char) -> c_int,
pub alpm_option_get_overwrite_files: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_set_overwrite_files: unsafe extern "C" fn(handle: *mut alpm_handle_t, globs: *mut alpm_list_t) -> c_int,
pub alpm_option_add_overwrite_file: unsafe extern "C" fn(handle: *mut alpm_handle_t, glob: *const c_char) -> c_int,
pub alpm_option_remove_overwrite_file: unsafe extern "C" fn(handle: *mut alpm_handle_t, glob: *const c_char) -> c_int,
pub alpm_option_get_logfile: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_set_logfile: unsafe extern "C" fn(handle: *mut alpm_handle_t, logfile: *const c_char) -> c_int,
pub alpm_option_get_gpgdir: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_set_gpgdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, gpgdir: *const c_char) -> c_int,
pub alpm_option_get_usesyslog: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_usesyslog: unsafe extern "C" fn(handle: *mut alpm_handle_t, usesyslog: c_int) -> c_int,
pub alpm_option_get_noupgrades: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_set_noupgrades: unsafe extern "C" fn(handle: *mut alpm_handle_t, noupgrade: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_match_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_get_noextracts: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_set_noextracts: unsafe extern "C" fn(handle: *mut alpm_handle_t, noextract: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_match_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int,
pub alpm_option_get_ignorepkgs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_ignorepkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *const c_char) -> c_int,
pub alpm_option_set_ignorepkgs: unsafe extern "C" fn(handle: *mut alpm_handle_t, ignorepkgs: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_ignorepkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *const c_char) -> c_int,
pub alpm_option_get_ignoregroups: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_ignoregroup: unsafe extern "C" fn(handle: *mut alpm_handle_t, grp: *const c_char) -> c_int,
pub alpm_option_set_ignoregroups: unsafe extern "C" fn(handle: *mut alpm_handle_t, ignoregrps: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_ignoregroup: unsafe extern "C" fn(handle: *mut alpm_handle_t, grp: *const c_char) -> c_int,
pub alpm_option_get_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, dep: *const alpm_depend_t) -> c_int,
pub alpm_option_set_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, deps: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, dep: *const alpm_depend_t) -> c_int,
pub alpm_option_get_architectures: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_option_add_architecture: unsafe extern "C" fn(handle: *mut alpm_handle_t, arch: *const c_char) -> c_int,
pub alpm_option_set_architectures: unsafe extern "C" fn(handle: *mut alpm_handle_t, arches: *mut alpm_list_t) -> c_int,
pub alpm_option_remove_architecture: unsafe extern "C" fn(handle: *mut alpm_handle_t, arch: *const c_char) -> c_int,
pub alpm_option_get_checkspace: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_checkspace: unsafe extern "C" fn(handle: *mut alpm_handle_t, checkspace: c_int) -> c_int,
pub alpm_option_get_dbext: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char,
pub alpm_option_set_dbext: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbext: *const c_char) -> c_int,
pub alpm_option_get_default_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_default_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int,
pub alpm_option_get_local_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_local_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int,
pub alpm_option_get_remote_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_remote_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int,
pub alpm_option_set_disable_dl_timeout: unsafe extern "C" fn(handle: *mut alpm_handle_t, disable_dl_timeout: c_ushort) -> c_int,
pub alpm_option_get_parallel_downloads: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_option_set_parallel_downloads: unsafe extern "C" fn(handle: *mut alpm_handle_t, num_streams: c_uint) -> c_int,
pub alpm_pkg_load: unsafe extern "C" fn(handle: *mut alpm_handle_t, filename: *const c_char, full: c_int, level: c_int, pkg: *mut *mut alpm_pkg_t) -> c_int,
pub alpm_fetch_pkgurl: unsafe extern "C" fn(handle: *mut alpm_handle_t, urls: *const alpm_list_t, fetched: *mut *mut alpm_list_t) -> c_int,
pub alpm_pkg_find: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_char) -> *mut alpm_pkg_t,
pub alpm_pkg_free: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_pkg_checkmd5sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_pkg_vercmp: unsafe extern "C" fn(a: *const c_char, b: *const c_char) -> c_int,
pub alpm_pkg_compute_requiredby: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_compute_optionalfor: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_should_ignore: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_pkg_get_filename: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_base: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_name: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_version: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_origin: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_pkgfrom_t,
pub alpm_pkg_get_desc: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_url: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_builddate: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_time_t,
pub alpm_pkg_get_installdate: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_time_t,
pub alpm_pkg_get_packager: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_md5sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_sha256sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_arch: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_size: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> off_t,
pub alpm_pkg_get_isize: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> off_t,
pub alpm_pkg_get_reason: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_pkgreason_t,
pub alpm_pkg_get_licenses: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_groups: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_depends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_optdepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_checkdepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_makedepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_conflicts: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_provides: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_replaces: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_files: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_filelist_t,
pub alpm_pkg_get_backup: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t,
pub alpm_pkg_get_db: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_db_t,
pub alpm_pkg_get_base64_sig: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char,
pub alpm_pkg_get_sig: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, sig: *mut *mut c_uchar, sig_len: *mut usize) -> c_int,
pub alpm_pkg_get_validation: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_pkg_has_scriptlet: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_pkg_download_size: unsafe extern "C" fn(newpkg: *mut alpm_pkg_t) -> off_t,
pub alpm_pkg_set_reason: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, reason: alpm_pkgreason_t) -> c_int,
pub alpm_pkg_changelog_open: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut c_void,
pub alpm_pkg_changelog_read: unsafe extern "C" fn(ptr: *mut c_void, size: usize, pkg: *const alpm_pkg_t, fp: *mut c_void) -> usize,
pub alpm_pkg_changelog_close: unsafe extern "C" fn(pkg: *const alpm_pkg_t, fp: *mut c_void) -> c_int,
pub alpm_pkg_mtree_open: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut archive,
pub alpm_pkg_mtree_next: unsafe extern "C" fn(pkg: *const alpm_pkg_t, archive: *mut archive, entry: *mut *mut archive_entry) -> c_int,
pub alpm_pkg_mtree_close: unsafe extern "C" fn(pkg: *const alpm_pkg_t, archive: *mut archive) -> c_int,
pub alpm_trans_get_flags: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_trans_get_add: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_trans_get_remove: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t,
pub alpm_trans_init: unsafe extern "C" fn(handle: *mut alpm_handle_t, flags: c_int) -> c_int,
pub alpm_trans_prepare: unsafe extern "C" fn(handle: *mut alpm_handle_t, data: *mut *mut alpm_list_t) -> c_int,
pub alpm_trans_commit: unsafe extern "C" fn(handle: *mut alpm_handle_t, data: *mut *mut alpm_list_t) -> c_int,
pub alpm_trans_interrupt: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_trans_release: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_sync_sysupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, enable_downgrade: c_int) -> c_int,
pub alpm_add_pkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_remove_pkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int,
pub alpm_sync_get_new_version: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, dbs_sync: *mut alpm_list_t) -> *mut alpm_pkg_t,
pub alpm_compute_md5sum: unsafe extern "C" fn(filename: *const c_char) -> *mut c_char,
pub alpm_compute_sha256sum: unsafe extern "C" fn(filename: *const c_char) -> *mut c_char,
pub alpm_unlock: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int,
pub alpm_version: unsafe extern "C" fn() -> *const c_char,
pub alpm_capabilities: unsafe extern "C" fn() -> c_int,
/* private fields */
}
Fields
alpm_list_free: unsafe extern "C" fn(list: *mut alpm_list_t)
alpm_list_free_inner: unsafe extern "C" fn(list: *mut alpm_list_t, fn_: alpm_list_fn_free)
alpm_list_add: unsafe extern "C" fn(list: *mut alpm_list_t, data: *mut c_void) -> *mut alpm_list_t
alpm_list_append: unsafe extern "C" fn(list: *mut *mut alpm_list_t, data: *mut c_void) -> *mut alpm_list_t
alpm_list_append_strdup: unsafe extern "C" fn(list: *mut *mut alpm_list_t, data: *const c_char) -> *mut alpm_list_t
alpm_list_add_sorted: unsafe extern "C" fn(list: *mut alpm_list_t, data: *mut c_void, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t
alpm_list_join: unsafe extern "C" fn(first: *mut alpm_list_t, second: *mut alpm_list_t) -> *mut alpm_list_t
alpm_list_mmerge: unsafe extern "C" fn(left: *mut alpm_list_t, right: *mut alpm_list_t, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t
alpm_list_msort: unsafe extern "C" fn(list: *mut alpm_list_t, n: usize, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t
alpm_list_remove_item: unsafe extern "C" fn(haystack: *mut alpm_list_t, item: *mut alpm_list_t) -> *mut alpm_list_t
alpm_list_remove: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_void, fn_: alpm_list_fn_cmp, data: *mut *mut c_void) -> *mut alpm_list_t
alpm_list_remove_str: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_char, data: *mut *mut c_char) -> *mut alpm_list_t
alpm_list_remove_dupes: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_strdup: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_copy: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_copy_data: unsafe extern "C" fn(list: *const alpm_list_t, size: usize) -> *mut alpm_list_t
alpm_list_reverse: unsafe extern "C" fn(list: *mut alpm_list_t) -> *mut alpm_list_t
alpm_list_nth: unsafe extern "C" fn(list: *const alpm_list_t, n: usize) -> *mut alpm_list_t
alpm_list_next: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_previous: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_last: unsafe extern "C" fn(list: *const alpm_list_t) -> *mut alpm_list_t
alpm_list_count: unsafe extern "C" fn(list: *const alpm_list_t) -> usize
alpm_list_find: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_void, fn_: alpm_list_fn_cmp) -> *mut c_void
alpm_list_find_ptr: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_void) -> *mut c_void
alpm_list_find_str: unsafe extern "C" fn(haystack: *const alpm_list_t, needle: *const c_char) -> *mut c_char
alpm_list_diff_sorted: unsafe extern "C" fn(left: *const alpm_list_t, right: *const alpm_list_t, fn_: alpm_list_fn_cmp, onlyleft: *mut *mut alpm_list_t, onlyright: *mut *mut alpm_list_t)
alpm_list_diff: unsafe extern "C" fn(lhs: *const alpm_list_t, rhs: *const alpm_list_t, fn_: alpm_list_fn_cmp) -> *mut alpm_list_t
alpm_list_to_array: unsafe extern "C" fn(list: *const alpm_list_t, n: usize, size: usize) -> *mut c_void
alpm_filelist_contains: unsafe extern "C" fn(filelist: *mut alpm_filelist_t, path: *const c_char) -> *mut alpm_file_t
alpm_find_group_pkgs: unsafe extern "C" fn(dbs: *mut alpm_list_t, name: *const c_char) -> *mut alpm_list_t
alpm_errno: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_errno_t
alpm_strerror: unsafe extern "C" fn(err: alpm_errno_t) -> *const c_char
alpm_initialize: unsafe extern "C" fn(root: *const c_char, dbpath: *const c_char, err: *mut alpm_errno_t) -> *mut alpm_handle_t
alpm_release: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_pkg_check_pgp_signature: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, siglist: *mut alpm_siglist_t) -> c_int
alpm_db_check_pgp_signature: unsafe extern "C" fn(db: *mut alpm_db_t, siglist: *mut alpm_siglist_t) -> c_int
alpm_siglist_cleanup: unsafe extern "C" fn(siglist: *mut alpm_siglist_t) -> c_int
alpm_decode_signature: unsafe extern "C" fn(base64_data: *const c_char, data: *mut *mut c_uchar, data_len: *mut usize) -> c_int
alpm_extract_keyid: unsafe extern "C" fn(handle: *mut alpm_handle_t, identifier: *const c_char, sig: *const c_uchar, len: usize, keys: *mut *mut alpm_list_t) -> c_int
alpm_checkdeps: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkglist: *mut alpm_list_t, remove: *mut alpm_list_t, upgrade: *mut alpm_list_t, reversedeps: c_int) -> *mut alpm_list_t
alpm_find_satisfier: unsafe extern "C" fn(pkgs: *mut alpm_list_t, depstring: *const c_char) -> *mut alpm_pkg_t
alpm_find_dbs_satisfier: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbs: *mut alpm_list_t, depstring: *const c_char) -> *mut alpm_pkg_t
alpm_checkconflicts: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkglist: *mut alpm_list_t) -> *mut alpm_list_t
alpm_dep_compute_string: unsafe extern "C" fn(dep: *const alpm_depend_t) -> *mut c_char
alpm_dep_from_string: unsafe extern "C" fn(depstring: *const c_char) -> *mut alpm_depend_t
alpm_dep_free: unsafe extern "C" fn(dep: *mut alpm_depend_t)
alpm_fileconflict_free: unsafe extern "C" fn(conflict: *mut alpm_fileconflict_t)
alpm_depmissing_free: unsafe extern "C" fn(miss: *mut alpm_depmissing_t)
alpm_conflict_free: unsafe extern "C" fn(conflict: *mut alpm_conflict_t)
alpm_get_localdb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_db_t
alpm_get_syncdbs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_register_syncdb: unsafe extern "C" fn(handle: *mut alpm_handle_t, treename: *const c_char, level: c_int) -> *mut alpm_db_t
alpm_unregister_all_syncdbs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_db_unregister: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int
alpm_db_get_name: unsafe extern "C" fn(db: *const alpm_db_t) -> *const c_char
alpm_db_get_siglevel: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int
alpm_db_get_valid: unsafe extern "C" fn(db: *mut alpm_db_t) -> c_int
alpm_db_get_servers: unsafe extern "C" fn(db: *const alpm_db_t) -> *mut alpm_list_t
alpm_db_set_servers: unsafe extern "C" fn(db: *mut alpm_db_t, servers: *mut alpm_list_t) -> c_int
alpm_db_add_server: unsafe extern "C" fn(db: *mut alpm_db_t, url: *const c_char) -> c_int
alpm_db_remove_server: unsafe extern "C" fn(db: *mut alpm_db_t, url: *const c_char) -> c_int
alpm_db_update: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbs: *mut alpm_list_t, force: c_int) -> c_int
alpm_db_get_pkg: unsafe extern "C" fn(db: *mut alpm_db_t, name: *const c_char) -> *mut alpm_pkg_t
alpm_db_get_pkgcache: unsafe extern "C" fn(db: *mut alpm_db_t) -> *mut alpm_list_t
alpm_db_get_group: unsafe extern "C" fn(db: *mut alpm_db_t, name: *const c_char) -> *mut alpm_group_t
alpm_db_get_groupcache: unsafe extern "C" fn(db: *mut alpm_db_t) -> *mut alpm_list_t
alpm_db_search: unsafe extern "C" fn(db: *mut alpm_db_t, needles: *const alpm_list_t, ret: *mut *mut alpm_list_t) -> c_int
alpm_db_set_usage: unsafe extern "C" fn(db: *mut alpm_db_t, usage: c_int) -> c_int
alpm_db_get_usage: unsafe extern "C" fn(db: *mut alpm_db_t, usage: *mut c_int) -> c_int
alpm_logaction: unsafe extern "C" fn(handle: *mut alpm_handle_t, prefix: *const c_char, fmt: *const c_char, ...) -> c_int
alpm_option_get_logcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_log
alpm_option_get_logcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_logcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_log, ctx: *mut c_void) -> c_int
alpm_option_get_dlcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_download
alpm_option_get_dlcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_dlcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_download, ctx: *mut c_void) -> c_int
alpm_option_get_fetchcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_fetch
alpm_option_get_fetchcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_fetchcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_fetch, ctx: *mut c_void) -> c_int
alpm_option_get_eventcb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_event
alpm_option_get_eventcb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_eventcb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_event, ctx: *mut c_void) -> c_int
alpm_option_get_questioncb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_question
alpm_option_get_questioncb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_questioncb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_question, ctx: *mut c_void) -> c_int
alpm_option_get_progresscb: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> alpm_cb_progress
alpm_option_get_progresscb_ctx: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut c_void
alpm_option_set_progresscb: unsafe extern "C" fn(handle: *mut alpm_handle_t, cb: alpm_cb_progress, ctx: *mut c_void) -> c_int
alpm_option_get_root: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_get_dbpath: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_get_lockfile: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_get_cachedirs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_set_cachedirs: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedirs: *mut alpm_list_t) -> c_int
alpm_option_add_cachedir: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedir: *const c_char) -> c_int
alpm_option_remove_cachedir: unsafe extern "C" fn(handle: *mut alpm_handle_t, cachedir: *const c_char) -> c_int
alpm_option_get_hookdirs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_set_hookdirs: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdirs: *mut alpm_list_t) -> c_int
alpm_option_add_hookdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdir: *const c_char) -> c_int
alpm_option_remove_hookdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, hookdir: *const c_char) -> c_int
alpm_option_get_overwrite_files: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_set_overwrite_files: unsafe extern "C" fn(handle: *mut alpm_handle_t, globs: *mut alpm_list_t) -> c_int
alpm_option_add_overwrite_file: unsafe extern "C" fn(handle: *mut alpm_handle_t, glob: *const c_char) -> c_int
alpm_option_remove_overwrite_file: unsafe extern "C" fn(handle: *mut alpm_handle_t, glob: *const c_char) -> c_int
alpm_option_get_logfile: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_set_logfile: unsafe extern "C" fn(handle: *mut alpm_handle_t, logfile: *const c_char) -> c_int
alpm_option_get_gpgdir: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_set_gpgdir: unsafe extern "C" fn(handle: *mut alpm_handle_t, gpgdir: *const c_char) -> c_int
alpm_option_get_usesyslog: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_usesyslog: unsafe extern "C" fn(handle: *mut alpm_handle_t, usesyslog: c_int) -> c_int
alpm_option_get_noupgrades: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_set_noupgrades: unsafe extern "C" fn(handle: *mut alpm_handle_t, noupgrade: *mut alpm_list_t) -> c_int
alpm_option_remove_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_match_noupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_get_noextracts: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_set_noextracts: unsafe extern "C" fn(handle: *mut alpm_handle_t, noextract: *mut alpm_list_t) -> c_int
alpm_option_remove_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_match_noextract: unsafe extern "C" fn(handle: *mut alpm_handle_t, path: *const c_char) -> c_int
alpm_option_get_ignorepkgs: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_ignorepkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *const c_char) -> c_int
alpm_option_set_ignorepkgs: unsafe extern "C" fn(handle: *mut alpm_handle_t, ignorepkgs: *mut alpm_list_t) -> c_int
alpm_option_remove_ignorepkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *const c_char) -> c_int
alpm_option_get_ignoregroups: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_ignoregroup: unsafe extern "C" fn(handle: *mut alpm_handle_t, grp: *const c_char) -> c_int
alpm_option_set_ignoregroups: unsafe extern "C" fn(handle: *mut alpm_handle_t, ignoregrps: *mut alpm_list_t) -> c_int
alpm_option_remove_ignoregroup: unsafe extern "C" fn(handle: *mut alpm_handle_t, grp: *const c_char) -> c_int
alpm_option_get_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, dep: *const alpm_depend_t) -> c_int
alpm_option_set_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, deps: *mut alpm_list_t) -> c_int
alpm_option_remove_assumeinstalled: unsafe extern "C" fn(handle: *mut alpm_handle_t, dep: *const alpm_depend_t) -> c_int
alpm_option_get_architectures: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_option_add_architecture: unsafe extern "C" fn(handle: *mut alpm_handle_t, arch: *const c_char) -> c_int
alpm_option_set_architectures: unsafe extern "C" fn(handle: *mut alpm_handle_t, arches: *mut alpm_list_t) -> c_int
alpm_option_remove_architecture: unsafe extern "C" fn(handle: *mut alpm_handle_t, arch: *const c_char) -> c_int
alpm_option_get_checkspace: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_checkspace: unsafe extern "C" fn(handle: *mut alpm_handle_t, checkspace: c_int) -> c_int
alpm_option_get_dbext: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *const c_char
alpm_option_set_dbext: unsafe extern "C" fn(handle: *mut alpm_handle_t, dbext: *const c_char) -> c_int
alpm_option_get_default_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_default_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int
alpm_option_get_local_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_local_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int
alpm_option_get_remote_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_remote_file_siglevel: unsafe extern "C" fn(handle: *mut alpm_handle_t, level: c_int) -> c_int
alpm_option_set_disable_dl_timeout: unsafe extern "C" fn(handle: *mut alpm_handle_t, disable_dl_timeout: c_ushort) -> c_int
alpm_option_get_parallel_downloads: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_option_set_parallel_downloads: unsafe extern "C" fn(handle: *mut alpm_handle_t, num_streams: c_uint) -> c_int
alpm_pkg_load: unsafe extern "C" fn(handle: *mut alpm_handle_t, filename: *const c_char, full: c_int, level: c_int, pkg: *mut *mut alpm_pkg_t) -> c_int
alpm_fetch_pkgurl: unsafe extern "C" fn(handle: *mut alpm_handle_t, urls: *const alpm_list_t, fetched: *mut *mut alpm_list_t) -> c_int
alpm_pkg_find: unsafe extern "C" fn(haystack: *mut alpm_list_t, needle: *const c_char) -> *mut alpm_pkg_t
alpm_pkg_free: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int
alpm_pkg_checkmd5sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int
alpm_pkg_vercmp: unsafe extern "C" fn(a: *const c_char, b: *const c_char) -> c_int
alpm_pkg_compute_requiredby: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_compute_optionalfor: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_should_ignore: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int
alpm_pkg_get_filename: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_base: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_name: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_version: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_origin: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_pkgfrom_t
alpm_pkg_get_desc: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_url: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_builddate: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_time_t
alpm_pkg_get_installdate: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_time_t
alpm_pkg_get_packager: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_md5sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_sha256sum: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_arch: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_size: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> off_t
alpm_pkg_get_isize: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> off_t
alpm_pkg_get_reason: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> alpm_pkgreason_t
alpm_pkg_get_licenses: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_groups: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_depends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_optdepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_checkdepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_makedepends: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_conflicts: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_provides: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_replaces: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_files: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_filelist_t
alpm_pkg_get_backup: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_list_t
alpm_pkg_get_db: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut alpm_db_t
alpm_pkg_get_base64_sig: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *const c_char
alpm_pkg_get_sig: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, sig: *mut *mut c_uchar, sig_len: *mut usize) -> c_int
alpm_pkg_get_validation: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int
alpm_pkg_has_scriptlet: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> c_int
alpm_pkg_download_size: unsafe extern "C" fn(newpkg: *mut alpm_pkg_t) -> off_t
alpm_pkg_set_reason: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, reason: alpm_pkgreason_t) -> c_int
alpm_pkg_changelog_open: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut c_void
alpm_pkg_changelog_read: unsafe extern "C" fn(ptr: *mut c_void, size: usize, pkg: *const alpm_pkg_t, fp: *mut c_void) -> usize
alpm_pkg_changelog_close: unsafe extern "C" fn(pkg: *const alpm_pkg_t, fp: *mut c_void) -> c_int
alpm_pkg_mtree_open: unsafe extern "C" fn(pkg: *mut alpm_pkg_t) -> *mut archive
alpm_pkg_mtree_next: unsafe extern "C" fn(pkg: *const alpm_pkg_t, archive: *mut archive, entry: *mut *mut archive_entry) -> c_int
alpm_pkg_mtree_close: unsafe extern "C" fn(pkg: *const alpm_pkg_t, archive: *mut archive) -> c_int
alpm_trans_get_flags: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_trans_get_add: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_trans_get_remove: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> *mut alpm_list_t
alpm_trans_init: unsafe extern "C" fn(handle: *mut alpm_handle_t, flags: c_int) -> c_int
alpm_trans_prepare: unsafe extern "C" fn(handle: *mut alpm_handle_t, data: *mut *mut alpm_list_t) -> c_int
alpm_trans_commit: unsafe extern "C" fn(handle: *mut alpm_handle_t, data: *mut *mut alpm_list_t) -> c_int
alpm_trans_interrupt: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_trans_release: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_sync_sysupgrade: unsafe extern "C" fn(handle: *mut alpm_handle_t, enable_downgrade: c_int) -> c_int
alpm_add_pkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int
alpm_remove_pkg: unsafe extern "C" fn(handle: *mut alpm_handle_t, pkg: *mut alpm_pkg_t) -> c_int
alpm_sync_get_new_version: unsafe extern "C" fn(pkg: *mut alpm_pkg_t, dbs_sync: *mut alpm_list_t) -> *mut alpm_pkg_t
alpm_compute_md5sum: unsafe extern "C" fn(filename: *const c_char) -> *mut c_char
alpm_compute_sha256sum: unsafe extern "C" fn(filename: *const c_char) -> *mut c_char
alpm_unlock: unsafe extern "C" fn(handle: *mut alpm_handle_t) -> c_int
alpm_version: unsafe extern "C" fn() -> *const c_char
alpm_capabilities: unsafe extern "C" fn() -> c_int
Implementations
sourceimpl libalpm
impl libalpm
pub unsafe fn new<P>(path: P) -> Result<Self, Error> where
P: AsRef<OsStr>,
pub unsafe fn from_library<L>(library: L) -> Result<Self, Error> where
L: Into<Library>,
pub unsafe fn alpm_list_free(&self, list: *mut alpm_list_t)
pub unsafe fn alpm_list_free_inner(
&self,
list: *mut alpm_list_t,
fn_: alpm_list_fn_free
)
pub unsafe fn alpm_list_add(
&self,
list: *mut alpm_list_t,
data: *mut c_void
) -> *mut alpm_list_t
pub unsafe fn alpm_list_append(
&self,
list: *mut *mut alpm_list_t,
data: *mut c_void
) -> *mut alpm_list_t
pub unsafe fn alpm_list_append_strdup(
&self,
list: *mut *mut alpm_list_t,
data: *const c_char
) -> *mut alpm_list_t
pub unsafe fn alpm_list_add_sorted(
&self,
list: *mut alpm_list_t,
data: *mut c_void,
fn_: alpm_list_fn_cmp
) -> *mut alpm_list_t
pub unsafe fn alpm_list_join(
&self,
first: *mut alpm_list_t,
second: *mut alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_mmerge(
&self,
left: *mut alpm_list_t,
right: *mut alpm_list_t,
fn_: alpm_list_fn_cmp
) -> *mut alpm_list_t
pub unsafe fn alpm_list_msort(
&self,
list: *mut alpm_list_t,
n: usize,
fn_: alpm_list_fn_cmp
) -> *mut alpm_list_t
pub unsafe fn alpm_list_remove_item(
&self,
haystack: *mut alpm_list_t,
item: *mut alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_remove(
&self,
haystack: *mut alpm_list_t,
needle: *const c_void,
fn_: alpm_list_fn_cmp,
data: *mut *mut c_void
) -> *mut alpm_list_t
pub unsafe fn alpm_list_remove_str(
&self,
haystack: *mut alpm_list_t,
needle: *const c_char,
data: *mut *mut c_char
) -> *mut alpm_list_t
pub unsafe fn alpm_list_remove_dupes(
&self,
list: *const alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_strdup(
&self,
list: *const alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_copy(&self, list: *const alpm_list_t) -> *mut alpm_list_t
pub unsafe fn alpm_list_copy_data(
&self,
list: *const alpm_list_t,
size: usize
) -> *mut alpm_list_t
pub unsafe fn alpm_list_reverse(
&self,
list: *mut alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_nth(
&self,
list: *const alpm_list_t,
n: usize
) -> *mut alpm_list_t
pub unsafe fn alpm_list_next(&self, list: *const alpm_list_t) -> *mut alpm_list_t
pub unsafe fn alpm_list_previous(
&self,
list: *const alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_list_last(&self, list: *const alpm_list_t) -> *mut alpm_list_t
pub unsafe fn alpm_list_count(&self, list: *const alpm_list_t) -> usize
pub unsafe fn alpm_list_find(
&self,
haystack: *const alpm_list_t,
needle: *const c_void,
fn_: alpm_list_fn_cmp
) -> *mut c_void
pub unsafe fn alpm_list_find_ptr(
&self,
haystack: *const alpm_list_t,
needle: *const c_void
) -> *mut c_void
pub unsafe fn alpm_list_find_str(
&self,
haystack: *const alpm_list_t,
needle: *const c_char
) -> *mut c_char
pub unsafe fn alpm_list_diff_sorted(
&self,
left: *const alpm_list_t,
right: *const alpm_list_t,
fn_: alpm_list_fn_cmp,
onlyleft: *mut *mut alpm_list_t,
onlyright: *mut *mut alpm_list_t
)
pub unsafe fn alpm_list_diff(
&self,
lhs: *const alpm_list_t,
rhs: *const alpm_list_t,
fn_: alpm_list_fn_cmp
) -> *mut alpm_list_t
pub unsafe fn alpm_list_to_array(
&self,
list: *const alpm_list_t,
n: usize,
size: usize
) -> *mut c_void
sourcepub unsafe fn alpm_filelist_contains(
&self,
filelist: *mut alpm_filelist_t,
path: *const c_char
) -> *mut alpm_file_t
pub unsafe fn alpm_filelist_contains(
&self,
filelist: *mut alpm_filelist_t,
path: *const c_char
) -> *mut alpm_file_t
Determines whether a package filelist contains a given path. The provided path should be relative to the install root with no leading slashes, e.g. “etc/localtime”. When searching for directories, the path must have a trailing slash. @param filelist a pointer to a package filelist @param path the path to search for in the package @return a pointer to the matching file or NULL if not found
sourcepub unsafe fn alpm_find_group_pkgs(
&self,
dbs: *mut alpm_list_t,
name: *const c_char
) -> *mut alpm_list_t
pub unsafe fn alpm_find_group_pkgs(
&self,
dbs: *mut alpm_list_t,
name: *const c_char
) -> *mut alpm_list_t
Find group members across a list of databases. If a member exists in several databases, only the first database is used. IgnorePkg is also handled. @param dbs the list of alpm_db_t * @param name the name of the group @return the list of alpm_pkg_t * (caller is responsible for alpm_list_free)
sourcepub unsafe fn alpm_errno(&self, handle: *mut alpm_handle_t) -> alpm_errno_t
pub unsafe fn alpm_errno(&self, handle: *mut alpm_handle_t) -> alpm_errno_t
Returns the current error code from the handle. @param handle the context handle @return the current error code of the handle
sourcepub unsafe fn alpm_strerror(&self, err: alpm_errno_t) -> *const c_char
pub unsafe fn alpm_strerror(&self, err: alpm_errno_t) -> *const c_char
Returns the string corresponding to an error number. @param err the error code to get the string for @return the string relating to the given error code
sourcepub unsafe fn alpm_initialize(
&self,
root: *const c_char,
dbpath: *const c_char,
err: *mut alpm_errno_t
) -> *mut alpm_handle_t
pub unsafe fn alpm_initialize(
&self,
root: *const c_char,
dbpath: *const c_char,
err: *mut alpm_errno_t
) -> *mut alpm_handle_t
Initializes the library. Creates handle, connects to database and creates lockfile. This must be called before any other functions are called. @param root the root path for all filesystem operations @param dbpath the absolute path to the libalpm database @param err an optional variable to hold any error return codes @return a context handle on success, NULL on error, err will be set if provided
sourcepub unsafe fn alpm_release(&self, handle: *mut alpm_handle_t) -> c_int
pub unsafe fn alpm_release(&self, handle: *mut alpm_handle_t) -> c_int
Release the library. Disconnects from the database, removes handle and lockfile This should be the last alpm call you make. After this returns, handle should be considered invalid and cannot be reused in any way. @param handle the context handle @return 0 on success, -1 on error
sourcepub unsafe fn alpm_pkg_check_pgp_signature(
&self,
pkg: *mut alpm_pkg_t,
siglist: *mut alpm_siglist_t
) -> c_int
pub unsafe fn alpm_pkg_check_pgp_signature(
&self,
pkg: *mut alpm_pkg_t,
siglist: *mut alpm_siglist_t
) -> c_int
Check the PGP signature for the given package file. @param pkg the package to check @param siglist a pointer to storage for signature results @return a int value : 0 (valid), 1 (invalid), -1 (an error occurred)
sourcepub unsafe fn alpm_db_check_pgp_signature(
&self,
db: *mut alpm_db_t,
siglist: *mut alpm_siglist_t
) -> c_int
pub unsafe fn alpm_db_check_pgp_signature(
&self,
db: *mut alpm_db_t,
siglist: *mut alpm_siglist_t
) -> c_int
Check the PGP signature for the given database. @param db the database to check @param siglist a pointer to storage for signature results @return a int value : 0 (valid), 1 (invalid), -1 (an error occurred)
sourcepub unsafe fn alpm_siglist_cleanup(&self, siglist: *mut alpm_siglist_t) -> c_int
pub unsafe fn alpm_siglist_cleanup(&self, siglist: *mut alpm_siglist_t) -> c_int
Clean up and free a signature result list. Note that this does not free the siglist object itself in case that was allocated on the stack; this is the responsibility of the caller. @param siglist a pointer to storage for signature results @return 0 on success, -1 on error
sourcepub unsafe fn alpm_decode_signature(
&self,
base64_data: *const c_char,
data: *mut *mut c_uchar,
data_len: *mut usize
) -> c_int
pub unsafe fn alpm_decode_signature(
&self,
base64_data: *const c_char,
data: *mut *mut c_uchar,
data_len: *mut usize
) -> c_int
Decode a loaded signature in base64 form. @param base64_data the signature to attempt to decode @param data the decoded data; must be freed by the caller @param data_len the length of the returned data @return 0 on success, -1 on failure to properly decode
sourcepub unsafe fn alpm_extract_keyid(
&self,
handle: *mut alpm_handle_t,
identifier: *const c_char,
sig: *const c_uchar,
len: usize,
keys: *mut *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_extract_keyid(
&self,
handle: *mut alpm_handle_t,
identifier: *const c_char,
sig: *const c_uchar,
len: usize,
keys: *mut *mut alpm_list_t
) -> c_int
Extract the Issuer Key ID from a signature @param handle the context handle @param identifier the identifier of the key. This may be the name of the package or the path to the package. @param sig PGP signature @param len length of signature @param keys a pointer to storage for key IDs @return 0 on success, -1 on error
sourcepub unsafe fn alpm_checkdeps(
&self,
handle: *mut alpm_handle_t,
pkglist: *mut alpm_list_t,
remove: *mut alpm_list_t,
upgrade: *mut alpm_list_t,
reversedeps: c_int
) -> *mut alpm_list_t
pub unsafe fn alpm_checkdeps(
&self,
handle: *mut alpm_handle_t,
pkglist: *mut alpm_list_t,
remove: *mut alpm_list_t,
upgrade: *mut alpm_list_t,
reversedeps: c_int
) -> *mut alpm_list_t
Checks dependencies and returns missing ones in a list. Dependencies can include versions with depmod operators. @param handle the context handle @param pkglist the list of local packages @param remove an alpm_list_t* of packages to be removed @param upgrade an alpm_list_t* of packages to be upgraded (remove-then-upgrade) @param reversedeps handles the backward dependencies @return an alpm_list_t* of alpm_depmissing_t pointers.
sourcepub unsafe fn alpm_find_satisfier(
&self,
pkgs: *mut alpm_list_t,
depstring: *const c_char
) -> *mut alpm_pkg_t
pub unsafe fn alpm_find_satisfier(
&self,
pkgs: *mut alpm_list_t,
depstring: *const c_char
) -> *mut alpm_pkg_t
Find a package satisfying a specified dependency. The dependency can include versions with depmod operators. @param pkgs an alpm_list_t* of alpm_pkg_t where the satisfyer will be searched @param depstring package or provision name, versioned or not @return a alpm_pkg_t* satisfying depstring
sourcepub unsafe fn alpm_find_dbs_satisfier(
&self,
handle: *mut alpm_handle_t,
dbs: *mut alpm_list_t,
depstring: *const c_char
) -> *mut alpm_pkg_t
pub unsafe fn alpm_find_dbs_satisfier(
&self,
handle: *mut alpm_handle_t,
dbs: *mut alpm_list_t,
depstring: *const c_char
) -> *mut alpm_pkg_t
Find a package satisfying a specified dependency. First look for a literal, going through each db one by one. Then look for providers. The first satisfyer that belongs to an installed package is returned. If no providers belong to an installed package then an alpm_question_select_provider_t is created to select the provider. The dependency can include versions with depmod operators.
@param handle the context handle @param dbs an alpm_list_t* of alpm_db_t where the satisfyer will be searched @param depstring package or provision name, versioned or not @return a alpm_pkg_t* satisfying depstring
sourcepub unsafe fn alpm_checkconflicts(
&self,
handle: *mut alpm_handle_t,
pkglist: *mut alpm_list_t
) -> *mut alpm_list_t
pub unsafe fn alpm_checkconflicts(
&self,
handle: *mut alpm_handle_t,
pkglist: *mut alpm_list_t
) -> *mut alpm_list_t
Check the package conflicts in a database
@param handle the context handle @param pkglist the list of packages to check
@return an alpm_list_t of alpm_conflict_t
sourcepub unsafe fn alpm_dep_compute_string(
&self,
dep: *const alpm_depend_t
) -> *mut c_char
pub unsafe fn alpm_dep_compute_string(
&self,
dep: *const alpm_depend_t
) -> *mut c_char
Returns a newly allocated string representing the dependency information. @param dep a dependency info structure @return a formatted string, e.g. “glibc>=2.12”
sourcepub unsafe fn alpm_dep_from_string(
&self,
depstring: *const c_char
) -> *mut alpm_depend_t
pub unsafe fn alpm_dep_from_string(
&self,
depstring: *const c_char
) -> *mut alpm_depend_t
Return a newly allocated dependency information parsed from a string \link alpm_dep_free should be used to free the dependency \endlink @param depstring a formatted string, e.g. “glibc=2.12” @return a dependency info structure
sourcepub unsafe fn alpm_dep_free(&self, dep: *mut alpm_depend_t)
pub unsafe fn alpm_dep_free(&self, dep: *mut alpm_depend_t)
Free a dependency info structure @param dep struct to free
sourcepub unsafe fn alpm_fileconflict_free(&self, conflict: *mut alpm_fileconflict_t)
pub unsafe fn alpm_fileconflict_free(&self, conflict: *mut alpm_fileconflict_t)
Free a fileconflict and its members. @param conflict the fileconflict to free
sourcepub unsafe fn alpm_depmissing_free(&self, miss: *mut alpm_depmissing_t)
pub unsafe fn alpm_depmissing_free(&self, miss: *mut alpm_depmissing_t)
Free a depmissing and its members @param miss the depmissing to free
sourcepub unsafe fn alpm_conflict_free(&self, conflict: *mut alpm_conflict_t)
pub unsafe fn alpm_conflict_free(&self, conflict: *mut alpm_conflict_t)
Free a conflict and its members. @param conflict the conflict to free
sourcepub unsafe fn alpm_get_localdb(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_db_t
pub unsafe fn alpm_get_localdb(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_db_t
Get the database of locally installed packages. The returned pointer points to an internal structure of libalpm which should only be manipulated through libalpm functions. @return a reference to the local database
sourcepub unsafe fn alpm_get_syncdbs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_get_syncdbs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Get the list of sync databases. Returns a list of alpm_db_t structures, one for each registered sync database.
@param handle the context handle @return a reference to an internal list of alpm_db_t structures
sourcepub unsafe fn alpm_register_syncdb(
&self,
handle: *mut alpm_handle_t,
treename: *const c_char,
level: c_int
) -> *mut alpm_db_t
pub unsafe fn alpm_register_syncdb(
&self,
handle: *mut alpm_handle_t,
treename: *const c_char,
level: c_int
) -> *mut alpm_db_t
Register a sync database of packages. Databases can not be registered when there is an active transaction.
@param handle the context handle @param treename the name of the sync repository @param level what level of signature checking to perform on the database; note that this must be a ‘.sig’ file type verification @return an alpm_db_t* on success (the value), NULL on error
sourcepub unsafe fn alpm_unregister_all_syncdbs(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_unregister_all_syncdbs(
&self,
handle: *mut alpm_handle_t
) -> c_int
Unregister all package databases. Databases can not be unregistered while there is an active transaction.
@param handle the context handle @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_unregister(&self, db: *mut alpm_db_t) -> c_int
pub unsafe fn alpm_db_unregister(&self, db: *mut alpm_db_t) -> c_int
Unregister a package database. Databases can not be unregistered when there is an active transaction.
@param db pointer to the package database to unregister @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_get_name(&self, db: *const alpm_db_t) -> *const c_char
pub unsafe fn alpm_db_get_name(&self, db: *const alpm_db_t) -> *const c_char
Get the name of a package database. @param db pointer to the package database @return the name of the package database, NULL on error
sourcepub unsafe fn alpm_db_get_siglevel(&self, db: *mut alpm_db_t) -> c_int
pub unsafe fn alpm_db_get_siglevel(&self, db: *mut alpm_db_t) -> c_int
Get the signature verification level for a database. Will return the default verification level if this database is set up with ALPM_SIG_USE_DEFAULT. @param db pointer to the package database @return the signature verification level
sourcepub unsafe fn alpm_db_get_valid(&self, db: *mut alpm_db_t) -> c_int
pub unsafe fn alpm_db_get_valid(&self, db: *mut alpm_db_t) -> c_int
Check the validity of a database. This is most useful for sync databases and verifying signature status. If invalid, the handle error code will be set accordingly. @param db pointer to the package database @return 0 if valid, -1 if invalid (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_get_servers(
&self,
db: *const alpm_db_t
) -> *mut alpm_list_t
pub unsafe fn alpm_db_get_servers(
&self,
db: *const alpm_db_t
) -> *mut alpm_list_t
Get the list of servers assigned to this db. @param db pointer to the database to get the servers from @return a char* list of servers
sourcepub unsafe fn alpm_db_set_servers(
&self,
db: *mut alpm_db_t,
servers: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_db_set_servers(
&self,
db: *mut alpm_db_t,
servers: *mut alpm_list_t
) -> c_int
Sets the list of servers for the database to use. @param db the database to set the servers. The list will be duped and the original will still need to be freed by the caller. @param servers a char* list of servers.
sourcepub unsafe fn alpm_db_add_server(
&self,
db: *mut alpm_db_t,
url: *const c_char
) -> c_int
pub unsafe fn alpm_db_add_server(
&self,
db: *mut alpm_db_t,
url: *const c_char
) -> c_int
Add a download server to a database. @param db database pointer @param url url of the server @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_remove_server(
&self,
db: *mut alpm_db_t,
url: *const c_char
) -> c_int
pub unsafe fn alpm_db_remove_server(
&self,
db: *mut alpm_db_t,
url: *const c_char
) -> c_int
Remove a download server from a database. @param db database pointer @param url url of the server @return 0 on success, 1 on server not present, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_update(
&self,
handle: *mut alpm_handle_t,
dbs: *mut alpm_list_t,
force: c_int
) -> c_int
pub unsafe fn alpm_db_update(
&self,
handle: *mut alpm_handle_t,
dbs: *mut alpm_list_t,
force: c_int
) -> c_int
Update package databases.
An update of the package databases in the list \a dbs will be attempted. Unless \a force is true, the update will only be performed if the remote databases were modified since the last update.
This operation requires a database lock, and will return an applicable error if the lock could not be obtained.
Example: @code alpm_list_t *dbs = alpm_get_syncdbs(config->handle); ret = alpm_db_update(config->handle, dbs, force); if(ret < 0) { pm_printf(ALPM_LOG_ERROR, _(“failed to synchronize all databases (%s)\n”), alpm_strerror(alpm_errno(config->handle))); } @endcode
@note After a successful update, the \link alpm_db_get_pkgcache() package cache \endlink will be invalidated @param handle the context handle @param dbs list of package databases to update @param force if true, then forces the update, otherwise update only in case the databases aren’t up to date @return 0 on success, -1 on error (pm_errno is set accordingly), 1 if all databases are up to to date
sourcepub unsafe fn alpm_db_get_pkg(
&self,
db: *mut alpm_db_t,
name: *const c_char
) -> *mut alpm_pkg_t
pub unsafe fn alpm_db_get_pkg(
&self,
db: *mut alpm_db_t,
name: *const c_char
) -> *mut alpm_pkg_t
Get a package entry from a package database. Looking up a package is O(1) and will be significantly faster than iterating over the pkgcahe. @param db pointer to the package database to get the package from @param name of the package @return the package entry on success, NULL on error
sourcepub unsafe fn alpm_db_get_pkgcache(&self, db: *mut alpm_db_t) -> *mut alpm_list_t
pub unsafe fn alpm_db_get_pkgcache(&self, db: *mut alpm_db_t) -> *mut alpm_list_t
Get the package cache of a package database. This is a list of all packages the db contains. @param db pointer to the package database to get the package from @return the list of packages on success, NULL on error
sourcepub unsafe fn alpm_db_get_group(
&self,
db: *mut alpm_db_t,
name: *const c_char
) -> *mut alpm_group_t
pub unsafe fn alpm_db_get_group(
&self,
db: *mut alpm_db_t,
name: *const c_char
) -> *mut alpm_group_t
Get a group entry from a package database. Looking up a group is O(1) and will be significantly faster than iterating over the groupcahe. @param db pointer to the package database to get the group from @param name of the group @return the groups entry on success, NULL on error
sourcepub unsafe fn alpm_db_get_groupcache(
&self,
db: *mut alpm_db_t
) -> *mut alpm_list_t
pub unsafe fn alpm_db_get_groupcache(
&self,
db: *mut alpm_db_t
) -> *mut alpm_list_t
Get the group cache of a package database. @param db pointer to the package database to get the group from @return the list of groups on success, NULL on error
sourcepub unsafe fn alpm_db_search(
&self,
db: *mut alpm_db_t,
needles: *const alpm_list_t,
ret: *mut *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_db_search(
&self,
db: *mut alpm_db_t,
needles: *const alpm_list_t,
ret: *mut *mut alpm_list_t
) -> c_int
Searches a database with regular expressions. @param db pointer to the package database to search in @param needles a list of regular expressions to search for @param ret pointer to list for storing packages matching all regular expressions - must point to an empty (NULL) alpm_list_t *. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_db_set_usage(&self, db: *mut alpm_db_t, usage: c_int) -> c_int
pub unsafe fn alpm_db_set_usage(&self, db: *mut alpm_db_t, usage: c_int) -> c_int
Sets the usage of a database. @param db pointer to the package database to set the status for @param usage a bitmask of alpm_db_usage_t values @return 0 on success, or -1 on error
sourcepub unsafe fn alpm_db_get_usage(
&self,
db: *mut alpm_db_t,
usage: *mut c_int
) -> c_int
pub unsafe fn alpm_db_get_usage(
&self,
db: *mut alpm_db_t,
usage: *mut c_int
) -> c_int
Gets the usage of a database. @param db pointer to the package database to get the status of @param usage pointer to an alpm_db_usage_t to store db’s status @return 0 on success, or -1 on error
sourcepub unsafe fn alpm_option_get_logcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_log
pub unsafe fn alpm_option_get_logcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_log
Returns the callback used for logging. @param handle the context handle @return the currently set log callback
sourcepub unsafe fn alpm_option_get_logcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_logcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the callback used for logging. @param handle the context handle @return the currently set log callback context
sourcepub unsafe fn alpm_option_set_logcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_log,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_logcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_log,
ctx: *mut c_void
) -> c_int
Sets the callback used for logging. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_dlcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_download
pub unsafe fn alpm_option_get_dlcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_download
Returns the callback used to report download progress. @param handle the context handle @return the currently set download callback
sourcepub unsafe fn alpm_option_get_dlcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_dlcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the callback used to report download progress. @param handle the context handle @return the currently set download callback context
sourcepub unsafe fn alpm_option_set_dlcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_download,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_dlcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_download,
ctx: *mut c_void
) -> c_int
Sets the callback used to report download progress. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_fetchcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_fetch
pub unsafe fn alpm_option_get_fetchcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_fetch
Returns the downloading callback. @param handle the context handle @return the currently set fetch callback
sourcepub unsafe fn alpm_option_get_fetchcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_fetchcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the downloading callback. @param handle the context handle @return the currently set fetch callback context
sourcepub unsafe fn alpm_option_set_fetchcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_fetch,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_fetchcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_fetch,
ctx: *mut c_void
) -> c_int
Sets the downloading callback. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_eventcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_event
pub unsafe fn alpm_option_get_eventcb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_event
Returns the callback used for events. @param handle the context handle @return the currently set event callback
sourcepub unsafe fn alpm_option_get_eventcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_eventcb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the callback used for events. @param handle the context handle @return the currently set event callback context
sourcepub unsafe fn alpm_option_set_eventcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_event,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_eventcb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_event,
ctx: *mut c_void
) -> c_int
Sets the callback used for events. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_questioncb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_question
pub unsafe fn alpm_option_get_questioncb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_question
Returns the callback used for questions. @param handle the context handle @return the currently set question callback
sourcepub unsafe fn alpm_option_get_questioncb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_questioncb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the callback used for questions. @param handle the context handle @return the currently set question callback context
sourcepub unsafe fn alpm_option_set_questioncb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_question,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_questioncb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_question,
ctx: *mut c_void
) -> c_int
Sets the callback used for questions. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_progresscb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_progress
pub unsafe fn alpm_option_get_progresscb(
&self,
handle: *mut alpm_handle_t
) -> alpm_cb_progress
Returns the callback used for operation progress. @param handle the context handle @return the currently set progress callback
sourcepub unsafe fn alpm_option_get_progresscb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
pub unsafe fn alpm_option_get_progresscb_ctx(
&self,
handle: *mut alpm_handle_t
) -> *mut c_void
Returns the callback used for operation progress. @param handle the context handle @return the currently set progress callback context
sourcepub unsafe fn alpm_option_set_progresscb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_progress,
ctx: *mut c_void
) -> c_int
pub unsafe fn alpm_option_set_progresscb(
&self,
handle: *mut alpm_handle_t,
cb: alpm_cb_progress,
ctx: *mut c_void
) -> c_int
Sets the callback used for operation progress. @param handle the context handle @param cb the cb to use @param ctx user-provided context to pass to cb @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_root(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_root(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Returns the root path. Read-only. @param handle the context handle
sourcepub unsafe fn alpm_option_get_dbpath(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_dbpath(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Returns the path to the database directory. Read-only. @param handle the context handle
sourcepub unsafe fn alpm_option_get_lockfile(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_lockfile(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Get the name of the database lock file. Read-only. This is the name that the lockfile would have. It does not matter if the lockfile actually exists on disk. @param handle the context handle
sourcepub unsafe fn alpm_option_get_cachedirs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_cachedirs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Gets the currently configured cachedirs, @param handle the context handle @return a char* list of cache directories
sourcepub unsafe fn alpm_option_set_cachedirs(
&self,
handle: *mut alpm_handle_t,
cachedirs: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_cachedirs(
&self,
handle: *mut alpm_handle_t,
cachedirs: *mut alpm_list_t
) -> c_int
Sets the cachedirs. @param handle the context handle @param cachedirs a char* list of cachdirs. The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_add_cachedir(
&self,
handle: *mut alpm_handle_t,
cachedir: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_cachedir(
&self,
handle: *mut alpm_handle_t,
cachedir: *const c_char
) -> c_int
Append a cachedir to the configured cachedirs. @param handle the context handle @param cachedir the cachedir to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_cachedir(
&self,
handle: *mut alpm_handle_t,
cachedir: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_cachedir(
&self,
handle: *mut alpm_handle_t,
cachedir: *const c_char
) -> c_int
Remove a cachedir from the configured cachedirs. @param handle the context handle @param cachedir the cachedir to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_hookdirs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_hookdirs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Gets the currently configured hookdirs, @param handle the context handle @return a char* list of hook directories
sourcepub unsafe fn alpm_option_set_hookdirs(
&self,
handle: *mut alpm_handle_t,
hookdirs: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_hookdirs(
&self,
handle: *mut alpm_handle_t,
hookdirs: *mut alpm_list_t
) -> c_int
Sets the hookdirs. @param handle the context handle @param hookdirs a char* list of hookdirs. The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_add_hookdir(
&self,
handle: *mut alpm_handle_t,
hookdir: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_hookdir(
&self,
handle: *mut alpm_handle_t,
hookdir: *const c_char
) -> c_int
Append a hookdir to the configured hookdirs. @param handle the context handle @param hookdir the hookdir to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_hookdir(
&self,
handle: *mut alpm_handle_t,
hookdir: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_hookdir(
&self,
handle: *mut alpm_handle_t,
hookdir: *const c_char
) -> c_int
Remove a hookdir from the configured hookdirs. @param handle the context handle @param hookdir the hookdir to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_overwrite_files(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_overwrite_files(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Gets the currently configured overwritable files, @param handle the context handle @return a char* list of overwritable file globs
sourcepub unsafe fn alpm_option_set_overwrite_files(
&self,
handle: *mut alpm_handle_t,
globs: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_overwrite_files(
&self,
handle: *mut alpm_handle_t,
globs: *mut alpm_list_t
) -> c_int
Sets the overwritable files. @param handle the context handle @param globs a char* list of overwritable file globs. The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_add_overwrite_file(
&self,
handle: *mut alpm_handle_t,
glob: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_overwrite_file(
&self,
handle: *mut alpm_handle_t,
glob: *const c_char
) -> c_int
Append an overwritable file to the configured overwritable files. @param handle the context handle @param glob the file glob to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_overwrite_file(
&self,
handle: *mut alpm_handle_t,
glob: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_overwrite_file(
&self,
handle: *mut alpm_handle_t,
glob: *const c_char
) -> c_int
Remove a file glob from the configured overwritable files globs. @note The overwritable file list contains a list of globs. The glob to remove must exactly match the entry to remove. There is no glob expansion. @param handle the context handle @param glob the file glob to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_logfile(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_logfile(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Gets the filepath to the currently set logfile. @param handle the context handle @return the path to the logfile
sourcepub unsafe fn alpm_option_set_logfile(
&self,
handle: *mut alpm_handle_t,
logfile: *const c_char
) -> c_int
pub unsafe fn alpm_option_set_logfile(
&self,
handle: *mut alpm_handle_t,
logfile: *const c_char
) -> c_int
Sets the logfile path. @param handle the context handle @param logfile path to the new location of the logfile @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_gpgdir(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_gpgdir(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Returns the path to libalpm’s GnuPG home directory. @param handle the context handle @return the path to libalpms’s GnuPG home directory
sourcepub unsafe fn alpm_option_set_gpgdir(
&self,
handle: *mut alpm_handle_t,
gpgdir: *const c_char
) -> c_int
pub unsafe fn alpm_option_set_gpgdir(
&self,
handle: *mut alpm_handle_t,
gpgdir: *const c_char
) -> c_int
Sets the path to libalpm’s GnuPG home directory. @param handle the context handle @param gpgdir the gpgdir to set
sourcepub unsafe fn alpm_option_get_usesyslog(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_usesyslog(
&self,
handle: *mut alpm_handle_t
) -> c_int
Returns whether to use syslog (0 is FALSE, TRUE otherwise). @param handle the context handle @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_usesyslog(
&self,
handle: *mut alpm_handle_t,
usesyslog: c_int
) -> c_int
pub unsafe fn alpm_option_set_usesyslog(
&self,
handle: *mut alpm_handle_t,
usesyslog: c_int
) -> c_int
Sets whether to use syslog (0 is FALSE, TRUE otherwise). @param handle the context handle @param usesyslog whether to use the syslog (0 is FALSE, TRUE otherwise)
sourcepub unsafe fn alpm_option_get_noupgrades(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_noupgrades(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Get the list of no-upgrade files @param handle the context handle @return the char* list of no-upgrade files
sourcepub unsafe fn alpm_option_add_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Add a file to the no-upgrade list @param handle the context handle @param path the path to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_noupgrades(
&self,
handle: *mut alpm_handle_t,
noupgrade: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_noupgrades(
&self,
handle: *mut alpm_handle_t,
noupgrade: *mut alpm_list_t
) -> c_int
Sets the list of no-upgrade files @param handle the context handle @param noupgrade a char* list of file to not upgrade. The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Remove an entry from the no-upgrade list @param handle the context handle @param path the path to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_match_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_match_noupgrade(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Test if a path matches any of the globs in the no-upgrade list @param handle the context handle @param path the path to test @return 0 is the path matches a glob, negative if there is no match and positive is the match was inverted
sourcepub unsafe fn alpm_option_get_noextracts(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_noextracts(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Get the list of no-extract files @param handle the context handle @return the char* list of no-extract files
sourcepub unsafe fn alpm_option_add_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Add a file to the no-extract list @param handle the context handle @param path the path to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_noextracts(
&self,
handle: *mut alpm_handle_t,
noextract: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_noextracts(
&self,
handle: *mut alpm_handle_t,
noextract: *mut alpm_list_t
) -> c_int
Sets the list of no-extract files @param handle the context handle @param noextract a char* list of file to not extract. The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Remove an entry from the no-extract list @param handle the context handle @param path the path to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_match_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
pub unsafe fn alpm_option_match_noextract(
&self,
handle: *mut alpm_handle_t,
path: *const c_char
) -> c_int
Test if a path matches any of the globs in the no-extract list @param handle the context handle @param path the path to test @return 0 is the path matches a glob, negative if there is no match and positive is the match was inverted
sourcepub unsafe fn alpm_option_get_ignorepkgs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_ignorepkgs(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Get the list of ignored packages @param handle the context handle @return the char* list of ignored packages
sourcepub unsafe fn alpm_option_add_ignorepkg(
&self,
handle: *mut alpm_handle_t,
pkg: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_ignorepkg(
&self,
handle: *mut alpm_handle_t,
pkg: *const c_char
) -> c_int
Add a file to the ignored package list @param handle the context handle @param pkg the package to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_ignorepkgs(
&self,
handle: *mut alpm_handle_t,
ignorepkgs: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_ignorepkgs(
&self,
handle: *mut alpm_handle_t,
ignorepkgs: *mut alpm_list_t
) -> c_int
Sets the list of packages to ignore @param handle the context handle @param ignorepkgs a char* list of packages to ignore The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_ignorepkg(
&self,
handle: *mut alpm_handle_t,
pkg: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_ignorepkg(
&self,
handle: *mut alpm_handle_t,
pkg: *const c_char
) -> c_int
Remove an entry from the ignorepkg list @param handle the context handle @param pkg the package to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_ignoregroups(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_ignoregroups(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Get the list of ignored groups @param handle the context handle @return the char* list of ignored groups
sourcepub unsafe fn alpm_option_add_ignoregroup(
&self,
handle: *mut alpm_handle_t,
grp: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_ignoregroup(
&self,
handle: *mut alpm_handle_t,
grp: *const c_char
) -> c_int
Add a file to the ignored group list @param handle the context handle @param grp the group to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_ignoregroups(
&self,
handle: *mut alpm_handle_t,
ignoregrps: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_ignoregroups(
&self,
handle: *mut alpm_handle_t,
ignoregrps: *mut alpm_list_t
) -> c_int
Sets the list of groups to ignore @param handle the context handle @param ignoregrps a char* list of groups to ignore The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_ignoregroup(
&self,
handle: *mut alpm_handle_t,
grp: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_ignoregroup(
&self,
handle: *mut alpm_handle_t,
grp: *const c_char
) -> c_int
Remove an entry from the ignoregroup list @param handle the context handle @param grp the group to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_assumeinstalled(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_assumeinstalled(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Gets the list of dependencies that are assumed to be met @param handle the context handle @return a list of alpm_depend_t*
sourcepub unsafe fn alpm_option_add_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
dep: *const alpm_depend_t
) -> c_int
pub unsafe fn alpm_option_add_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
dep: *const alpm_depend_t
) -> c_int
Add a depend to the assumed installed list @param handle the context handle @param dep the dependency to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
deps: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
deps: *mut alpm_list_t
) -> c_int
Sets the list of dependencies that are assumed to be met @param handle the context handle @param deps a list of *alpm_depend_t The list will be duped and the original will still need to be freed by the caller. @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_remove_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
dep: *const alpm_depend_t
) -> c_int
pub unsafe fn alpm_option_remove_assumeinstalled(
&self,
handle: *mut alpm_handle_t,
dep: *const alpm_depend_t
) -> c_int
Remove an entry from the assume installed list @param handle the context handle @param dep the dep to remove @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_architectures(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_option_get_architectures(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Returns the allowed package architecture. @param handle the context handle @return the configured package architectures
sourcepub unsafe fn alpm_option_add_architecture(
&self,
handle: *mut alpm_handle_t,
arch: *const c_char
) -> c_int
pub unsafe fn alpm_option_add_architecture(
&self,
handle: *mut alpm_handle_t,
arch: *const c_char
) -> c_int
Adds an allowed package architecture. @param handle the context handle @param arch the architecture to set
sourcepub unsafe fn alpm_option_set_architectures(
&self,
handle: *mut alpm_handle_t,
arches: *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_option_set_architectures(
&self,
handle: *mut alpm_handle_t,
arches: *mut alpm_list_t
) -> c_int
Sets the allowed package architecture. @param handle the context handle @param arches the architecture to set
sourcepub unsafe fn alpm_option_remove_architecture(
&self,
handle: *mut alpm_handle_t,
arch: *const c_char
) -> c_int
pub unsafe fn alpm_option_remove_architecture(
&self,
handle: *mut alpm_handle_t,
arch: *const c_char
) -> c_int
Removes an allowed package architecture. @param handle the context handle @param arch the architecture to remove
sourcepub unsafe fn alpm_option_get_checkspace(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_checkspace(
&self,
handle: *mut alpm_handle_t
) -> c_int
Get whether or not checking for free space before installing packages is enabled. @param handle the context handle @return 0 if disabled, 1 if enabled
sourcepub unsafe fn alpm_option_set_checkspace(
&self,
handle: *mut alpm_handle_t,
checkspace: c_int
) -> c_int
pub unsafe fn alpm_option_set_checkspace(
&self,
handle: *mut alpm_handle_t,
checkspace: c_int
) -> c_int
Enable/disable checking free space before installing packages. @param handle the context handle @param checkspace 0 for disabled, 1 for enabled
sourcepub unsafe fn alpm_option_get_dbext(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
pub unsafe fn alpm_option_get_dbext(
&self,
handle: *mut alpm_handle_t
) -> *const c_char
Gets the configured database extension. @param handle the context handle @return the configured database extension
sourcepub unsafe fn alpm_option_set_dbext(
&self,
handle: *mut alpm_handle_t,
dbext: *const c_char
) -> c_int
pub unsafe fn alpm_option_set_dbext(
&self,
handle: *mut alpm_handle_t,
dbext: *const c_char
) -> c_int
Sets the database extension. @param handle the context handle @param dbext the database extension to use @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_default_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_default_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
Get the default siglevel. @param handle the context handle @return a \link alpm_siglevel_t \endlink bitfield of the siglevel
sourcepub unsafe fn alpm_option_set_default_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
pub unsafe fn alpm_option_set_default_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
Set the default siglevel. @param handle the context handle @param level a \link alpm_siglevel_t \endlink bitfield of the level to set @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_local_file_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_local_file_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
Get the configured local file siglevel. @param handle the context handle @return a \link alpm_siglevel_t \endlink bitfield of the siglevel
sourcepub unsafe fn alpm_option_set_local_file_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
pub unsafe fn alpm_option_set_local_file_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
Set the local file siglevel. @param handle the context handle @param level a \link alpm_siglevel_t \endlink bitfield of the level to set @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_remote_file_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_remote_file_siglevel(
&self,
handle: *mut alpm_handle_t
) -> c_int
Get the configured remote file siglevel. @param handle the context handle @return a \link alpm_siglevel_t \endlink bitfield of the siglevel
sourcepub unsafe fn alpm_option_set_remote_file_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
pub unsafe fn alpm_option_set_remote_file_siglevel(
&self,
handle: *mut alpm_handle_t,
level: c_int
) -> c_int
Set the remote file siglevel. @param handle the context handle @param level a \link alpm_siglevel_t \endlink bitfield of the level to set @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_set_disable_dl_timeout(
&self,
handle: *mut alpm_handle_t,
disable_dl_timeout: c_ushort
) -> c_int
pub unsafe fn alpm_option_set_disable_dl_timeout(
&self,
handle: *mut alpm_handle_t,
disable_dl_timeout: c_ushort
) -> c_int
Enables/disables the download timeout. @param handle the context handle @param disable_dl_timeout 0 for enabled, 1 for disabled @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_option_get_parallel_downloads(
&self,
handle: *mut alpm_handle_t
) -> c_int
pub unsafe fn alpm_option_get_parallel_downloads(
&self,
handle: *mut alpm_handle_t
) -> c_int
Gets the number of parallel streams to download database and package files. @param handle the context handle @return the number of parallel streams to download database and package files
sourcepub unsafe fn alpm_option_set_parallel_downloads(
&self,
handle: *mut alpm_handle_t,
num_streams: c_uint
) -> c_int
pub unsafe fn alpm_option_set_parallel_downloads(
&self,
handle: *mut alpm_handle_t,
num_streams: c_uint
) -> c_int
Sets number of parallel streams to download database and package files. @param handle the context handle @param num_streams number of parallel download streams @return 0 on success, -1 on error
sourcepub unsafe fn alpm_pkg_load(
&self,
handle: *mut alpm_handle_t,
filename: *const c_char,
full: c_int,
level: c_int,
pkg: *mut *mut alpm_pkg_t
) -> c_int
pub unsafe fn alpm_pkg_load(
&self,
handle: *mut alpm_handle_t,
filename: *const c_char,
full: c_int,
level: c_int,
pkg: *mut *mut alpm_pkg_t
) -> c_int
Create a package from a file. If full is false, the archive is read only until all necessary metadata is found. If it is true, the entire archive is read, which serves as a verification of integrity and the filelist can be created. The allocated structure should be freed using alpm_pkg_free(). @param handle the context handle @param filename location of the package tarball @param full whether to stop the load after metadata is read or continue through the full archive @param level what level of package signature checking to perform on the package; note that this must be a ‘.sig’ file type verification @param pkg address of the package pointer @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_fetch_pkgurl(
&self,
handle: *mut alpm_handle_t,
urls: *const alpm_list_t,
fetched: *mut *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_fetch_pkgurl(
&self,
handle: *mut alpm_handle_t,
urls: *const alpm_list_t,
fetched: *mut *mut alpm_list_t
) -> c_int
Fetch a list of remote packages.
@param handle the context handle
@param urls list of package URLs to download
@param fetched list of filepaths to the fetched packages, each item
corresponds to one in urls
list. This is an output parameter,
the caller should provide a pointer to an empty list
(*fetched === NULL) and the callee fills the list with data.
@return 0 on success or -1 on failure
sourcepub unsafe fn alpm_pkg_find(
&self,
haystack: *mut alpm_list_t,
needle: *const c_char
) -> *mut alpm_pkg_t
pub unsafe fn alpm_pkg_find(
&self,
haystack: *mut alpm_list_t,
needle: *const c_char
) -> *mut alpm_pkg_t
Find a package in a list by name. @param haystack a list of alpm_pkg_t @param needle the package name @return a pointer to the package if found or NULL
sourcepub unsafe fn alpm_pkg_free(&self, pkg: *mut alpm_pkg_t) -> c_int
pub unsafe fn alpm_pkg_free(&self, pkg: *mut alpm_pkg_t) -> c_int
Free a package. Only packages loaded with \link alpm_pkg_load \endlink can be freed. Packages from databases will be freed by libalpm when they are unregistered. @param pkg package pointer to free @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_pkg_checkmd5sum(&self, pkg: *mut alpm_pkg_t) -> c_int
pub unsafe fn alpm_pkg_checkmd5sum(&self, pkg: *mut alpm_pkg_t) -> c_int
Check the integrity (with md5) of a package from the sync cache. @param pkg package pointer @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_pkg_vercmp(&self, a: *const c_char, b: *const c_char) -> c_int
pub unsafe fn alpm_pkg_vercmp(&self, a: *const c_char, b: *const c_char) -> c_int
Compare two version strings and determine which one is ‘newer’. Returns a value comparable to the way strcmp works. Returns 1 if a is newer than b, 0 if a and b are the same version, or -1 if b is newer than a.
Different epoch values for version strings will override any further comparison. If no epoch is provided, 0 is assumed.
Keep in mind that the pkgrel is only compared if it is available on both versions handed to this function. For example, comparing 1.5-1 and 1.5 will yield 0; comparing 1.5-1 and 1.5-2 will yield -1 as expected. This is mainly for supporting versioned dependencies that do not include the pkgrel.
sourcepub unsafe fn alpm_pkg_compute_requiredby(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_compute_requiredby(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Computes the list of packages requiring a given package. The return value of this function is a newly allocated list of package names (char*), it should be freed by the caller. @param pkg a package @return the list of packages requiring pkg
sourcepub unsafe fn alpm_pkg_compute_optionalfor(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_compute_optionalfor(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Computes the list of packages optionally requiring a given package. The return value of this function is a newly allocated list of package names (char*), it should be freed by the caller. @param pkg a package @return the list of packages optionally requiring pkg
sourcepub unsafe fn alpm_pkg_should_ignore(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
pub unsafe fn alpm_pkg_should_ignore(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
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
sourcepub unsafe fn alpm_pkg_get_filename(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_filename(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Gets the name of the file from which the package was loaded. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_base(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_base(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package base name. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_name(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_name(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package name. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_version(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_version(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package version as a string. This includes all available epoch, version, and pkgrel components. Use alpm_pkg_vercmp() to compare version strings if necessary. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_origin(&self, pkg: *mut alpm_pkg_t) -> alpm_pkgfrom_t
pub unsafe fn alpm_pkg_get_origin(&self, pkg: *mut alpm_pkg_t) -> alpm_pkgfrom_t
Returns the origin of the package. @return an alpm_pkgfrom_t constant, -1 on error
sourcepub unsafe fn alpm_pkg_get_desc(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_desc(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package description. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_url(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_url(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package URL. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_builddate(&self, pkg: *mut alpm_pkg_t) -> alpm_time_t
pub unsafe fn alpm_pkg_get_builddate(&self, pkg: *mut alpm_pkg_t) -> alpm_time_t
Returns the build timestamp of the package. @param pkg a pointer to package @return the timestamp of the build time
sourcepub unsafe fn alpm_pkg_get_installdate(
&self,
pkg: *mut alpm_pkg_t
) -> alpm_time_t
pub unsafe fn alpm_pkg_get_installdate(
&self,
pkg: *mut alpm_pkg_t
) -> alpm_time_t
Returns the install timestamp of the package. @param pkg a pointer to package @return the timestamp of the install time
sourcepub unsafe fn alpm_pkg_get_packager(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_packager(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the packager’s name. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_md5sum(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_md5sum(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the package’s MD5 checksum as a string. The returned string is a sequence of 32 lowercase hexadecimal digits. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_sha256sum(
&self,
pkg: *mut alpm_pkg_t
) -> *const c_char
pub unsafe fn alpm_pkg_get_sha256sum(
&self,
pkg: *mut alpm_pkg_t
) -> *const c_char
Returns the package’s SHA256 checksum as a string. The returned string is a sequence of 64 lowercase hexadecimal digits. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_arch(&self, pkg: *mut alpm_pkg_t) -> *const c_char
pub unsafe fn alpm_pkg_get_arch(&self, pkg: *mut alpm_pkg_t) -> *const c_char
Returns the architecture for which the package was built. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_size(&self, pkg: *mut alpm_pkg_t) -> off_t
pub unsafe fn alpm_pkg_get_size(&self, pkg: *mut alpm_pkg_t) -> off_t
Returns the size of the package. This is only available for sync database packages and package files, not those loaded from the local database. @param pkg a pointer to package @return the size of the package in bytes.
sourcepub unsafe fn alpm_pkg_get_isize(&self, pkg: *mut alpm_pkg_t) -> off_t
pub unsafe fn alpm_pkg_get_isize(&self, pkg: *mut alpm_pkg_t) -> off_t
Returns the installed size of the package. @param pkg a pointer to package @return the total size of files installed by the package.
sourcepub unsafe fn alpm_pkg_get_reason(
&self,
pkg: *mut alpm_pkg_t
) -> alpm_pkgreason_t
pub unsafe fn alpm_pkg_get_reason(
&self,
pkg: *mut alpm_pkg_t
) -> alpm_pkgreason_t
Returns the package installation reason. @param pkg a pointer to package @return an enum member giving the install reason.
sourcepub unsafe fn alpm_pkg_get_licenses(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_licenses(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of package licenses. @param pkg a pointer to package @return a pointer to an internal list of strings.
sourcepub unsafe fn alpm_pkg_get_groups(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_groups(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of package groups. @param pkg a pointer to package @return a pointer to an internal list of strings.
sourcepub unsafe fn alpm_pkg_get_depends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_depends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of package dependencies as alpm_depend_t. @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_optdepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_optdepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of package optional dependencies. @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_checkdepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_checkdepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns a list of package check dependencies @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_makedepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_makedepends(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns a list of package make dependencies @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_conflicts(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_conflicts(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of packages conflicting with pkg. @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_provides(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_provides(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of packages provided by pkg. @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_replaces(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_replaces(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of packages to be replaced by pkg. @param pkg a pointer to package @return a reference to an internal list of alpm_depend_t structures.
sourcepub unsafe fn alpm_pkg_get_files(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_filelist_t
pub unsafe fn alpm_pkg_get_files(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_filelist_t
Returns the list of files installed by pkg. The filenames are relative to the install root, and do not include leading slashes. @param pkg a pointer to package @return a pointer to a filelist object containing a count and an array of package file objects
sourcepub unsafe fn alpm_pkg_get_backup(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
pub unsafe fn alpm_pkg_get_backup(
&self,
pkg: *mut alpm_pkg_t
) -> *mut alpm_list_t
Returns the list of files backed up when installing pkg. @param pkg a pointer to package @return a reference to a list of alpm_backup_t objects
sourcepub unsafe fn alpm_pkg_get_db(&self, pkg: *mut alpm_pkg_t) -> *mut alpm_db_t
pub unsafe fn alpm_pkg_get_db(&self, pkg: *mut alpm_pkg_t) -> *mut alpm_db_t
Returns the database containing pkg. Returns a pointer to the alpm_db_t structure the package is originating from, or NULL if the package was loaded from a file. @param pkg a pointer to package @return a pointer to the DB containing pkg, or NULL.
sourcepub unsafe fn alpm_pkg_get_base64_sig(
&self,
pkg: *mut alpm_pkg_t
) -> *const c_char
pub unsafe fn alpm_pkg_get_base64_sig(
&self,
pkg: *mut alpm_pkg_t
) -> *const c_char
Returns the base64 encoded package signature. @param pkg a pointer to package @return a reference to an internal string
sourcepub unsafe fn alpm_pkg_get_sig(
&self,
pkg: *mut alpm_pkg_t,
sig: *mut *mut c_uchar,
sig_len: *mut usize
) -> c_int
pub unsafe fn alpm_pkg_get_sig(
&self,
pkg: *mut alpm_pkg_t,
sig: *mut *mut c_uchar,
sig_len: *mut usize
) -> c_int
Extracts package signature either from embedded package signature or if it is absent then reads data from detached signature file. @param pkg a pointer to package. @param sig output parameter for signature data. Callee function allocates a buffer needed for the signature data. Caller is responsible for freeing this buffer. @param sig_len output parameter for the signature data length. @return 0 on success, negative number on error.
sourcepub unsafe fn alpm_pkg_get_validation(&self, pkg: *mut alpm_pkg_t) -> c_int
pub unsafe fn alpm_pkg_get_validation(&self, pkg: *mut alpm_pkg_t) -> c_int
Returns the method used to validate a package during install. @param pkg a pointer to package @return an enum member giving the validation method
sourcepub unsafe fn alpm_pkg_has_scriptlet(&self, pkg: *mut alpm_pkg_t) -> c_int
pub unsafe fn alpm_pkg_has_scriptlet(&self, pkg: *mut alpm_pkg_t) -> c_int
Returns whether the package has an install scriptlet. @return 0 if FALSE, TRUE otherwise
sourcepub unsafe fn alpm_pkg_download_size(&self, newpkg: *mut alpm_pkg_t) -> off_t
pub unsafe fn alpm_pkg_download_size(&self, newpkg: *mut alpm_pkg_t) -> off_t
Returns the size of the files that will be downloaded to install a package. @param newpkg the new package to upgrade to @return the size of the download
sourcepub unsafe fn alpm_pkg_set_reason(
&self,
pkg: *mut alpm_pkg_t,
reason: alpm_pkgreason_t
) -> c_int
pub unsafe fn alpm_pkg_set_reason(
&self,
pkg: *mut alpm_pkg_t,
reason: alpm_pkgreason_t
) -> c_int
Set install reason for a package in the local database. The provided package object must be from the local database or this method will fail. The write to the local database is performed immediately. @param pkg the package to update @param reason the new install reason @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_pkg_changelog_open(&self, pkg: *mut alpm_pkg_t) -> *mut c_void
pub unsafe fn alpm_pkg_changelog_open(&self, pkg: *mut alpm_pkg_t) -> *mut c_void
Open a package changelog for reading. Similar to fopen in functionality, except that the returned ‘file stream’ could really be from an archive as well as from the database. @param pkg the package to read the changelog of (either file or db) @return a ‘file stream’ to the package changelog
sourcepub unsafe fn alpm_pkg_changelog_read(
&self,
ptr: *mut c_void,
size: usize,
pkg: *const alpm_pkg_t,
fp: *mut c_void
) -> usize
pub unsafe fn alpm_pkg_changelog_read(
&self,
ptr: *mut c_void,
size: usize,
pkg: *const alpm_pkg_t,
fp: *mut c_void
) -> usize
Read data from an open changelog ‘file stream’. Similar to fread in functionality, this function takes a buffer and amount of data to read. If an error occurs pm_errno will be set. @param ptr a buffer to fill with raw changelog data @param size the size of the buffer @param pkg the package that the changelog is being read from @param fp a ‘file stream’ to the package changelog @return the number of characters read, or 0 if there is no more data or an error occurred.
sourcepub unsafe fn alpm_pkg_changelog_close(
&self,
pkg: *const alpm_pkg_t,
fp: *mut c_void
) -> c_int
pub unsafe fn alpm_pkg_changelog_close(
&self,
pkg: *const alpm_pkg_t,
fp: *mut c_void
) -> c_int
Close a package changelog for reading. @param pkg the package to close the changelog of (either file or db) @param fp the ‘file stream’ to the package changelog to close @return 0 on success, -1 on error
sourcepub unsafe fn alpm_pkg_mtree_open(&self, pkg: *mut alpm_pkg_t) -> *mut archive
pub unsafe fn alpm_pkg_mtree_open(&self, pkg: *mut alpm_pkg_t) -> *mut archive
Open a package mtree file for reading. @param pkg the local package to read the mtree of @return an archive structure for the package mtree file
sourcepub unsafe fn alpm_pkg_mtree_next(
&self,
pkg: *const alpm_pkg_t,
archive: *mut archive,
entry: *mut *mut archive_entry
) -> c_int
pub unsafe fn alpm_pkg_mtree_next(
&self,
pkg: *const alpm_pkg_t,
archive: *mut archive,
entry: *mut *mut archive_entry
) -> c_int
Read next entry from a package mtree file. @param pkg the package that the mtree file is being read from @param archive the archive structure reading from the mtree file @param entry an archive_entry to store the entry header information @return 0 on success, 1 if end of archive is reached, -1 otherwise.
sourcepub unsafe fn alpm_pkg_mtree_close(
&self,
pkg: *const alpm_pkg_t,
archive: *mut archive
) -> c_int
pub unsafe fn alpm_pkg_mtree_close(
&self,
pkg: *const alpm_pkg_t,
archive: *mut archive
) -> c_int
Close a package mtree file. @param pkg the local package to close the mtree of @param archive the archive to close
sourcepub unsafe fn alpm_trans_get_flags(&self, handle: *mut alpm_handle_t) -> c_int
pub unsafe fn alpm_trans_get_flags(&self, handle: *mut alpm_handle_t) -> c_int
Returns the bitfield of flags for the current transaction. @param handle the context handle @return the bitfield of transaction flags
sourcepub unsafe fn alpm_trans_get_add(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_trans_get_add(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Returns a list of packages added by the transaction. @param handle the context handle @return a list of alpm_pkg_t structures
sourcepub unsafe fn alpm_trans_get_remove(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
pub unsafe fn alpm_trans_get_remove(
&self,
handle: *mut alpm_handle_t
) -> *mut alpm_list_t
Returns the list of packages removed by the transaction. @param handle the context handle @return a list of alpm_pkg_t structures
sourcepub unsafe fn alpm_trans_init(
&self,
handle: *mut alpm_handle_t,
flags: c_int
) -> c_int
pub unsafe fn alpm_trans_init(
&self,
handle: *mut alpm_handle_t,
flags: c_int
) -> c_int
Initialize the transaction. @param handle the context handle @param flags flags of the transaction (like nodeps, etc; see alpm_transflag_t) @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_trans_prepare(
&self,
handle: *mut alpm_handle_t,
data: *mut *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_trans_prepare(
&self,
handle: *mut alpm_handle_t,
data: *mut *mut alpm_list_t
) -> c_int
Prepare a transaction. @param handle the context handle @param data the address of an alpm_list where a list of alpm_depmissing_t objects is dumped (conflicting packages) @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_trans_commit(
&self,
handle: *mut alpm_handle_t,
data: *mut *mut alpm_list_t
) -> c_int
pub unsafe fn alpm_trans_commit(
&self,
handle: *mut alpm_handle_t,
data: *mut *mut alpm_list_t
) -> c_int
Commit a transaction. @param handle the context handle @param data the address of an alpm_list where detailed description of an error can be dumped (i.e. list of conflicting files) @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_trans_interrupt(&self, handle: *mut alpm_handle_t) -> c_int
pub unsafe fn alpm_trans_interrupt(&self, handle: *mut alpm_handle_t) -> c_int
Interrupt a transaction. @param handle the context handle @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_trans_release(&self, handle: *mut alpm_handle_t) -> c_int
pub unsafe fn alpm_trans_release(&self, handle: *mut alpm_handle_t) -> c_int
Release a transaction. @param handle the context handle @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_sync_sysupgrade(
&self,
handle: *mut alpm_handle_t,
enable_downgrade: c_int
) -> c_int
pub unsafe fn alpm_sync_sysupgrade(
&self,
handle: *mut alpm_handle_t,
enable_downgrade: c_int
) -> c_int
Search for packages to upgrade and add them to the transaction. @param handle the context handle @param enable_downgrade allow downgrading of packages if the remote version is lower @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_add_pkg(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
pub unsafe fn alpm_add_pkg(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
Add a package to the transaction. If the package was loaded by alpm_pkg_load(), it will be freed upon \link alpm_trans_release \endlink invocation. @param handle the context handle @param pkg the package to add @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_remove_pkg(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
pub unsafe fn alpm_remove_pkg(
&self,
handle: *mut alpm_handle_t,
pkg: *mut alpm_pkg_t
) -> c_int
Add a package removal to the transaction. @param handle the context handle @param pkg the package to uninstall @return 0 on success, -1 on error (pm_errno is set accordingly)
sourcepub unsafe fn alpm_sync_get_new_version(
&self,
pkg: *mut alpm_pkg_t,
dbs_sync: *mut alpm_list_t
) -> *mut alpm_pkg_t
pub unsafe fn alpm_sync_get_new_version(
&self,
pkg: *mut alpm_pkg_t,
dbs_sync: *mut alpm_list_t
) -> *mut alpm_pkg_t
Check for new version of pkg in syncdbs.
If the same package appears multiple dbs only the first will be checked
This only checks the syncdb for a newer version. It does not access the network at all. See \link alpm_db_update \endlink to update a database.
sourcepub unsafe fn alpm_compute_md5sum(&self, filename: *const c_char) -> *mut c_char
pub unsafe fn alpm_compute_md5sum(&self, filename: *const c_char) -> *mut c_char
Get the md5 sum of file. @param filename name of the file @return the checksum on success, NULL on error
sourcepub unsafe fn alpm_compute_sha256sum(
&self,
filename: *const c_char
) -> *mut c_char
pub unsafe fn alpm_compute_sha256sum(
&self,
filename: *const c_char
) -> *mut c_char
Get the sha256 sum of file. @param filename name of the file @return the checksum on success, NULL on error
sourcepub unsafe fn alpm_unlock(&self, handle: *mut alpm_handle_t) -> c_int
pub unsafe fn alpm_unlock(&self, handle: *mut alpm_handle_t) -> c_int
Remove the database lock file @param handle the context handle @return 0 on success, -1 on error
@note Safe to call from inside signal handlers.
sourcepub unsafe fn alpm_version(&self) -> *const c_char
pub unsafe fn alpm_version(&self) -> *const c_char
Get the version of library. @return the library version, e.g. “6.0.4”
sourcepub unsafe fn alpm_capabilities(&self) -> c_int
pub unsafe fn alpm_capabilities(&self) -> c_int
Get the capabilities of the library. @return a bitmask of the capabilities
Auto Trait Implementations
impl RefUnwindSafe for libalpm
impl Send for libalpm
impl Sync for libalpm
impl Unpin for libalpm
impl UnwindSafe for libalpm
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more