Function alpm_sys::alpm_initialize

source ·
pub unsafe extern "C" fn alpm_initialize(
    root: *const c_char,
    dbpath: *const c_char,
    err: *mut alpm_errno_t
) -> *mut alpm_handle_t
Expand description

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