XBPS major changes in June 2011.
- A configuration file "xbps-conf.plist" replaces the (un)register target in xbps-repo(8) and (un)set-prop in xbps-bin(8). For now, you can set the repositories and prefered virtual packages. - New package pattern matching code from NetBSD. Supports more ways of matching patterns in packages. - Multiple bugs fixed in virtual packages related matching code. --HG-- rename : LICENSE => COPYING
This commit is contained in:
@@ -37,31 +37,14 @@
|
||||
int
|
||||
show_pkg_info_from_metadir(const char *pkgname)
|
||||
{
|
||||
prop_dictionary_t d, regpkgd, pkgpropsd;
|
||||
prop_dictionary_t d;
|
||||
|
||||
d = xbps_dictionary_from_metadata_plist(pkgname, XBPS_PKGPROPS);
|
||||
if (d == NULL)
|
||||
return EINVAL;
|
||||
|
||||
regpkgd = xbps_regpkgdb_dictionary_get();
|
||||
pkgpropsd = xbps_find_pkg_in_dict_by_name(regpkgd,
|
||||
"properties", pkgname);
|
||||
if (pkgpropsd == NULL) {
|
||||
show_pkg_info(d);
|
||||
prop_object_release(d);
|
||||
goto out;
|
||||
}
|
||||
if (prop_dictionary_get(pkgpropsd, "hold"))
|
||||
prop_dictionary_set_bool(d, "hold", true);
|
||||
if (prop_dictionary_get(pkgpropsd, "update-first"))
|
||||
prop_dictionary_set_bool(d, "update-first", true);
|
||||
if (prop_dictionary_get(pkgpropsd, "provides"))
|
||||
prop_dictionary_set_bool(d, "virtual-prefer", true);
|
||||
|
||||
show_pkg_info(d);
|
||||
prop_object_release(d);
|
||||
out:
|
||||
xbps_regpkgdb_dictionary_release();
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user