autounmask should be able to handle @sets, but only checks to see if what is passed to it is a true package. This patch adds the check, so autounmask @kde, or @world will now work. Reproducible: Always Steps to Reproduce: 1. autounmask @world Actual Results: can't find package @world Expected Results: <list of things being unmasked> --- /usr/bin/autounmask 2009-11-07 16:22:57.000000000 +1000 +++ autounmask 2009-11-07 16:22:43.000000000 +1000 @@ -47,6 +47,8 @@ my %buffers = (); my $pn = ''; +my $isSet = 0; + # - signal handler > $SIG{'INT'} = 'INT_handler'; $SIG{'HUP'} = 'INT_handler'; @@ -119,6 +121,23 @@ } } } + +# check to see if we have bee asked to emerge a set +if (index($packageToUnmask, '@')>-1) { + print "set specified, checking for validity\n"; + my $emergeSetsList=`emerge @ 2>&1`; + my $sets= substr($emergeSetsList, 67); + my $setToEmerge = substr($packageToUnmask, 2); + if(index($sets,$setToEmerge)>-1) { + $isOk=1; + $isSet=1; + } + +} + if (!$isOk) { $packageToUnmask.='-'; # Need this if no version is given. my $ebuildName=$pxs->getEbuildName($packageToUnmask); @@ -196,8 +215,14 @@ print "\n"; $pxs->print_ok('Unmasking '.$packageToUnmask." and its dependencies.. this might take a while..\n"); print "\n"; + +#needed because the script originally prepends an '=' to the package, which breaks if a set is asked for (=@world is not a package) +if(!$isSet) { + $packageToUnmask="=$packageToUnmask"; +} + do { - $r=`NOCOLOR=true emerge -pe =$packageToUnmask`; + $r=`NOCOLOR=true emerge -pe $packageToUnmask`; @l=split(/\n/,$r); undef $p;
*** Bug 323375 has been marked as a duplicate of this bug. ***
package no longer in tree