prt-auf: report the targets omitted from an install transaction
This commit is contained in:
parent
0c301f6387
commit
dff03f9b00
@ -160,9 +160,9 @@ if (($action =~ /^(listinst|listorphans|dependent)/)
|
|||||||
} elsif ($action =~ /^(install|sysup)$/) {
|
} elsif ($action =~ /^(install|sysup)$/) {
|
||||||
my @ok = @{$results[0]}; my %ok_pre = %{$results[1]};
|
my @ok = @{$results[0]}; my %ok_pre = %{$results[1]};
|
||||||
my %ok_post = %{$results[2]}; my @ok_readme = @{$results[3]};
|
my %ok_post = %{$results[2]}; my @ok_readme = @{$results[3]};
|
||||||
my @not_ok = @{$results[4]}; my $note;
|
my @not_ok = @{$results[4]}; my @missing = @{$results[5]}; my $note;
|
||||||
if ($opkg{test} eq "yes") {
|
if ($opkg{test} eq "yes") {
|
||||||
print "\n$action successful.\n";
|
print "\n$action successful.\n" unless ((@not_ok) or (@missing));
|
||||||
print "*** prt-auf: test mode end\n\n";
|
print "*** prt-auf: test mode end\n\n";
|
||||||
}
|
}
|
||||||
if (($opkg{test} eq "no") and (@ok)) {
|
if (($opkg{test} eq "no") and (@ok)) {
|
||||||
@ -175,13 +175,17 @@ if (($action =~ /^(listinst|listorphans|dependent)/)
|
|||||||
print "\n";
|
print "\n";
|
||||||
}
|
}
|
||||||
if (@ok_readme) {
|
if (@ok_readme) {
|
||||||
print "Ports with README files:\n";
|
print "Ports with README files:\n ";
|
||||||
print join("\n ", @ok_readme); print "\n";
|
print join("\n ", @ok_readme); print "\n";
|
||||||
}
|
}
|
||||||
if (@not_ok) {
|
if (@not_ok) {
|
||||||
print "Ports with pkgmk/pkgadd failures:\n";
|
print "Ports with pkgmk/pkgadd failures:\n ";
|
||||||
print join("\n ", @not_ok); print "\n";
|
print join("\n ", @not_ok); print "\n";
|
||||||
}
|
}
|
||||||
|
if (@missing) {
|
||||||
|
print "Ports not found in the repositories:\n ";
|
||||||
|
print join("\n ", @missing); print "\n";
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
# Done!
|
# Done!
|
||||||
@ -750,10 +754,10 @@ sub deporder { # returns a sorted list of packages required.
|
|||||||
return @result;
|
return @result;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub up_inst { # returns scalar references to five arrays
|
sub up_inst { # returns scalar references to six arrays
|
||||||
my @requested=@_; my @sortedList; my @targets; my %pdirs; my %builtpkg;
|
my @requested=@_; my @sortedList; my @targets; my %pdirs; my %builtpkg;
|
||||||
my %mkcmd; my %addcmd; my $rs_cmd; my %logfile; my %pvars; my $status;
|
my %mkcmd; my %addcmd; my $rs_cmd; my %logfile; my %pvars; my $status;
|
||||||
my %ok; my %not_ok; my %ok_pre; my %ok_post; my @ok_readme=();
|
my %ok; my @missing; my %not_ok; my %ok_pre; my %ok_post; my @ok_readme=();
|
||||||
my $PKGMK=$opkg{makecommand}; my $PKGADD=$opkg{addcommand};
|
my $PKGMK=$opkg{makecommand}; my $PKGADD=$opkg{addcommand};
|
||||||
my $SH=$opkg{scriptcommand};
|
my $SH=$opkg{scriptcommand};
|
||||||
|
|
||||||
@ -766,6 +770,7 @@ sub up_inst { # returns scalar references to five arrays
|
|||||||
} else {
|
} else {
|
||||||
@targets = grep { ($V_REPO{$_}) } @requested;
|
@targets = grep { ($V_REPO{$_}) } @requested;
|
||||||
}
|
}
|
||||||
|
@missing = grep { (! $V_REPO{$_}) } @requested;
|
||||||
|
|
||||||
# omit the ports that appear up to date, unless a rebuild is forced
|
# omit the ports that appear up to date, unless a rebuild is forced
|
||||||
if ("$opkg{margs} $opkg{aargs}" !~ m/-f/) {
|
if ("$opkg{margs} $opkg{aargs}" !~ m/-f/) {
|
||||||
@ -865,7 +870,7 @@ sub up_inst { # returns scalar references to five arrays
|
|||||||
}
|
}
|
||||||
|
|
||||||
my @ok = keys %ok; my @not_ok = keys %not_ok;
|
my @ok = keys %ok; my @not_ok = keys %not_ok;
|
||||||
return \@ok, \%ok_pre, \%ok_post, \@ok_readme, \@not_ok;
|
return \@ok, \%ok_pre, \%ok_post, \@ok_readme, \@not_ok, \@missing;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub parse_pkgmk_conf {
|
sub parse_pkgmk_conf {
|
||||||
@ -879,8 +884,9 @@ sub parse_pkgmk_conf {
|
|||||||
while (<CF>) { @pkgmkVars = split /:/;
|
while (<CF>) { @pkgmkVars = split /:/;
|
||||||
} close (CF);
|
} close (CF);
|
||||||
|
|
||||||
my $COMPRESSION = ($pkgmkVars[1] eq "") ? "gz" : $pkgmkVars[1];
|
my $COMPRESSION = ($pkgmkVars[1]) ? $pkgmkVars[1] : "gz";
|
||||||
return $COMPRESSION, $pkgmkVars[0];
|
my $PKGDIR = ($pkgmkVars[0]) ? $pkgmkVars[0] : "";
|
||||||
|
return $COMPRESSION, $PKGDIR;
|
||||||
}
|
}
|
||||||
|
|
||||||
sub port_ls {
|
sub port_ls {
|
||||||
|
Loading…
Reference in New Issue
Block a user