diff options
-rw-r--r-- | URPM.pm | 39 | ||||
-rw-r--r-- | URPM/Resolve.pm | 26 |
2 files changed, 39 insertions, 26 deletions
@@ -780,6 +780,45 @@ lower is prefered. =back +=head2 The $state object + +It has the following fields: + +B<backtrack>: { + selected => { id => undef }, + deadlock => { id|property => undef }, + } + +B<cached_installed>: { property_name => { fullname => undef } } + +B<oldpackage>: int + # will be passed to $trans->run to set RPMPROB_FILTER_OLDPACKAGE + +B<selected>: { id => { + requested => bool, install => bool, + from => pkg, psel => pkg, + promote => name, unsatisfied => [ id|property ] + } } + +B<rejected>: { fullname => { + size => int, removed => bool, obsoleted => bool, + backtrack => { + promote => [ name ], keep => [ fullname ], + unsatisfied => [ id|property ], + closure => { fullname => { old_requested => bool, + unsatisfied => [ id|property ] } }, + }, + } } + +B<whatrequires>: { name => { id => undef } } + # reversed requires_nosense for selected packages + +more fields only used in build_transaction_set and its callers): + +B<transaction>: [ { upgrade => [ id ], remove => [ fullname ] } ] + +B<transaction_state>: $state object + =head1 COPYRIGHT Copyright 2002, 2003, 2004, 2005 MandrakeSoft SA diff --git a/URPM/Resolve.pm b/URPM/Resolve.pm index 58bf9cb..67b7a71 100644 --- a/URPM/Resolve.pm +++ b/URPM/Resolve.pm @@ -10,32 +10,6 @@ use Config; sub min { my $n = shift; $_ < $n and $n = $_ foreach @_; $n } sub uniq { my %l; $l{$_} = 1 foreach @_; grep { delete $l{$_} } @_ } -#- $state fields: -#- -#- backtrack => { selected => { id => undef }, -#- deadlock => { id|property => undef } }, -#- -#- cached_installed => { property_name => { fullname => undef } }, -#- -#- oldpackage => int, -#- # will be passed to $trans->run to set RPMPROB_FILTER_OLDPACKAGE -#- -#- selected => { id => { requested => bool, install => bool, -#- from => pkg, psel => pkg, -#- promote => name, unsatisfied => [ id|property ] } }, -#- -#- rejected => { fullname => { size => int, removed => bool, obsoleted => bool, -#- backtrack => { promote => [ name ], keep => [ fullname ], -#- unsatisfied => [ id|property ], -#- closure => { fullname => { old_requested => bool, unsatisfied => [ id|property ] } } } } }, -#- -#- whatrequires => { name => { id => undef } }, -#- # reversed requires_nosense for selected packages -#- -#- # more fields only used in build_transaction_set and its callers) -#- transaction => [ { upgrade => [ id ], remove => [ fullname ] } ], -#- transaction_state => state_object, - sub property2name { $_[0] =~ /^([^\s\[]*)/ && $1; } |