XBPS Library API  0.19
The X Binary Package System
Functions
Package configuration functions

Functions

int xbps_configure_packages (struct xbps_handle *xhp, bool flush)
 
int xbps_configure_pkg (struct xbps_handle *xhp, const char *pkgname, bool check_state, bool update, bool flush)
 

Detailed Description

Configure a package or all packages. Only packages in XBPS_PKG_STATE_UNPACKED state will be processed (unless overriden). Package configuration steps:

Note
If the XBPS_FLAG_FORCE_CONFIGURE is set through xbps_init() in the flags member, the package (or packages) will be reconfigured even if its state is XBPS_PKG_STATE_INSTALLED.

Function Documentation

int xbps_configure_packages ( struct xbps_handle xhp,
bool  flush 
)

Configure (or force reconfiguration of) all packages.

Parameters
[in]xhpPointer to an xbps_handle struct.
[in]flushSet it to true to flush state to pkgdb.
Returns
0 on success, otherwise an errno value.

Definition at line 50 of file package_configure.c.

References xbps_configure_pkg(), and xbps_pkgdb_update().

+ Here is the call graph for this function:

int xbps_configure_pkg ( struct xbps_handle xhp,
const char *  pkgname,
bool  check_state,
bool  update,
bool  flush 
)

Configure (or force reconfiguration of) a package.

Parameters
[in]xhpPointer to an xbps_handle struct.
[in]pkgnamePackage name to configure.
[in]check_stateSet it to true to check that package is in unpacked state.
[in]updateSet it to true if this package is being updated.
[in]flushSet it to true to flush state to pkgdb.
Returns
0 on success, otherwise an errno value.

Definition at line 80 of file package_configure.c.

References xbps_handle::flags, xbps_handle::metadir, xbps_pkg_exec_script(), xbps_pkg_state_dictionary(), xbps_pkgdb_get_pkg(), xbps_pkgdb_update(), xbps_set_pkg_state_dictionary(), and xbps_xasprintf().

Referenced by xbps_configure_packages(), and xbps_transaction_commit().

+ Here is the call graph for this function:

+ Here is the caller graph for this function: