From: DongHun Kwak Date: Fri, 27 Nov 2020 06:49:01 +0000 (+0900) Subject: Imported Upstream version 17.23.6 X-Git-Tag: upstream/17.23.6^0 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=50de52ddf03619f5d8210491138b6ce8cb369470;p=platform%2Fupstream%2Flibzypp.git Imported Upstream version 17.23.6 --- diff --git a/VERSION.cmake b/VERSION.cmake index 460c93a..b41d44a 100644 --- a/VERSION.cmake +++ b/VERSION.cmake @@ -61,8 +61,8 @@ SET(LIBZYPP_MAJOR "17") SET(LIBZYPP_COMPATMINOR "22") SET(LIBZYPP_MINOR "23") -SET(LIBZYPP_PATCH "5") +SET(LIBZYPP_PATCH "6") # -# LAST RELEASED: 17.23.5 (22) +# LAST RELEASED: 17.23.6 (22) # (The number in parenthesis is LIBZYPP_COMPATMINOR) #======= diff --git a/libzypp.spec.cmake b/libzypp.spec.cmake index 16a47fc..cf444d5 100644 --- a/libzypp.spec.cmake +++ b/libzypp.spec.cmake @@ -18,12 +18,8 @@ %if 0%{?is_opensuse} && (0%{?sle_version} >= 150100 || 0%{?suse_version} > 1500) %bcond_without zchunk %else -%if 0%{?sle_version} >= 150200 -%bcond_without zchunk -%else %bcond_with zchunk %endif -%endif %bcond_without mediabackend_tests diff --git a/package/libzypp.changes b/package/libzypp.changes index 823f674..66a4727 100644 --- a/package/libzypp.changes +++ b/package/libzypp.changes @@ -1,4 +1,10 @@ ------------------------------------------------------------------- +Thu Jun 4 11:45:03 CEST 2020 - ma@suse.de + +- Revert "Enable zchunk on SLE-15-SP2". +- version 17.23.6 (22) + +------------------------------------------------------------------- Wed May 27 18:50:32 CEST 2020 - ma@suse.de - Enable zchunk on SLE-15-SP2. diff --git a/tools/zypp-NameReqPrv.cc b/tools/zypp-NameReqPrv.cc index 19aab32..6568cad 100644 --- a/tools/zypp-NameReqPrv.cc +++ b/tools/zypp-NameReqPrv.cc @@ -86,15 +86,19 @@ struct PQSort struct Table { - void row( PoolQuery::const_iterator it_r ) + std::vector & row( const sat::Solvable & solv_r ) { //smax( _maxSID, ); - smax( _maxNAME, it_r->ident().size() + it_r->edition().size() + it_r->arch().size() ); - smax( _maxREPO, it_r->repository().name().size(), it_r->repository().name() ); + smax( _maxNAME, solv_r.ident().size() + solv_r.edition().size() + solv_r.arch().size() ); + smax( _maxREPO, solv_r.repository().name().size(), solv_r.repository().name() ); //smax( _maxTIME, ); - //smax( _maxVEND, it_r->vendor().size() ); + //smax( _maxVEND, solv_r.vendor().size() ); + return _map[solv_r]; + } - std::vector & details { _map[*it_r] }; + void row( PoolQuery::const_iterator it_r ) + { + std::vector & details { row( *it_r ) }; for_( match, it_r.matchesBegin(), it_r.matchesEnd() ) { details.push_back( match->inSolvAttr().asString().substr( 9, 3 )+": " +match->asString() ); } @@ -178,6 +182,75 @@ void dDump( const std::string & spec_r ) message << endl << "}" << endl; } +/////////////////////////////////////////////////////////////////// + +void dTree( const std::string & cmd_r, const std::string & spec_r ) +{ + message << "tree " << spec_r << " {"; + + sat::WhatProvides spec( Capability::guessPackageSpec( spec_r ) ); + if ( spec.empty() ) + { + message << "}" << endl; + return; + } + + static const std::list attrs { + sat::SolvAttr::requires, + sat::SolvAttr::recommends, + sat::SolvAttr::obsoletes, + sat::SolvAttr::conflicts, + sat::SolvAttr::supplements, + }; + + std::map>> result; // solvables recommending provided capability + { + Table t; + for ( const auto & el : spec ) + { + auto & details { t.row( el ) }; + for ( const auto & cap : el.provides() ) + { + //details.push_back( "prv: "+cap.asString() ); // list only matching ones + + // get attrs matching cap + for ( const auto & attr : attrs ) + { + PoolQuery q; + q.addDependency( attr, cap ); + if ( q.empty() ) + continue; + for_( it, q.begin(), q.end() ) { + for_( match, it.matchesBegin(), it.matchesEnd() ) { + result[attr][*it].insert( match->inSolvAttr().asString().substr( 9, 3 )+": " +match->asString() + + " (" + cap.asString() + ")" + ); + } + } + } + } + } + message << endl << t; + } + + for ( const auto & attr : attrs ) + { + if ( result[attr].empty() ) + continue; + + message << endl << "======== " << attr << " by:" << endl; + Table t; + for ( const auto & el : result[attr] ) + { + auto & details { t.row( el.first ) }; + for ( const auto & cap : el.second ) + details.push_back( cap ); + } + message << endl << t << endl; + } + message << "}" << endl; +} + /****************************************************************** ** ** FUNCTION NAME : main @@ -317,6 +390,16 @@ int main( int argc, char * argv[] ) else return errexit("-D requires an argument."); break; + case 'T': + if ( argc > 1 ) + { + std::string cmd { *argv }; + --argc,++argv; + dTree( cmd, *argv ); + } + else + return errexit("-T requires an argument."); + break; case 'i': ignorecase = true; break; case 'I': ignorecase = false; break; case 'x': matechexact = true; break; @@ -427,9 +510,7 @@ int main( int argc, char * argv[] ) continue; t.row( it ); } - message << t << endl; - - message << "}" << endl; + message << t << "}" << endl; } INT << "===[END]============================================" << endl << endl;