my($lastmsg, %n_state, $total, %n_builder, $pu_total);
$pu_total = 0;
-$n_state{"Installed"} = 0;
-open( PIPE, "wanna-build --database=$arch/build-db --dist=$dist --list=all |" )
+$n_state{"Installed"} = 0;
+open( my $pipe, '-|', "wanna-build -A $arch --dist=$dist --list=all" )
or die "Cannot spawn wanna-build: $!\n";
-while( <PIPE> ) {
+while( <$pipe> ) {
if (/^Database for $dist doesn't exist$/) {
last;
}
}
$lastmsg = $_;
}
-close( PIPE );
+close( $pipe );
if ($?) {
print ", 0, 0";
} else {
# $total -= $n_state{"Not-For-Us"};
+ $total -= $n_state{"Auto-Not-For-Us"};
if ( $previously_built ) {
print ", ".$n_state{"Installed"}.", ".$pu_total;
} else {