lib/transaction_{revdeps,prepare}.c: try to update packages if necessary

`xbps_transaction_revdeps` will now try to add updates for packages to the
transaction if the dependency is not satisified anymore due to a package
install/update.

`xbps_transaction_prepare` will now check the return value of
`xbps_transaction_revdeps` and repeat the dependency resolution,
until `xbps_transaction_revdeps` returns 0, which means that it didn't
add any new packages to the transaction.
This commit is contained in:
Duncaen
2019-07-02 15:22:58 +02:00
committed by Juan RP
parent 5e4d33a58f
commit 0e950156fc
3 changed files with 87 additions and 47 deletions

View File

@ -127,7 +127,7 @@ xbps_dictionary_t HIDDEN xbps_find_pkg_in_array(xbps_array_t, const char *,
const char *);
xbps_dictionary_t HIDDEN xbps_find_virtualpkg_in_array(struct xbps_handle *,
xbps_array_t, const char *, const char *);
void HIDDEN xbps_transaction_revdeps(struct xbps_handle *, xbps_array_t);
int HIDDEN xbps_transaction_revdeps(struct xbps_handle *, xbps_array_t);
bool HIDDEN xbps_transaction_shlibs(struct xbps_handle *, xbps_array_t,
xbps_array_t);
int HIDDEN xbps_transaction_init(struct xbps_handle *);