From 23d06ec1f05d7dbb3d3250de9e229721163cd6b5 Mon Sep 17 00:00:00 2001 From: John McQuah Date: Tue, 14 Jun 2022 07:18:35 -0400 Subject: [PATCH] prt-auf: revised the lines that modify {} in up_inst() --- scripts/prt-auf | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/scripts/prt-auf b/scripts/prt-auf index 0de6387..d0ce492 100755 --- a/scripts/prt-auf +++ b/scripts/prt-auf @@ -652,7 +652,7 @@ sub up_inst { # returns scalar references to five arrays; my @targets=($type eq "grpinst") ? @_ : deporder("quickdep",@_); # filter out the invalid ports if deporder() didn't do so already - @targets = grep { (join " ", @allports) =~ / $_ / } @targets if ($type eq "grpinst"); + @targets = grep { (join " ", @allports) =~ /$_/ } @targets if ($type eq "grpinst"); # exempt any locked ports from an sysup operation %EXEMPT = map { $_ => 1 } @LOCKED; @@ -667,7 +667,7 @@ sub up_inst { # returns scalar references to five arrays; my %pdirs; my %builtpkg; my %mkcmd; my %addcmd; my %status; foreach my $t (@targets) { $opkg{$t} = $opkg{margs}; - $opkg{$t} =~ s/-f// if !(grep /$t/, @requested); + $opkg{$t} =~ s/-f// unless ($WANTED{$t}); $pdirs{$t} = find_port_by_name($t,1,1,0); $builtpkg{$t} = find_built_pkg($t); $mkcmd{$t} = "$PKGMK -d $opkg{$t}"; @@ -680,10 +680,10 @@ sub up_inst { # returns scalar references to five arrays; if (who_aliased_to($t)) { $mkcmd{$t} = "echo \"skipped build ($t provided by an alias)\""; } else { - $mkcmd{$t} = "" if ((port_diff("utd",$t)==0) and ($opkg{margs} !~ /-f/)); + $mkcmd{$t} = "" if ((port_diff("utd",$t)==0) and !($WANTED{$t})); $mkcmd{$t} = "" if (($type eq "install") and ($V_INST{$t}) and ($opkg{$t} !~ /-f/)); $mkcmd{$t} = "echo \"skipped build ($t up to date)\"" if ((-f $builtpkg{$t}) and - ((-M $builtpkg{$t}) < (-M "$pdirs{$t}/Pkgfile"))); + ((-M $builtpkg{$t}) < (-M "$pdirs{$t}/Pkgfile")) and ($opkg{$t} !~ /-f/)); } if ($mkcmd{$t}) {