Index: trunk/tools/ts-specs/TSpca.spec |
— | — | @@ -2,7 +2,7 @@ |
3 | 3 | |
4 | 4 | Name: TSpca |
5 | 5 | Summary: Patch Check Advanced |
6 | | -Version: 20080911-01 |
| 6 | +Version: 20081218-01 |
7 | 7 | Source1: pca |
8 | 8 | |
9 | 9 | SUNW_BaseDir: %{_basedir} |
Index: trunk/tools/ts-specs/ext-sources/pca |
— | — | @@ -8,7 +8,7 @@ |
9 | 9 | # |
10 | 10 | # Author : Martin Paul <martin@par.univie.ac.at> |
11 | 11 | # Home : http://www.par.univie.ac.at/solaris/pca/ |
12 | | -my $version='20080911-01'; |
| 12 | +my $version='20081218-01'; |
13 | 13 | |
14 | 14 | use strict; |
15 | 15 | use Config; |
— | — | @@ -52,7 +52,7 @@ |
53 | 53 | "noreboot|n|||0|Install only patches which do not require a reboot", |
54 | 54 | "minage||i|DAYS|0|List only patches which are at least DAYS old", |
55 | 55 | "maxage||i|DAYS|0|List only patches which are at most DAYS old", |
56 | | - "syslog||s|TYPE||Log successful patch installs to syslog facility TYPE", |
| 56 | + "syslog||s|TYPE|daemon.notice|Log patch installs to syslog priority TYPE", |
57 | 57 | "nobackup|k|s@|ID||Do not back up files to be patched for patch ID", |
58 | 58 | "backdir|B|s|DIR||Saves patch backout data to DIR", |
59 | 59 | "safe|s|||0|Check locally modified files for safe patch installation", |
— | — | @@ -94,7 +94,7 @@ |
95 | 95 | use File::Copy; |
96 | 96 | |
97 | 97 | # Variable declarations |
98 | | -my (%o, %input, %p, %pkgs, %u, %c, %locks, %rloop); |
| 98 | +my (%o, %input, %p, %pkgs, %u, %c, %locks, %rloop, %x, %pkga); |
99 | 99 | my (@plist, @slist, @rlist); |
100 | 100 | my $conf_dbg=''; my %conf_read; |
101 | 101 | my $dlfile=''; |
— | — | @@ -106,6 +106,8 @@ |
107 | 107 | my $download_start; |
108 | 108 | my $stopreached=0; |
109 | 109 | my $wgetv=''; |
| 110 | +my $agesum=0; |
| 111 | +my $xval=0; |
110 | 112 | |
111 | 113 | # Force flush to stdout right after every print command without "\n" |
112 | 114 | $|= 1; |
— | — | @@ -135,22 +137,23 @@ |
136 | 138 | push (@plist, $id); |
137 | 139 | } |
138 | 140 | do_patch_list(); |
139 | | - exit 0; |
| 141 | + exit $xval; |
140 | 142 | } |
141 | 143 | |
142 | 144 | get_current_xref(); |
143 | | -if (!$o{list} && !$o{download} && !$o{install} && !$o{readme}) { exit 0 } |
| 145 | +if (!$o{list} && !$o{download} && !$o{install} && !$o{readme}) { exit $xval } |
144 | 146 | |
145 | 147 | get_uname(); |
146 | 148 | get_installed_packages(); |
147 | 149 | get_installed_patches(); |
148 | 150 | get_current_patches(); |
| 151 | +set_extra_req(); |
149 | 152 | create_patch_list(); |
150 | 153 | print_header(); |
151 | 154 | do_patch_list(); |
152 | 155 | print_footer(); |
153 | 156 | |
154 | | -exit 0; |
| 157 | +exit $xval; |
155 | 158 | |
156 | 159 | # Functions |
157 | 160 | |
— | — | @@ -232,7 +235,7 @@ |
233 | 236 | ($p{$id}{irev} ne "00") && ($pp="$id-$p{$id}{irev}"); |
234 | 237 | ($p{$id}{crev} ne "00") && ($pp="$id-$p{$id}{crev}"); |
235 | 238 | ($p{$id}{prev} ne "00") && ($pp="$id-$p{$id}{prev}"); |
236 | | - $pp || err ("Unknown patch-id $id"); |
| 239 | + $pp || errx ("Unknown patch-id $id"); |
237 | 240 | # Remember revised patch id for later use |
238 | 241 | $p{$id}{pp} = $pp; |
239 | 242 | if ($o{threads}) { |
— | — | @@ -255,7 +258,7 @@ |
256 | 259 | print_patch ($id); |
257 | 260 | } |
258 | 261 | if ($o{download} || $o{install}) { |
259 | | - out ('info', "\nDownloading $pp ($c{current}/$c{total})"); |
| 262 | + out ('info', "\nLooking for $pp ($c{current}/$c{total})"); |
260 | 263 | if ($o{threads}) { |
261 | 264 | { # wait for the first download worker to tell us it's ready... |
262 | 265 | lock $download_start; |
— | — | @@ -287,6 +290,7 @@ |
288 | 291 | install_patch($pp); |
289 | 292 | if (-x '/var/run/nopatch') { |
290 | 293 | `/var/run/nopatch`; |
| 294 | + $xval=3; |
291 | 295 | last |
292 | 296 | } |
293 | 297 | } |
— | — | @@ -310,10 +314,10 @@ |
311 | 315 | printf "Install Summary : %d total, %d successful, ", $c{total}, $c{inst}; |
312 | 316 | printf "%d skipped, %d failed\n", $c{skipinst}, $c{failinst}; |
313 | 317 | |
314 | | - if ($c{p_ci}) { out ('info', "\nReconfiguration reboot required (init 6)") } |
315 | | - elsif ($c{p_bi}) { out ('info', "\nReboot required (init 6)") } |
316 | | - elsif ($c{p_c }) { out ('info', "\nReconfiguration reboot recommended (init 6)") } |
317 | | - elsif ($c{p_b }) { out ('info', "\nReboot recommended (init 6)") } |
| 318 | + if ($c{p_ci}) { out ('info', "\nReconfiguration reboot required (init 6)"); $xval || ($xval=4) } |
| 319 | + elsif ($c{p_bi}) { out ('info', "\nReboot required (init 6)"); $xval || ($xval=4) } |
| 320 | + elsif ($c{p_c }) { out ('info', "\nReconfiguration reboot recommended (init 6)"); $xval || ($xval=5) } |
| 321 | + elsif ($c{p_b }) { out ('info', "\nReboot recommended (init 6)"); $xval || ($xval=5) } |
318 | 322 | } |
319 | 323 | if ($o{readme} && (@rlist)) { |
320 | 324 | system ("$pager @rlist"); |
— | — | @@ -336,8 +340,8 @@ |
337 | 341 | } elsif ($s =~ /(\d{6}-\d{2})\.(zip|jar|tar\.Z|tar)$/) { |
338 | 342 | push (@slist, $1); |
339 | 343 | } elsif (-f $s) { |
340 | | - if ($fc{$s}) { err ("Recursive file inclusion: $s") } else { $fc{$s}=1 } |
341 | | - open (LIST, "<$s") || err ("Can't open $s ($!)"); |
| 344 | + if ($fc{$s}) { errx ("Recursive file inclusion: $s") } else { $fc{$s}=1 } |
| 345 | + open (LIST, "<$s") || errx ("Can't open $s ($!)"); |
342 | 346 | while (<LIST>) { |
343 | 347 | chomp; |
344 | 348 | next unless $_; |
— | — | @@ -345,7 +349,7 @@ |
346 | 350 | $again=1; |
347 | 351 | } |
348 | 352 | } else { |
349 | | - err ("Unknown operand: $s"); |
| 353 | + errx ("Unknown operand: $s"); |
350 | 354 | } |
351 | 355 | } |
352 | 356 | @tlist=@slist; |
— | — | @@ -446,7 +450,7 @@ |
447 | 451 | } |
448 | 452 | } |
449 | 453 | $p{$id}{listed}=1; |
450 | | - push (@plist, $id); |
| 454 | + push (@plist, $id); $agesum+=calculateage($id); |
451 | 455 | return (1); |
452 | 456 | } |
453 | 457 | |
— | — | @@ -505,7 +509,7 @@ |
506 | 510 | # Ignore patches for foreign architectures. |
507 | 511 | $found=0; |
508 | 512 | foreach my $j (split (/\;/, $p{$id}{archs})) { |
509 | | - if (($j eq $u{arch}) || ($j eq "all") || ($j eq "Solaris") || ($j eq "$u{arch}.$u{model}")) { |
| 513 | + if (($j eq $u{arch}) || ($j eq "all") || ($j eq "$u{arch}.$u{model}")) { |
510 | 514 | $found=1; last; |
511 | 515 | } |
512 | 516 | } |
— | — | @@ -514,14 +518,18 @@ |
515 | 519 | # Ignore patches for packages that are not installed. |
516 | 520 | $found=0; |
517 | 521 | foreach my $j (split (/\;/, $p{$id}{pkgs})) { |
518 | | - my ($package, $version)= split (/:/, $j); |
519 | | - if ($pkgs{$package} && ($pkgs{$package} =~ /<$version>/)) { |
| 522 | + my ($package, $version)= split (/:/, $j, 2); |
| 523 | + next unless ($pkgs{$package}); |
| 524 | + my $iversion=$pkgs{$package}; |
| 525 | + $version =~ s/"/./g; $version =~ s/\(/./g; $version =~ s/\)/./g; |
| 526 | + $iversion=~ s/"/./g; $iversion=~ s/\(/./g; $iversion=~ s/\)/./g; |
| 527 | + if ($iversion =~ /<$version>/) { |
520 | 528 | $found=1; last; |
521 | 529 | } |
522 | 530 | } |
523 | 531 | if (!$found) { next; } |
524 | 532 | |
525 | | - if (!patch_apply_check($id)) { next; } |
| 533 | + if (!chk_extra_req($id)) { next; } |
526 | 534 | if (!check_rs($s,$id) && ($type != 5)) { next; } |
527 | 535 | |
528 | 536 | return (5); |
— | — | @@ -573,8 +581,8 @@ |
574 | 582 | if ($p{$id}{ignore} eq $p{$id}{crev}) { return 0 } |
575 | 583 | |
576 | 584 | # Check for minage, maxage and pattern |
577 | | - if (($o{minage}) && (calculateage($p{$id}{reldate}) < $o{minage})) { return(0); } |
578 | | - if (($o{maxage}) && (calculateage($p{$id}{reldate}) > $o{maxage})) { return(0); } |
| 585 | + if (($o{minage}) && (calculateage($id) < $o{minage})) { return(0); } |
| 586 | + if (($o{maxage}) && (calculateage($id) > $o{maxage})) { return(0); } |
579 | 587 | if ($o{pattern}) { |
580 | 588 | if ($o{pattern} =~ /^!/) { |
581 | 589 | my $pattern= substr ($o{pattern}, 1); |
— | — | @@ -591,27 +599,25 @@ |
592 | 600 | my $pp=$_[0]; |
593 | 601 | my ($id, $rev)= split (/-/, $pp); |
594 | 602 | |
595 | | - lock_free($o{patchdir}, "download.$pp", 300) || err ("Another instance of pca is downloading $pp to $o{patchdir} right now"); |
| 603 | + lock_free($o{patchdir}, "download.$pp", 300) || errx ("Another instance of pca is downloading $pp to $o{patchdir} right now"); |
596 | 604 | |
597 | 605 | # Check if patch exists |
598 | 606 | if (-d "$o{patchdir}/$pp") { |
599 | | - buffer_worker_out ($id, 'info', "Skipped (directory exists)"); $c{skipdl}++; return; |
| 607 | + buffer_worker_out ($id, 'info', "Found patch directory"); $c{skipdl}++; return; |
600 | 608 | } |
601 | 609 | foreach my $ext ('zip','jar','tar.Z','tar') { |
| 610 | + (-z "$o{patchdir}/$pp.$ext") && unlink "$o{patchdir}/$pp.$ext"; |
602 | 611 | if (-f "$o{patchdir}/$pp.$ext") { |
603 | | - if (-s "$o{patchdir}/$pp.$ext") { |
604 | | - buffer_worker_out ($id, 'info', "Skipped (file exists)"); $c{skipdl}++; return; |
605 | | - } |
606 | | - unlink "$o{patchdir}/$pp.$ext"; |
| 612 | + buffer_worker_out ($id, 'info', "Found patch file"); $c{skipdl}++; return; |
607 | 613 | } |
608 | 614 | } |
609 | 615 | |
610 | 616 | # Remember if we downloaded the patch for install only |
611 | 617 | $o{download} || ($p{$id}{dfori}=1); |
612 | 618 | |
613 | | - (-w $o{patchdir}) || err ("Can't write to patch download directory $o{patchdir}"); |
| 619 | + (-w $o{patchdir}) || errx ("Can't write to patch download directory $o{patchdir}"); |
614 | 620 | |
615 | | - lock_create($o{patchdir}, "download.$pp", 1) || err ("Another instance of pca is downloading $pp to $o{patchdir} right now"); |
| 621 | + lock_create($o{patchdir}, "download.$pp", 1) || errx ("Another instance of pca is downloading $pp to $o{patchdir} right now"); |
616 | 622 | |
617 | 623 | # Try to get patch from local patch server |
618 | 624 | if ($o{patchurl} =~ /^file:/) { |
— | — | @@ -734,10 +740,11 @@ |
735 | 741 | sub filetype { |
736 | 742 | my $fname=$_[0]; my $buffer; |
737 | 743 | |
738 | | - open (F, "< $fname") || err ("Can't open $fname ($!)"); |
739 | | - read F, $buffer, 1024; |
| 744 | + open (F, "< $fname") || errx ("Can't open $fname ($!)"); |
| 745 | + my $size=read (F, $buffer, 512); |
740 | 746 | close (F); |
741 | 747 | |
| 748 | + if ($size != 512) { dbg ("Short file: $fname"); return ('unknown') } |
742 | 749 | if (substr($buffer, 257, 5) eq "ustar") { return ('tar') } |
743 | 750 | if (substr($buffer, 0, 2) eq "\037\235") { return ('tar.Z') } |
744 | 751 | if (substr($buffer, 0, 4) eq "PK\003\004") { |
— | — | @@ -757,7 +764,7 @@ |
758 | 765 | my $opt=''; |
759 | 766 | |
760 | 767 | $patchxdir= "$o{tmpdir}/pca." . time() . $$; |
761 | | - mkdir $patchxdir,0755 || err ("Can't create temporary directory $patchxdir ($!)"); |
| 768 | + mkdir $patchxdir,0755 || errx ("Can't create temporary directory $patchxdir ($!)"); |
762 | 769 | |
763 | 770 | if (-d "$o{patchdir}/$pp") { |
764 | 771 | $?= !symlink ("$o{patchdir}/$pp", "$patchxdir/$pp"); |
— | — | @@ -801,7 +808,7 @@ |
802 | 809 | # Do we need a reboot? |
803 | 810 | my $p_b=0; my $p_bi=0; my $p_c=0; my $p_ci=0; |
804 | 811 | if (-f $patchinfo) { |
805 | | - open(PATCHINFO,$patchinfo) || err ("Can't open $patchinfo ($!)"); |
| 812 | + open(PATCHINFO,$patchinfo) || errx ("Can't open $patchinfo ($!)"); |
806 | 813 | dbg ("Checking for reboot/reconfig in patchinfo"); |
807 | 814 | while (<PATCHINFO>) { |
808 | 815 | if (/PATCH_PROPERTIES=.*reconfigimmediate/) { $p_ci=1; last } |
— | — | @@ -811,7 +818,7 @@ |
812 | 819 | } |
813 | 820 | close PATCHINFO; |
814 | 821 | } elsif (-f $readme) { |
815 | | - open(README,$readme) || err ("Can't open $readme ($!)"); |
| 822 | + open(README,$readme) || errx ("Can't open $readme ($!)"); |
816 | 823 | dbg ("Checking for reboot/reconfig in README"); |
817 | 824 | while(<README>) { |
818 | 825 | if (/Reconfig.*immediate.*after.*install/) { $p_ci=1; last } |
— | — | @@ -825,7 +832,7 @@ |
826 | 833 | # If the patchadd command doesn't exist, try installpatch, which |
827 | 834 | # comes with patches for Solaris <= 2.5.1. |
828 | 835 | (-x $o{patchadd}) || ($o{patchadd}="$patchxdir/$pp/installpatch"); |
829 | | - (-x $o{patchadd}) || err ("Can't execute patchadd/installpatch"); |
| 836 | + (-x $o{patchadd}) || errx ("Can't execute patchadd/installpatch"); |
830 | 837 | |
831 | 838 | # Sun Studio 11 patches on Solaris 10 must be installed with -G |
832 | 839 | # Patches 119254-34 and 119255-34 fix this in patchadd |
— | — | @@ -844,7 +851,7 @@ |
845 | 852 | } elsif ($o{pretend}) { |
846 | 853 | out ('info', "Skipping patchadd (pretend)"); $c{skipinst}++; |
847 | 854 | } else { |
848 | | - lock_create($o{tmpdir}, "install", 1) || err ("Another instance of pca is installing patches right now"); |
| 855 | + lock_create($o{tmpdir}, "install", 1) || errx ("Another instance of pca is installing patches right now"); |
849 | 856 | $o{currentzone} && ($opt .= "-G "); |
850 | 857 | if (($o{nobackup} =~ /all/) || ($p{$id}{nobackup} eq "00") || ($p{$id}{nobackup} eq $p{$id}{crev})) { $opt .= "-d " } |
851 | 858 | $o{backdir} && ($opt .= "-B $o{backdir} "); |
— | — | @@ -943,9 +950,9 @@ |
944 | 951 | open (F, "<$odir/$f"); read (F, my $content, $size); close (F); |
945 | 952 | print $content; |
946 | 953 | } else { |
947 | | - err ("$f not found"); |
| 954 | + errx ("$f not found"); |
948 | 955 | } |
949 | | - exit 0; |
| 956 | + exit $xval; |
950 | 957 | } |
951 | 958 | |
952 | 959 | sub checksoa { |
— | — | @@ -984,10 +991,10 @@ |
985 | 992 | sub check_prerequisites { |
986 | 993 | # Must be root to install patches |
987 | 994 | if ($o{install} && ($< != 0) && !$o{pretend}) { |
988 | | - err ("You must be root to install patches"); |
| 995 | + errx ("You must be root to install patches"); |
989 | 996 | } |
990 | 997 | if ($o{install} && $o{safe} && !$o{proxy} && ($< != 0)) { |
991 | | - err ("You must be root to use safe mode"); |
| 998 | + errx ("You must be root to use safe mode"); |
992 | 999 | } |
993 | 1000 | |
994 | 1001 | # Set umask (esp. for patchxdir) |
— | — | @@ -1011,7 +1018,7 @@ |
1012 | 1019 | $input{xref}="$o{xrefdir}/patchdiag.xref"; |
1013 | 1020 | |
1014 | 1021 | # Check patch download directory |
1015 | | - (-d $o{patchdir}) || err ("Can't find patch directory $o{patchdir}"); |
| 1022 | + (-d $o{patchdir}) || errx ("Can't find patch directory $o{patchdir}"); |
1016 | 1023 | |
1017 | 1024 | # Check for pager |
1018 | 1025 | $ENV{PAGER} && ($pager=$ENV{PAGER}); |
— | — | @@ -1031,7 +1038,7 @@ |
1032 | 1039 | $input{showrev}= "<$o{fromfiles}/showrev.out"; |
1033 | 1040 | $input{uname} = "<$o{fromfiles}/uname.out"; |
1034 | 1041 | } else { |
1035 | | - err ("Can't find pkginfo/showrev/uname output with prefix $o{fromfiles}"); |
| 1042 | + errx ("Can't find pkginfo/showrev/uname output with prefix $o{fromfiles}"); |
1036 | 1043 | } |
1037 | 1044 | dbg ("Using $o{fromfiles} as prefix to read .out files"); |
1038 | 1045 | } else { |
— | — | @@ -1139,6 +1146,7 @@ |
1140 | 1147 | $wl{120346}="/etc/hba.conf"; |
1141 | 1148 | $wl{120410}="/etc/gtk-2.0/gtk.immodules /etc/sparcv9/gtk-2.0/gtk.immodules"; |
1142 | 1149 | $wl{120460}="/etc/gtk-2.0/gtk.immodules /etc/sparcv9/gtk-2.0/gtk.immodules"; |
| 1150 | + $wl{121308}="/usr/sadm/lib/smc/policy/smcconsole.policy"; |
1143 | 1151 | $wl{121430}="/etc/default/lu"; |
1144 | 1152 | $wl{122212}="/etc/gconf/gconf.xml.defaults/apps/panel/default_setup/general/%gconf.xml"; |
1145 | 1153 | $wl{124393}="/etc/security/auth_attr /etc/security/prof_attr"; |
— | — | @@ -1146,6 +1154,7 @@ |
1147 | 1155 | $wl{127127}="/etc/krb5/krb5.conf /etc/logadm.conf /etc/pam.conf /etc/security/audit_warn /etc/security/auth_attr /etc/security/prof_attr /etc/shadow /etc/user_attr /kernel/drv/mpt.conf"; |
1148 | 1156 | $wl{127755}="/etc/logadm.conf"; |
1149 | 1157 | $wl{137093}="/etc/logindevperm"; |
| 1158 | + $wl{137137}="/etc/vfstab"; |
1150 | 1159 | $wl{137274}="/etc/mnttab"; |
1151 | 1160 | # 10/x86 |
1152 | 1161 | $wl{118855}="/etc/logindevperm /etc/security/prof_attr /etc/vold.conf /lib/libc.so.1 /etc/security/device_policy /etc/ipf/pfil.ap /boot/solaris/devicedb/master"; |
— | — | @@ -1161,6 +1170,7 @@ |
1162 | 1171 | $wl{120347}="/etc/hba.conf"; |
1163 | 1172 | $wl{120411}="/etc/gtk-2.0/gtk.immodules /etc/amd64/gtk-2.0/gtk.immodules"; |
1164 | 1173 | $wl{120461}="/etc/gtk-2.0/gtk.immodules /etc/amd64/gtk-2.0/gtk.immodules"; |
| 1174 | + $wl{121309}="/usr/sadm/lib/smc/policy/smcconsole.policy"; |
1165 | 1175 | $wl{121431}="/etc/default/lu"; |
1166 | 1176 | $wl{122213}="/etc/gconf/gconf.xml.defaults/apps/panel/default_setup/general/%gconf.xml"; |
1167 | 1177 | $wl{124394}="/etc/security/auth_attr /etc/security/prof_attr"; |
— | — | @@ -1168,13 +1178,13 @@ |
1169 | 1179 | $wl{125216}="/etc/wgetrc"; |
1170 | 1180 | $wl{127128}="/etc/krb5/krb5.conf /etc/logadm.conf /etc/pam.conf /etc/security/audit_warn /etc/security/auth_attr /etc/security/prof_attr /etc/shadow /etc/user_attr /kernel/drv/mpt.conf"; |
1171 | 1181 | $wl{127756}="/etc/logadm.conf"; |
1172 | | - $wl{128307}="/etc/security/device_policy"; |
1173 | 1182 | $wl{137094}="/etc/logindevperm"; |
1174 | | - $wl{137112}="/lib/libc.so.1"; |
| 1183 | + $wl{137138}="/etc/vfstab /lib/libc.so.1"; |
1175 | 1184 | $wl{137275}="/etc/mnttab"; |
| 1185 | + $wl{138270}="/etc/security/device_policy"; |
1176 | 1186 | |
1177 | 1187 | (-f $readme) || return (1); |
1178 | | - open (README, "<$readme") || err ("Can't open $readme ($!)"); |
| 1188 | + open (README, "<$readme") || errx ("Can't open $readme ($!)"); |
1179 | 1189 | |
1180 | 1190 | FILE: while (<README>) { |
1181 | 1191 | next if ($_ !~ /Files included with this patch:/); |
— | — | @@ -1207,7 +1217,7 @@ |
1208 | 1218 | my $fc=$#tfiles; |
1209 | 1219 | ($fc >= 1023) && ($fc=1023); |
1210 | 1220 | my $pfile="$o{tmpdir}/pca.pkgchk." . time() . $$; |
1211 | | - open (PFILE, ">$pfile") || err ("Can't open $pfile ($!)"); |
| 1221 | + open (PFILE, ">$pfile") || errx ("Can't open $pfile ($!)"); |
1212 | 1222 | foreach my $f (@tfiles[0..$fc]) { print PFILE "$f\n" } |
1213 | 1223 | close PFILE; |
1214 | 1224 | $out .= `$pkgchk $o{root} -q -i $pfile 2>&1`; |
— | — | @@ -1223,312 +1233,227 @@ |
1224 | 1234 | return (1); |
1225 | 1235 | } |
1226 | 1236 | |
1227 | | -sub patch_apply_check { |
| 1237 | +sub set_extra_req { |
| 1238 | + $x{113039}=$x{113040}=$x{113041}=$x{113042}=$x{113043}=$x{111095}=$x{111096}=$x{111413}="rpkg=SUNWsan"; |
| 1239 | + $x{114046}=$x{119209}="rosrel=5.8"; |
| 1240 | + $x{114049}=$x{114050}=$x{119211}=$x{119212}="rosrel=5.9"; |
| 1241 | + $x{117765}=$x{117766}="rosrel=5.8"; $x{117767}=$x{117768}="rosrel=5.9"; |
| 1242 | + $x{114644}=$x{114645}=$x{114646}=$x{114647}=$x{114648}=$x{114649}="rosrel=5.8"; |
| 1243 | + $x{114650}=$x{114651}=$x{114652}=$x{114653}="rosrel=5.8"; |
| 1244 | + $x{114816}=$x{114817}=$x{115780}=$x{115781}=$x{117520}=$x{117521}="rosrel=5.8"; |
| 1245 | + $x{114686}=$x{114687}=$x{114688}=$x{114689}="rosrel=5.9"; |
| 1246 | + $x{114690}=$x{114691}=$x{114692}=$x{114693}=$x{114694}=$x{114695}="rosrel=5.9"; |
| 1247 | + $x{114818}=$x{114819}=$x{115782}=$x{115783}=$x{117526}=$x{117527}="rosrel=5.9"; |
| 1248 | + $x{114255}="rarch=sparc"; $x{114256}="rarch=i386"; |
| 1249 | + $x{115328}="rosrel=5.8"; |
| 1250 | + $x{115342}="rosrel=5.9"; |
| 1251 | + $x{115343}="rosrel=5.9"; |
| 1252 | + $x{119346}="rosrel=5.10"; |
| 1253 | + $x{115766}=$x{120879}=$x{120954}="rarch=sparc"; |
| 1254 | + $x{120091}=$x{120880}=$x{120955}="rarch=i386"; |
| 1255 | + $x{119300}="rosrel=5.8"; $x{119301}="rosrel=5.9"; $x{119302}="rosrel=5.10"; |
| 1256 | + $x{113434}="rpkg=SUNWwbsup"; |
| 1257 | + $x{109700}=$x{111248}="rosrel=5.6"; $x{109701}=$x{111249}="rosrel=5.7"; |
| 1258 | + $x{111250}="rosrel=5.8"; $x{115548}="rosrel=5.9"; |
| 1259 | + $x{123200}="rosrel=5.8"; $x{123201}="rosrel=5.9"; $x{123202}="rosrel=5.10"; |
| 1260 | + $x{119527}=$x{119530}=$x{119325}="rarch=sparc"; |
| 1261 | + $x{119528}=$x{119531}=$x{119326}="rarch=i386"; |
| 1262 | + $x{127498}=$x{127499}="rosrel=5.8"; |
| 1263 | + $x{136986}=$x{136987}="rosrel=5.8"; |
| 1264 | + $x{125950}=$x{125951}="rosrel=5.9"; |
| 1265 | + $x{125952}=$x{125953}="rosrel=5.10"; |
| 1266 | + $x{123827}="rosrel=5.8"; $x{123828}="rosrel=5.9"; $x{123829}="rosrel=5.10"; |
| 1267 | + $x{125760}="rosrel=5.8"; $x{125761}="rosrel=5.9"; $x{125762}="rosrel=5.10"; |
| 1268 | + $x{106514}=$x{108049}=$x{108879}=$x{109120}=$x{109413}="rarch=sparc"; |
| 1269 | + $x{117784}=$x{118195}=$x{118263}=$x{118950}=$x{123254}="rarch=sparc"; |
| 1270 | + $x{106515}=$x{108050}=$x{108881}=$x{109121}=$x{109414}="rarch=i386"; |
| 1271 | + $x{117785}=$x{118196}=$x{118264}=$x{118951}=$x{124590}="rarch=i386"; |
| 1272 | + $x{126356}="rarch=sparc"; $x{126357}="rarch=i386"; |
| 1273 | + $x{117429}="rosrel=5.9"; |
| 1274 | + $x{118386}="rosrel=5.6"; $x{118387}="rosrel=5.7"; $x{118388}="rosrel=5.8"; $x{118389}="rosrel=5.9"; |
| 1275 | + $x{118828}="rosrel=5.8"; $x{118829}="rosrel=5.9"; |
| 1276 | + $x{118836}="rosrel=5.6"; $x{118837}="rosrel=5.7"; $x{118838}="rosrel=5.8"; |
| 1277 | + $x{118839}="rosrel=5.9"; $x{118840}="rosrel=5.9"; |
| 1278 | + $x{120376}="rosrel=5.6"; $x{120377}="rosrel=5.7"; $x{120378}="rosrel=5.8"; $x{120379}="rosrel=5.9"; |
| 1279 | + $x{124689}="rosrel=5.8"; $x{124690}="rosrel=5.9"; |
| 1280 | + $x{111857}="rosrel=5.8"; $x{114176}="rosrel=5.9"; |
| 1281 | + $x{125445}="rosrel=5.9"; $x{125446}="rosrel=5.10"; |
| 1282 | + $x{127553}="rarch=sparc"; $x{127554}="rarch=i386"; |
| 1283 | + $x{121708}="rosrel=5.8"; $x{121709}="rosrel=5.9"; $x{121710}="rosrel=5.10"; |
| 1284 | + $x{125848}="rosrel=5.8"; $x{125849}="rosrel=5.9"; $x{125850}="rosrel=5.10"; |
| 1285 | + $x{115835}=$x{115836}="rpkgs=SUNWgscr"; |
| 1286 | + $x{108553}="rosrel=5.8"; |
| 1287 | + $x{125276}="rarch=sparc"; |
| 1288 | + $x{106533}="rplatform=SUNW,UltraSPARC-IIi-cEngine"; |
| 1289 | + $x{106629}="rplatform=CYRS,Superserver-6400"; |
| 1290 | + $x{116413}="rplatform=SUNW,Sun-Fire-15000"; |
| 1291 | + $x{125277}="rosrel=5.9:rarch=i386"; |
| 1292 | + $x{125278}="rosrel=5.10:rarch=i386"; |
| 1293 | + $x{124480}="rosrel=5.9:rarch=sparc"; |
| 1294 | + $x{124481}="rosrel=5.10:rarch=sparc"; |
| 1295 | + $x{124482}="rosrel=5.10:rarch=i386"; |
| 1296 | + $x{119380}="rosrel=5.8"; |
| 1297 | + $x{110936}=$x{110971}="rosrel=5.6"; |
| 1298 | + $x{110937}=$x{110972}="rosrel=5.7"; |
| 1299 | + $x{118386}="rosrel=5.6"; $x{118387}="rosrel=5.7"; $x{118388}="rosrel=5.8"; $x{118389}="rosrel=5.9"; |
| 1300 | + $x{118828}="rosrel=5.8"; $x{118829}="rosrel=5.9"; |
| 1301 | + $x{118836}="rosrel=5.6"; $x{118837}="rosrel=5.7"; $x{118838}="rosrel=5.8"; $x{118839}="rosrel=5.9"; |
| 1302 | + $x{127680}="rosrel=5.8"; $x{127681}=$x{127682}="rosrel=5.9"; $x{127683}=$x{127684}="rosrel=5.10"; |
| 1303 | + $x{138550}="rosrel=5.8"; $x{138551}=$x{138552}="rosrel=5.9"; $x{138553}=$x{138554}="rosrel=5.10"; |
| 1304 | +} |
| 1305 | + |
| 1306 | +sub chk_extra_req { |
1228 | 1307 | my $id=$_[0]; |
| 1308 | + my ($major, $minor) = split (/\./, $u{osrel}); |
1229 | 1309 | |
1230 | | - if ($id =~ /113039|113040|113041|113042|113043/) { |
1231 | | - if (!$pkgs{"SUNWsan"}) { return (0) } |
| 1310 | + if (exists $x{$id}) { |
| 1311 | + foreach my $i (split (/:/, $x{$id})) { |
| 1312 | + my ($opt, $val)=split(/=/, $i); |
| 1313 | + if (($opt eq "rarch") && ($val ne $u{arch})) { return 0 } |
| 1314 | + if (($opt eq "rosrel") && ($val ne $u{osrel})) { return 0 } |
| 1315 | + if (($opt eq "rplatform") && ($val ne $u{platform})) { return 0 } |
| 1316 | + if (($opt eq "rpkg") && !$pkgs{$val}) { return 0 } |
| 1317 | + } |
| 1318 | + return 1; |
1232 | 1319 | } |
1233 | 1320 | |
1234 | 1321 | if ($id eq "114045") { |
1235 | | - if ((exists $p{114049}) && ($p{114049}{irev} gt '03')) { return (0) } |
| 1322 | + if ((exists $p{114049}) && ($p{114049}{irev} gt '03')) { return 0 } |
1236 | 1323 | } |
1237 | | - |
1238 | | - if (($id =~ /114046|119209/) && ($u{osrel} ne "5.8")) { return (0) } |
1239 | | - if (($id =~ /114049|114050/) && ($u{osrel} ne "5.9")) { return (0) } |
1240 | | - if (($id =~ /119211|119212/) && ($u{osrel} ne "5.9")) { return (0) } |
1241 | | - |
1242 | 1324 | if ($id eq "114790") { |
1243 | | - if (!$pkgs{"SUNWdcar"} || $pkgs{"SUNWdcar"} !~ "<1.1.0,REV=2002.05.29.15.02>") { return (0) } |
1244 | | - if (!$pkgs{"SUNWcrypr"} || $pkgs{"SUNWcrypr"} !~ "<1.1.0,REV=2002.05.29.15.00>") { return (0) } |
| 1325 | + if (!$pkgs{"SUNWdcar"} || $pkgs{"SUNWdcar"} !~ "<1.1.0,REV=2002.05.29.15.02>") { return 0 } |
| 1326 | + if (!$pkgs{"SUNWcrypr"} || $pkgs{"SUNWcrypr"} !~ "<1.1.0,REV=2002.05.29.15.00>") { return 0 } |
1245 | 1327 | } |
1246 | | - |
1247 | | - if (($id =~ /117765|117766/) && ($u{osrel} ne "5.8")) { return (0) } |
1248 | | - if (($id =~ /117767|117768/) && ($u{osrel} ne "5.9")) { return (0) } |
1249 | | - |
1250 | 1328 | if ($id eq "113332") { |
1251 | | - if (($pkgs{"SUNWhea"}) || ($pkgs{"SUNWmdb"})) { return (1) } |
1252 | | - if (($u{model} eq 'sun4u') || ($u{model} eq 'sun4us')) { return (1) } |
1253 | | - return (0); |
| 1329 | + if (($pkgs{"SUNWhea"}) || ($pkgs{"SUNWmdb"})) { return 1 } |
| 1330 | + if (($u{model} eq 'sun4u') || ($u{model} eq 'sun4us')) { return 1 } |
| 1331 | + return 0; |
1254 | 1332 | } |
1255 | | - |
1256 | 1333 | if ($id =~ /115010|116478/) { |
1257 | | - if (($pkgs{"SUNWhea"}) || ($pkgs{"SUNWmdb"})) { return (1) } |
1258 | | - if ($u{model} eq 'sun4u') { return (1) } |
1259 | | - return (0); |
| 1334 | + if (($pkgs{"SUNWhea"}) || ($pkgs{"SUNWmdb"})) { return 1 } |
| 1335 | + if ($u{model} eq 'sun4u') { return 1 } |
| 1336 | + return 0; |
1260 | 1337 | } |
1261 | | - |
1262 | 1338 | if ($id =~ /109077|109078/) { |
1263 | | - if ((!$pkgs{"SUNWdhcm"}) && (!$pkgs{"SUNWdhcsu"})) { return (0) } |
1264 | | - if ($pkgs{"SUNWj3rt"}) { return (1) } |
1265 | | - return (0); |
| 1339 | + if ((!$pkgs{"SUNWdhcm"}) && (!$pkgs{"SUNWdhcsu"})) { return 0 } |
| 1340 | + if ($pkgs{"SUNWj3rt"}) { return 1 } |
| 1341 | + return 0; |
1266 | 1342 | } |
1267 | | - |
1268 | 1343 | if ($id =~ /118739|116706/) { |
1269 | | - if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.04.03.21.27>") { return (0) } |
| 1344 | + if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.04.03.21.27>") { return 0 } |
1270 | 1345 | } |
1271 | 1346 | if ($id =~ /118740|116707/) { |
1272 | | - if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.04.03.19.26>") { return (0) } |
| 1347 | + if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.04.03.19.26>") { return 0 } |
1273 | 1348 | } |
1274 | 1349 | if ($id eq "118741") { |
1275 | | - if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.11.11.23.55>") { return (0) } |
| 1350 | + if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.11.11.23.55>") { return 0 } |
1276 | 1351 | } |
1277 | 1352 | if ($id eq "118742") { |
1278 | | - if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.11.11.20.36>") { return (0) } |
| 1353 | + if (!$pkgs{"SUNWtsr"} || $pkgs{"SUNWtsr"} !~ "<2.5.0,REV=2003.11.11.20.36>") { return 0 } |
1279 | 1354 | } |
1280 | | - |
1281 | 1355 | if ($id eq "110692") { |
1282 | | - if ((exists $p{108806}) && ($p{108806}{irev} ge '01')) { return (0) } |
1283 | | - if ((exists $p{108806}) && ($p{108806}{crev} ge '01')) { return (0) } |
| 1356 | + if ((exists $p{108806}) && ($p{108806}{irev} ge '01')) { return 0 } |
| 1357 | + if ((exists $p{108806}) && ($p{108806}{crev} ge '01')) { return 0 } |
1284 | 1358 | } |
1285 | | - |
1286 | 1359 | if ($id eq "111412") { |
1287 | | - if (!$pkgs{"SUNWmdi"} || $pkgs{"SUNWmdi"} !~ "<11.8.0,REV=2001.01.19.01.02>") { return (0) } |
1288 | | - if (!$pkgs{"SUNWsan"}) { return (0) } |
| 1360 | + if (!$pkgs{"SUNWmdi"} || $pkgs{"SUNWmdi"} !~ "<11.8.0,REV=2001.01.19.01.02>") { return 0 } |
| 1361 | + if (!$pkgs{"SUNWsan"}) { return 0 } |
1289 | 1362 | } |
1290 | | - if ($id =~ /111095|111096|111413/) { |
1291 | | - if (!$pkgs{"SUNWsan"}) { return (0) } |
1292 | | - } |
1293 | 1363 | if ($id eq "111097") { |
1294 | | - if (!$pkgs{"SUNWsan"}) { return (0) } |
1295 | | - if (!$pkgs{"SUNWqlc"}) { return (0) } |
| 1364 | + if (!$pkgs{"SUNWsan"}) { return 0 } |
| 1365 | + if (!$pkgs{"SUNWqlc"}) { return 0 } |
1296 | 1366 | } |
1297 | | - |
1298 | 1367 | if ($id eq "111656") { |
1299 | | - if (!((exists $p{109460}) && ($p{109460}{irev} eq '05'))) { return (0) } |
| 1368 | + if (!((exists $p{109460}) && ($p{109460}{irev} eq '05'))) { return 0 } |
1300 | 1369 | } |
1301 | 1370 | if ($id eq "111658") { |
1302 | | - if (!((exists $p{107469}) && ($p{107469}{irev} eq '08'))) { return (0) } |
| 1371 | + if (!((exists $p{107469}) && ($p{107469}{irev} eq '08'))) { return 0 } |
1303 | 1372 | } |
1304 | 1373 | if ($id eq "111079") { |
1305 | | - if (!((exists $p{105375}) && ($p{105375}{irev} eq '26'))) { return (0) } |
| 1374 | + if (!((exists $p{105375}) && ($p{105375}{irev} eq '26'))) { return 0 } |
1306 | 1375 | } |
1307 | | - |
1308 | 1376 | if ($id eq "107474") { |
1309 | | - if ((exists $p{107292}) && ($p{107292}{irev} ge '02')) { return (1) } |
1310 | | - return (0); |
| 1377 | + if ((exists $p{107292}) && ($p{107292}{irev} ge '02')) { return 1 } |
| 1378 | + return 0; |
1311 | 1379 | } |
1312 | | - |
1313 | | - if ($id eq "106533") { |
1314 | | - if ($u{platform} ne 'SUNW,UltraSPARC-IIi-cEngine') { return (0) } |
1315 | | - } |
1316 | | - if ($id eq "106629") { |
1317 | | - if ($u{platform} ne 'CYRS,Superserver-6400') { return (0) } |
1318 | | - } |
1319 | | - if ($id eq "112780") { |
1320 | | - if (!($u{model} eq 'sun4u')) { return (0) } |
1321 | | - } |
| 1380 | + if (($id eq "112780") && !($u{model} eq 'sun4u')) { return 0 } |
1322 | 1381 | if ($id eq "112327") { |
1323 | | - if (($u{osrel} ne "5.6") && ($u{osrel} ne "5.7")) { return (0) } |
| 1382 | + if (($u{osrel} ne "5.6") && ($u{osrel} ne "5.7")) { return 0 } |
1324 | 1383 | } |
1325 | | - |
1326 | | - if ($id =~ /11464[456789]|11465[0123]|11481[67]|11578[01]|11752[01]/) { |
1327 | | - if ($u{osrel} ne "5.8") { return (0) } |
1328 | | - } |
1329 | | - if ($id =~ /11468[6789]|11469[012345]|11481[89]|11578[23]|11752[67]/) { |
1330 | | - if ($u{osrel} ne "5.9") { return (0) } |
1331 | | - } |
1332 | | - |
1333 | 1384 | if ($id eq "111891") { |
1334 | | - if (!$pkgs{"SUNWutr"} || $pkgs{"SUNWutr"} !~ "<1.3_12.c,REV=2001.07.16.20.52>") { return (0) } |
| 1385 | + if (!$pkgs{"SUNWutr"} || $pkgs{"SUNWutr"} !~ "<1.3_12.c,REV=2001.07.16.20.52>") { return 0 } |
1335 | 1386 | } |
1336 | | - |
1337 | | - if (($id eq "114255") && ($u{arch} ne "sparc")) { return (0) } |
1338 | | - if (($id eq "114256") && ($u{arch} ne "i386")) { return (0) } |
1339 | | - |
1340 | | - if (($id eq "115328") && ($u{osrel} ne "5.8")) { return (0) } |
1341 | | - if (($id eq "115342") && ($u{osrel} ne "5.9")) { return (0) } |
1342 | | - if (($id eq "115343") && ($u{osrel} ne "5.9")) { return (0) } |
1343 | | - if (($id eq "119346") && ($u{osrel} ne "5.10")) { return (0) } |
1344 | | - |
1345 | | - if (($id eq "115766") && ($u{arch} ne "sparc")) { return (0) } |
1346 | | - if (($id eq "120091") && ($u{arch} ne "i386")) { return (0) } |
1347 | | - if (($id eq "120879") && ($u{arch} ne "sparc")) { return (0) } |
1348 | | - if (($id eq "120880") && ($u{arch} ne "i386")) { return (0) } |
1349 | | - if (($id eq "120954") && ($u{arch} ne "sparc")) { return (0) } |
1350 | | - if (($id eq "120955") && ($u{arch} ne "i386")) { return (0) } |
1351 | | - |
1352 | | - if (($id =~ /115835|115836/) && (!$pkgs{"SUNWgscr"})) { return (0) } |
1353 | | - |
1354 | | - if (($id eq "119300") && ($u{osrel} ne "5.8")) { return (0) } |
1355 | | - if (($id eq "119301") && ($u{osrel} ne "5.9")) { return (0) } |
1356 | | - if (($id eq "119302") && ($u{osrel} ne "5.10")) { return (0) } |
1357 | | - |
1358 | 1387 | if ($id =~ /109357/) { |
1359 | | - if ((exists $p{109778}) && ($p{109778}{irev} ge '08')) { return (0) } |
1360 | | - if ((exists $p{109778}) && ($p{109778}{crev} ge '08')) { return (0) } |
| 1388 | + if ((exists $p{109778}) && ($p{109778}{irev} ge '08')) { return 0 } |
| 1389 | + if ((exists $p{109778}) && ($p{109778}{crev} ge '08')) { return 0 } |
1361 | 1390 | } |
1362 | | - if (($id eq "113434") && (!$pkgs{"SUNWwbsup"})) { return (0) } |
1363 | | - |
1364 | | - if (($id eq "109700") && ($u{osrel} ne "5.6")) { return (0) } |
1365 | | - if (($id eq "109701") && ($u{osrel} ne "5.7")) { return (0) } |
1366 | | - if (($id eq "111248") && ($u{osrel} ne "5.6")) { return (0) } |
1367 | | - if (($id eq "111249") && ($u{osrel} ne "5.7")) { return (0) } |
1368 | | - if (($id eq "111250") && ($u{osrel} ne "5.8")) { return (0) } |
1369 | | - if (($id eq "115548") && ($u{osrel} ne "5.9")) { return (0) } |
1370 | | - |
1371 | | - if (($id eq "108553") && ($u{osrel} ne "5.8")) { return (0) } |
1372 | | - if (($id eq "108834") && (($u{osrel} ne "5.5.1") || ($u{osrel} ne "5.6") || ($u{osrel} ne "5.7"))) { return (0) } |
1373 | | - if (($id eq "112125") && (($u{osrel} ne "5.6") || ($u{osrel} ne "5.7"))) { return (0) } |
1374 | | - if (($id eq "112126") && (($u{osrel} ne "5.8") || ($u{osrel} ne "5.9"))) { return (0) } |
1375 | | - |
1376 | | - if (($id eq "123200") && ($u{osrel} ne "5.8")) { return (0) } |
1377 | | - if (($id eq "123201") && ($u{osrel} ne "5.9")) { return (0) } |
1378 | | - if (($id eq "123202") && ($u{osrel} ne "5.10")) { return (0) } |
1379 | | - |
1380 | | - if (($id eq "119527") && ($u{arch} ne "sparc")) { return (0) } |
1381 | | - if (($id eq "119528") && ($u{arch} ne "i386")) { return (0) } |
1382 | | - if (($id eq "119530") && ($u{arch} ne "sparc")) { return (0) } |
1383 | | - if (($id eq "119531") && ($u{arch} ne "i386")) { return (0) } |
1384 | | - if (($id eq "119325") && ($u{arch} ne "sparc")) { return (0) } |
1385 | | - if (($id eq "119326") && ($u{arch} ne "i386")) { return (0) } |
1386 | | - |
1387 | | - if (($id eq "127498") && ($u{osrel} ne "5.8")) { return (0) } |
1388 | | - if (($id eq "127499") && ($u{osrel} ne "5.8")) { return (0) } |
1389 | | - |
1390 | | - if (($id eq "136986") && ($u{osrel} ne "5.8")) { return (0) } |
1391 | | - if (($id eq "136987") && ($u{osrel} ne "5.8")) { return (0) } |
1392 | | - if (($id eq "125950") && ($u{osrel} ne "5.9")) { return (0) } |
1393 | | - if (($id eq "125951") && ($u{osrel} ne "5.9")) { return (0) } |
1394 | | - if (($id eq "125952") && ($u{osrel} ne "5.10")) { return (0) } |
1395 | | - if (($id eq "125953") && ($u{osrel} ne "5.10")) { return (0) } |
1396 | | - |
1397 | | - if (($id eq "121430") && ($p{121430}{crev} ge '16') && (!$pkgs{"SUNWlucfg"})) { return (0) } |
1398 | | - if (($id eq "121431") && ($p{121431}{crev} ge '17') && (!$pkgs{"SUNWlucfg"})) { return (0) } |
| 1391 | + if (($id eq "108834") && (($u{osrel} ne "5.5.1") || ($u{osrel} ne "5.6") || ($u{osrel} ne "5.7"))) { return 0 } |
| 1392 | + if (($id eq "112125") && (($u{osrel} ne "5.6") || ($u{osrel} ne "5.7"))) { return 0 } |
| 1393 | + if (($id eq "112126") && (($u{osrel} ne "5.8") || ($u{osrel} ne "5.9"))) { return 0 } |
| 1394 | + if (($id eq "121430") && ($p{121430}{crev} ge '16') && (!$pkgs{"SUNWlucfg"})) { return 0 } |
| 1395 | + if (($id eq "121431") && ($p{121431}{crev} ge '17') && (!$pkgs{"SUNWlucfg"})) { return 0 } |
1399 | 1396 | if (($id eq "121428") && ($p{121428}{crev} ge '08')) { |
1400 | | - if (!((exists $p{121430}) && ($p{121430}{irev} ge '16'))) { return (0) } |
| 1397 | + if (!((exists $p{121430}) && ($p{121430}{irev} ge '16'))) { return 0 } |
1401 | 1398 | } |
1402 | 1399 | if (($id eq "121429") && ($p{121429}{crev} ge '08')) { |
1403 | | - if (!((exists $p{121431}) && ($p{121431}{irev} ge '16'))) { return (0) } |
| 1400 | + if (!((exists $p{121431}) && ($p{121431}{irev} ge '16'))) { return 0 } |
1404 | 1401 | } |
1405 | | - |
1406 | | - if (($id eq "125276") && ($u{arch} ne "sparc")) { return (0) } |
1407 | | - if (($id eq "125277") && (($u{osrel} ne "5.9") || ($u{arch} ne "i386"))) { return (0) } |
1408 | | - if (($id eq "125278") && (($u{osrel} ne "5.10") || ($u{arch} ne "i386"))) { return (0) } |
1409 | | - |
1410 | | - if (($id eq "123827") && ($u{osrel} ne "5.8")) { return (0) } |
1411 | | - if (($id eq "123828") && ($u{osrel} ne "5.9")) { return (0) } |
1412 | | - if (($id eq "123829") && ($u{osrel} ne "5.10")) { return (0) } |
1413 | | - |
1414 | | - if (($id eq "125760") && ($u{osrel} ne "5.8")) { return (0) } |
1415 | | - if (($id eq "125761") && ($u{osrel} ne "5.9")) { return (0) } |
1416 | | - if (($id eq "125762") && ($u{osrel} ne "5.10")) { return (0) } |
1417 | | - |
1418 | 1402 | if ($id =~ /120971|120972|120973|122803|122804|122805|126507|126508|126506/) { |
1419 | | - if (!($pkgs{"SUNWsamfsr"} || $pkgs{"SUNWsamfsu"})) { return (0) } |
| 1403 | + if (!($pkgs{"SUNWsamfsr"} || $pkgs{"SUNWsamfsu"})) { return 0 } |
1420 | 1404 | } |
1421 | 1405 | if ($id =~ /120974|120975|120976|122806|122807|122808|126511|126512|126510/) { |
1422 | | - if (!($pkgs{"SUNWqfsr"} || $pkgs{"SUNWqfsu"})) { return (0) } |
| 1406 | + if (!($pkgs{"SUNWqfsr"} || $pkgs{"SUNWqfsu"})) { return 0 } |
1423 | 1407 | } |
| 1408 | + if ($id =~ /116338|116339|118383|118384|125698|125699/) { |
| 1409 | + if (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>") { return 0 } |
| 1410 | + } |
| 1411 | + if (($id eq "119381") && ($u{osrel} ne "5.9") && ($u{osrel} ne "5.10")) { return 0 } |
| 1412 | + if (($id eq "119775") && ($minor < 10)) { return 0 } |
| 1413 | + if ($id eq "116831") { |
| 1414 | + if (!($pkga{"SUNWebsc"} && ($pkga{"SUNWebsc"} eq "<sparc>"))) { return 0 } |
| 1415 | + } |
| 1416 | + if ($id eq "116832") { |
| 1417 | + if (!($pkga{"SUNWebsc"} && ($pkga{"SUNWebsc"} eq "<sparcv9>"))) { return 0 } |
| 1418 | + } |
| 1419 | + if (($id eq "110938") && (($u{osrel} ne "5.8") || ($u{osrel} ne "5.9"))) { return 0 } |
| 1420 | + if (($id eq "110973") && (($u{osrel} ne "5.8") || ($u{osrel} ne "5.9"))) { return 0 } |
1424 | 1421 | |
1425 | | - if (($id eq "106514") && ($u{arch} ne "sparc")) { return (0) } |
1426 | | - if (($id eq "106515") && ($u{arch} ne "i386")) { return (0) } |
1427 | | - if (($id eq "108049") && ($u{arch} ne "sparc")) { return (0) } |
1428 | | - if (($id eq "108050") && ($u{arch} ne "i386")) { return (0) } |
1429 | | - if (($id eq "108879") && ($u{arch} ne "sparc")) { return (0) } |
1430 | | - if (($id eq "108881") && ($u{arch} ne "i386")) { return (0) } |
1431 | | - if (($id eq "109120") && ($u{arch} ne "sparc")) { return (0) } |
1432 | | - if (($id eq "109121") && ($u{arch} ne "i386")) { return (0) } |
1433 | | - if (($id eq "109413") && ($u{arch} ne "sparc")) { return (0) } |
1434 | | - if (($id eq "109414") && ($u{arch} ne "i386")) { return (0) } |
1435 | | - if (($id eq "117784") && ($u{arch} ne "sparc")) { return (0) } |
1436 | | - if (($id eq "117785") && ($u{arch} ne "i386")) { return (0) } |
1437 | | - if (($id eq "118195") && ($u{arch} ne "sparc")) { return (0) } |
1438 | | - if (($id eq "118196") && ($u{arch} ne "i386")) { return (0) } |
1439 | | - if (($id eq "118263") && ($u{arch} ne "sparc")) { return (0) } |
1440 | | - if (($id eq "118264") && ($u{arch} ne "i386")) { return (0) } |
1441 | | - if (($id eq "118950") && ($u{arch} ne "sparc")) { return (0) } |
1442 | | - if (($id eq "118951") && ($u{arch} ne "i386")) { return (0) } |
1443 | | - if (($id eq "123254") && ($u{arch} ne "sparc")) { return (0) } |
1444 | | - if (($id eq "124590") && ($u{arch} ne "i386")) { return (0) } |
1445 | | - |
1446 | | - if (($id eq "124480") && (($u{osrel} ne "5.9") || ($u{arch} ne "sparc"))) { return (0) } |
1447 | | - if (($id eq "124481") && (($u{osrel} ne "5.10") || ($u{arch} ne "sparc"))) { return (0) } |
1448 | | - if (($id eq "124482") && (($u{osrel} ne "5.10") || ($u{arch} ne "i386"))) { return (0) } |
1449 | | - |
1450 | | - if (($id eq "126356") && ($u{arch} ne "sparc")) { return (0) } |
1451 | | - if (($id eq "126357") && ($u{arch} ne "i386")) { return (0) } |
1452 | | - |
1453 | | - if (($id eq "117429") && ($u{osrel} ne "5.9")) { return (0) } |
1454 | | - if (($id eq "118386") && ($u{osrel} ne "5.6")) { return (0) } |
1455 | | - if (($id eq "118387") && ($u{osrel} ne "5.7")) { return (0) } |
1456 | | - if (($id eq "118388") && ($u{osrel} ne "5.8")) { return (0) } |
1457 | | - if (($id eq "118389") && ($u{osrel} ne "5.9")) { return (0) } |
1458 | | - if (($id eq "118828") && ($u{osrel} ne "5.8")) { return (0) } |
1459 | | - if (($id eq "118829") && ($u{osrel} ne "5.9")) { return (0) } |
1460 | | - if (($id eq "118836") && ($u{osrel} ne "5.6")) { return (0) } |
1461 | | - if (($id eq "118837") && ($u{osrel} ne "5.7")) { return (0) } |
1462 | | - if (($id eq "118838") && ($u{osrel} ne "5.8")) { return (0) } |
1463 | | - if (($id eq "118839") && ($u{osrel} ne "5.9")) { return (0) } |
1464 | | - if (($id eq "118840") && ($u{osrel} ne "5.9")) { return (0) } |
1465 | | - if (($id eq "120376") && ($u{osrel} ne "5.6")) { return (0) } |
1466 | | - if (($id eq "120377") && ($u{osrel} ne "5.7")) { return (0) } |
1467 | | - if (($id eq "120378") && ($u{osrel} ne "5.8")) { return (0) } |
1468 | | - if (($id eq "120379") && ($u{osrel} ne "5.9")) { return (0) } |
1469 | | - if (($id eq "124689") && ($u{osrel} ne "5.8")) { return (0) } |
1470 | | - if (($id eq "124690") && ($u{osrel} ne "5.9")) { return (0) } |
1471 | | - |
1472 | | - if (($id eq "116338") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1473 | | - if (($id eq "116339") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1474 | | - if (($id eq "118383") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1475 | | - if (($id eq "118384") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1476 | | - if (($id eq "125698") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1477 | | - if (($id eq "125699") && (!$pkgs{"SUNWxwplt"} || $pkgs{"SUNWxwplt"} !~ "<3.8.1800,REV=0.99.03.23>")) { return (0) } |
1478 | | - |
1479 | | - if (($id eq "111857") && ($u{osrel} ne "5.8")) { return (0) } |
1480 | | - if (($id eq "114176") && ($u{osrel} ne "5.9")) { return (0) } |
1481 | | - |
1482 | | - if (($id eq "119380") && ($u{osrel} ne "5.8")) { return (0) } |
1483 | | - if (($id eq "119381") && ($u{osrel} ne "5.9") && ($u{osrel} ne "5.10")) { return (0) } |
1484 | | - |
1485 | | - if (($id eq "125445") && ($u{osrel} ne "5.9")) { return (0) } |
1486 | | - if (($id eq "125446") && ($u{osrel} ne "5.10")) { return (0) } |
1487 | | - |
1488 | | - if (($id eq "127553") && ($u{arch} ne "sparc")) { return (0) } |
1489 | | - if (($id eq "127554") && ($u{arch} ne "i386")) { return (0) } |
1490 | | - |
1491 | | - if (($id eq "121708") && ($u{osrel} ne "5.8")) { return (0) } |
1492 | | - if (($id eq "121709") && ($u{osrel} ne "5.9")) { return (0) } |
1493 | | - if (($id eq "121710") && ($u{osrel} ne "5.10")) { return (0) } |
1494 | | - |
1495 | | - if (($id eq "125848") && ($u{osrel} ne "5.8")) { return (0) } |
1496 | | - if (($id eq "125849") && ($u{osrel} ne "5.9")) { return (0) } |
1497 | | - if (($id eq "125850") && ($u{osrel} ne "5.10")) { return (0) } |
1498 | | - |
1499 | | - return (1); |
| 1422 | + return 1; |
1500 | 1423 | } |
1501 | 1424 | |
1502 | 1425 | sub get_uname { |
1503 | 1426 | # Get information about host |
1504 | | - open(UNAME, $input{uname}) || err ("Can't open $input{uname} ($!)"); |
| 1427 | + open(UNAME, $input{uname}) || errx ("Can't open $input{uname} ($!)"); |
1505 | 1428 | $_=<UNAME>; |
1506 | | - $_ || err ("Empty uname output"); |
| 1429 | + $_ || errx ("Empty uname output"); |
1507 | 1430 | chomp; |
1508 | 1431 | close UNAME; |
1509 | 1432 | |
1510 | 1433 | ($u{osname}, $u{hostname}, $u{osrel}, $u{osversion}, $u{model}, $u{arch}, $u{platform})= split (/ /, $_); |
1511 | | - ($u{osname} && $u{hostname} && $u{osrel} && $u{osversion} && $u{model} && $u{arch} && $u{platform}) || err ("Can't parse ouput from $input{uname}:\n $_"); |
| 1434 | + ($u{osname} && $u{hostname} && $u{osrel} && $u{osversion} && $u{model} && $u{arch} && $u{platform}) || errx ("Can't parse ouput from $input{uname}:\n $_"); |
1512 | 1435 | } |
1513 | 1436 | |
1514 | 1437 | sub get_installed_packages { |
1515 | 1438 | my $package; |
1516 | 1439 | |
1517 | 1440 | # Read pkginfo |
1518 | | - open(PKGINFO, $input{pkginfo}) || err ("Can't open $input{pkginfo} ($!)"); |
| 1441 | + open(PKGINFO, $input{pkginfo}) || errx ("Can't open $input{pkginfo} ($!)"); |
1519 | 1442 | if ($input{pkginfo} =~ /pkginfo-l.out/) { |
1520 | 1443 | while(<PKGINFO>) { |
1521 | 1444 | if (/\s+PKGINST:\s+(\S+)$/) { $package = $1; } |
| 1445 | + if (/\s+ARCH:\s+(\S+)$/) { $pkga{$package} .= "<$1>"; } |
1522 | 1446 | if (/\s+VERSION:\s+(\S+)$/) { $pkgs{$package} .= "<$1>"; } |
1523 | 1447 | } |
1524 | 1448 | } else { |
1525 | 1449 | while(<PKGINFO>) { |
1526 | | - ($_ =~ /^(\S+) /) || err ("Can't parse output from $input{pkginfo}:\n $_"); |
| 1450 | + ($_ =~ /^(\S+) /) || errx ("Can't parse output from $input{pkginfo}:\n $_"); |
1527 | 1451 | $package=$1; |
1528 | 1452 | # Removing trailing .2/.3/... (multiple versions of same package) |
1529 | 1453 | $package =~ s/\..*//; |
1530 | 1454 | $_= <PKGINFO>; |
1531 | | - ($_ =~ / (\S+)$/) || err ("Can't parse output from $input{pkginfo}:\n $_"); |
1532 | | - $pkgs{$package} .= "<$1>"; |
| 1455 | + ($_ =~ /\((\S+)\) (.+)$/) || errx ("Can't parse output from $input{pkginfo}:\n $_"); |
| 1456 | + $pkga{$package} .= "<$1>"; |
| 1457 | + $pkgs{$package} .= "<$2>"; |
1533 | 1458 | } |
1534 | 1459 | } |
1535 | 1460 | close(PKGINFO); |
— | — | @@ -1537,6 +1462,7 @@ |
1538 | 1463 | sub get_installed_patches { |
1539 | 1464 | my $list=''; |
1540 | 1465 | my $done=0; |
| 1466 | + my $nonsun=999999; |
1541 | 1467 | |
1542 | 1468 | my $showrev_cmd=$showrev; ( -x $showrev_cmd) || ($showrev_cmd=''); |
1543 | 1469 | my $patchadd_cmd=$o{patchadd}; ( -x $patchadd_cmd) || ($patchadd_cmd=''); |
— | — | @@ -1547,7 +1473,7 @@ |
1548 | 1474 | |
1549 | 1475 | if ($o{fromfiles}) { |
1550 | 1476 | dbg ("Reading from $input{showrev}"); |
1551 | | - open(SHOWREV, $input{showrev}) || err ("Can't open $input{showrev} ($!)"); |
| 1477 | + open(SHOWREV, $input{showrev}) || errx ("Can't open $input{showrev} ($!)"); |
1552 | 1478 | $/=""; $list= <SHOWREV>; $/="\n"; |
1553 | 1479 | close SHOWREV; |
1554 | 1480 | $done=1; |
— | — | @@ -1560,40 +1486,14 @@ |
1561 | 1487 | if (!$?) { $done=1; last } else { dbg ("Failed: $list") } |
1562 | 1488 | } |
1563 | 1489 | } |
1564 | | - $done || err ("Couldn't get list of installed patches"); |
| 1490 | + $done || errx ("Couldn't get list of installed patches"); |
1565 | 1491 | |
1566 | 1492 | $list || ($list= "No patches are installed\n"); |
1567 | 1493 | my @list= split(/\n/, $list); |
1568 | 1494 | |
1569 | 1495 | foreach my $i (sort @list) { |
1570 | | - # Known formats of patch IDs: |
1571 | | - # 123456-78 : Regular Sun |
1572 | | - # IDR123456-78 : Unsupported (pre-release) Sun |
1573 | | - # 123-45 : EMC |
1574 | | - # CKPSP123456-78 : Checkpoint |
1575 | | - # CPFWSP410002-01: Checkpoint |
1576 | | - # KDE20060107-01 : KDE |
1577 | | - # IDCE32-02 : DCE |
1578 | | - # DP550001-05 : HP Data Protector |
1579 | | - # DP550011-1 : HP Data Protector |
1580 | | - # PSE400SOL023 : Citrix |
1581 | | - # ME113SB222 : Citrix |
1582 | | - # Q995801-01 : SUNWluxop |
1583 | | - # T000000-01 : Terix DST patch |
1584 | | - if ( |
1585 | | - ($i =~ /^Patch:\s+(\d{3,6})-(\d{2}).*/) || |
1586 | | - ($i =~ /^Patch:\s+IDR(\d{6})-(\d{2}).*/) || |
1587 | | - ($i =~ /^Patch:\s+CKPSP(\d{6})-(\d{2}).*/) || |
1588 | | - ($i =~ /^Patch:\s+CPFWSP(\d{6})-(\d{2}).*/) || |
1589 | | - ($i =~ /^Patch:\s+KDE(\d{8})-(\d{2}).*/) || |
1590 | | - ($i =~ /^Patch:\s+IDCE(\d{2})-(\d{2}).*/) || |
1591 | | - ($i =~ /^Patch:\s+DP(\d{6})-(\d{2}).*/) || |
1592 | | - ($i =~ /^Patch:\s+DP(\d{6})-(\d{1}).*/) || |
1593 | | - ($i =~ /^Patch:\s+PSE(\d{3})SOL(\d{3}).*/) || |
1594 | | - ($i =~ /^Patch:\s+ME(\d{3})SB(\d{3}).*/) || |
1595 | | - ($i =~ /^Patch:\s+Q(\d{6})-(\d{2}).*/) || |
1596 | | - ($i =~ /^Patch:\s+T(\d{6})-(\d{2}).*/) |
1597 | | - ) { |
| 1496 | + # Sun patches (123456-78, IDR123456-78) |
| 1497 | + if (($i =~ /^Patch:\s+(\d{6})-(\d{2}).*/) || ($i =~ /^Patch:\s+IDR(\d{6})-(\d{2}).*/)) { |
1598 | 1498 | my ($id, $rev)=($1,$2); |
1599 | 1499 | init_patch($id); |
1600 | 1500 | $p{$id}{irev}= $rev; |
— | — | @@ -1614,6 +1514,11 @@ |
1615 | 1515 | } |
1616 | 1516 | } |
1617 | 1517 | next; |
| 1518 | + # Non-Sun patches |
| 1519 | + } elsif ($i =~ /^Patch:\s+(\S+)/) { |
| 1520 | + my $id=$nonsun--; |
| 1521 | + init_patch ($id); $p{$id}{irev}=$p{$id}{crev}="01"; $p{$id}{synopsis}=$1; |
| 1522 | + next; |
1618 | 1523 | } |
1619 | 1524 | next if ($i =~ "No patches are installed"); |
1620 | 1525 | next if ($i =~ "No patches installed"); |
— | — | @@ -1627,7 +1532,7 @@ |
1628 | 1533 | |
1629 | 1534 | return if ($o{nocheckxref}); |
1630 | 1535 | |
1631 | | - lock_free($o{xrefdir}, "xref", 60) || err ("Another instance of pca is downloading $input{xref} right now"); |
| 1536 | + lock_free($o{xrefdir}, "xref", 60) || errx ("Another instance of pca is downloading $input{xref} right now"); |
1632 | 1537 | |
1633 | 1538 | # Remove possibly left-over size zero file |
1634 | 1539 | if (-z $input{xref}) { unlink ($input{xref}) } |
— | — | @@ -1652,18 +1557,18 @@ |
1653 | 1558 | if (! -w $o{xrefdir}) { |
1654 | 1559 | my $msg="Can't write to xref download directory $o{xrefdir}"; |
1655 | 1560 | if ($o{getxref} || (! -f $input{xref})) { |
1656 | | - err ($msg) |
| 1561 | + errx ($msg) |
1657 | 1562 | } else { out ('info', $msg); return } |
1658 | 1563 | } |
1659 | 1564 | # Check if we can write to xref file |
1660 | 1565 | if ((-f $input{xref}) && (! -w $input{xref})) { |
1661 | 1566 | my $msg="Can't write to $input{xref}"; |
1662 | 1567 | if ($o{getxref}) { |
1663 | | - err ($msg) |
| 1568 | + errx ($msg) |
1664 | 1569 | } else { out ('info', $msg); return } |
1665 | 1570 | } |
1666 | 1571 | |
1667 | | - lock_create($o{xrefdir}, "xref", 1) || err ("Another instance of pca is downloading $input{xref} right now"); |
| 1572 | + lock_create($o{xrefdir}, "xref", 1) || errx ("Another instance of pca is downloading $input{xref} right now"); |
1668 | 1573 | (-s $input{xref}) && rename ("$input{xref}", "$input{xref}.tmp"); |
1669 | 1574 | |
1670 | 1575 | if ($o{xrefurl} =~ /^file:/) { |
— | — | @@ -1702,14 +1607,14 @@ |
1703 | 1608 | open (XREF, "<$input{xref}.tmp"); |
1704 | 1609 | while (<XREF>) { |
1705 | 1610 | if ($_ =~ /PATCHDIAG TOOL CROSS-REFERENCE FILE AS OF (.*) /) { |
1706 | | - $oage= calculateage ($odate=$1); dbg ("old xref age: $oage"); last; |
| 1611 | + $oage= date2days ($odate=$1); dbg ("old xref age: $oage"); last; |
1707 | 1612 | } |
1708 | 1613 | } |
1709 | 1614 | close XREF; |
1710 | 1615 | open (XREF, "<$input{xref}"); |
1711 | 1616 | while (<XREF>) { |
1712 | 1617 | if ($_ =~ /PATCHDIAG TOOL CROSS-REFERENCE FILE AS OF (.*) /) { |
1713 | | - $nage= calculateage ($ndate=$1); dbg ("new xref age: $nage"); last; |
| 1618 | + $nage= date2days ($ndate=$1); dbg ("new xref age: $nage"); last; |
1714 | 1619 | } |
1715 | 1620 | } |
1716 | 1621 | close XREF; |
— | — | @@ -1737,8 +1642,8 @@ |
1738 | 1643 | sub get_current_patches { |
1739 | 1644 | # Read patchdiag.xref |
1740 | 1645 | # |
1741 | | - (-z $input{xref}) && err ("Empty file $input{xref}"); |
1742 | | - open(XREF, "<$input{xref}") || err ("Can't open xref file $input{xref} ($!)"); |
| 1646 | + (-z $input{xref}) && errx ("Empty file $input{xref}"); |
| 1647 | + open(XREF, "<$input{xref}") || errx ("Can't open xref file $input{xref} ($!)"); |
1743 | 1648 | while (<XREF>) { |
1744 | 1649 | if ($_ =~ /PATCHDIAG TOOL CROSS-REFERENCE FILE AS OF (.*) /) { |
1745 | 1650 | out ('info', "Using $input{xref} from $1"); last; |
— | — | @@ -1747,7 +1652,7 @@ |
1748 | 1653 | $/=""; my $xref= <XREF>; $/="\n"; |
1749 | 1654 | close XREF; |
1750 | 1655 | |
1751 | | - if (!$xref) { err ("Corrupt file $input{xref}") } |
| 1656 | + if (!$xref) { errx ("Corrupt file $input{xref}") } |
1752 | 1657 | |
1753 | 1658 | my @xref= split( /\n/, $xref ); |
1754 | 1659 | |
— | — | @@ -1758,11 +1663,14 @@ |
1759 | 1664 | foreach my $i (sort @xref) { |
1760 | 1665 | # Ignore comment lines and HTML tags |
1761 | 1666 | next if (($i =~ /^##/) || ($i =~ /^</)); |
1762 | | - if ($i !~ /^\d{6}\|\d{2}\|.*\|.\|.\|.\|..\|.*\|.*\|.*\|.*$/) { err ("Can't parse input from $input{xref}:\n $i") } |
| 1667 | + if ($i !~ /^\d{6}\|\d{2}\|.*\|.\|.\|.\|..\|.*\|.*\|.*\|.*$/) { errx ("Can't parse input from $input{xref}:\n $i") } |
1763 | 1668 | |
1764 | 1669 | my ($id, $crev, $reldate, $rFlag, $sFlag, $oFlag, $byFlag, $os, |
1765 | 1670 | $archs, $pkgs, $synopsis )= split( /\|/, $i); |
1766 | 1671 | |
| 1672 | + # Fix missing BAD mark |
| 1673 | + ($id eq "114147") && ($byFlag=" B"); |
| 1674 | + |
1767 | 1675 | init_patch($id); |
1768 | 1676 | |
1769 | 1677 | # If an installed patch revision is marked bad, note this. |
— | — | @@ -1821,6 +1729,8 @@ |
1822 | 1730 | # Patch requires are coded into the archs field - separate them. |
1823 | 1731 | $p{$id}{archs}=''; |
1824 | 1732 | $p{$id}{requires}=''; |
| 1733 | + $archs =~ s/[ ,]/;/; $archs =~ s/sparcv9;/sparc;/; $archs =~ s/x64;/i386;/; |
| 1734 | + $archs =~ s/Solaris;/all;/; $archs =~ s/Sparc;/sparc;/; $archs =~ s/|i86pc;/|i386;/; |
1825 | 1735 | foreach my $r (split /\;/, $archs) { |
1826 | 1736 | if ($r =~ /^\d{6}-\d{2}/) { |
1827 | 1737 | $p{$id}{requires} .= "$r;"; |
— | — | @@ -1867,6 +1777,7 @@ |
1868 | 1778 | $p{$id}{ignore}= ''; |
1869 | 1779 | $p{$id}{nobackup}= ''; |
1870 | 1780 | $p{$id}{reldate}= 'Jan/01/71'; |
| 1781 | + $p{$id}{age}= 0; |
1871 | 1782 | $p{$id}{obsoletedby}= ''; |
1872 | 1783 | $p{$id}{iobsoletedby}= ''; |
1873 | 1784 | $p{$id}{archs}= ''; |
— | — | @@ -1898,7 +1809,7 @@ |
1899 | 1810 | |
1900 | 1811 | $synopsis= $p{$id}{synopsis}; |
1901 | 1812 | |
1902 | | - $age=calculateage($p{$id}{reldate}); |
| 1813 | + $age=calculateage($id); |
1903 | 1814 | if ($age > 999) { $age=999; } |
1904 | 1815 | |
1905 | 1816 | if (!$o{listhtml}) { |
— | — | @@ -1935,7 +1846,7 @@ |
1936 | 1847 | if (!$o{listhtml} && !$o{noheader} && !$o{readme}) { |
1937 | 1848 | print "Host: $u{hostname} ($u{osname} $u{osrel}/$u{osversion}/$u{arch}/$u{model})\n"; |
1938 | 1849 | if ($o{root}) { my $r=$o{root}; $r =~ s/-R //; print "Root: $r\n" } |
1939 | | - print "List: @slist\n\n"; |
| 1850 | + print "List: @slist (" . int(@plist) . "/$agesum)\n\n"; |
1940 | 1851 | (@plist) || return; |
1941 | 1852 | |
1942 | 1853 | my $hdr= my $sep=$o{format}; |
— | — | @@ -1959,7 +1870,7 @@ |
1960 | 1871 | print "</head>\n<body>\n"; |
1961 | 1872 | print "<h2>Host: $u{hostname} ($u{osname} $u{osrel}/$u{osversion}/$u{arch}/$u{model})<br>\n"; |
1962 | 1873 | if ($o{root}) { my $r=$o{root}; $r =~ s/-R //; print "Root: $r<br>\n" } |
1963 | | - print "List: @slist</h2>\n<table>\n"; |
| 1874 | + print "List: @slist (" . int(@plist) . "/$agesum)</h2>\n<table>\n"; |
1964 | 1875 | (@plist) || return; |
1965 | 1876 | |
1966 | 1877 | print "<tr><th>Patch</th>"; |
— | — | @@ -2054,7 +1965,7 @@ |
2055 | 1966 | |
2056 | 1967 | # If we can't write to pca, update won't work. |
2057 | 1968 | if (($o{update} eq 'now') || ($o{update} eq 'auto')) { |
2058 | | - if (! -w $0) { err ("Update option unavailable: Can't write to $0") } |
| 1969 | + if (! -w $0) { errx ("Update option unavailable: Can't write to $0") } |
2059 | 1970 | } |
2060 | 1971 | |
2061 | 1972 | if ($o{update} eq 'auto') { |
— | — | @@ -2073,7 +1984,7 @@ |
2074 | 1985 | } |
2075 | 1986 | |
2076 | 1987 | my $udir= "$o{tmpdir}/pca." . time() . $$; |
2077 | | - mkdir $udir,0755 || err ("Can't create temporary directory $udir ($!)"); |
| 1988 | + mkdir $udir,0755 || errx ("Can't create temporary directory $udir ($!)"); |
2078 | 1989 | my $ufile= "$udir/pca"; |
2079 | 1990 | dbg ("ufile: $ufile"); |
2080 | 1991 | |
— | — | @@ -2088,7 +1999,7 @@ |
2089 | 2000 | } else { |
2090 | 2001 | $ret=download('pca', '', 'pcaurl', "", $udir); |
2091 | 2002 | } |
2092 | | - $ret || err ("Could not get pca from $o{pcaurl}"); |
| 2003 | + $ret || errx ("Could not get pca from $o{pcaurl}"); |
2093 | 2004 | |
2094 | 2005 | my $newv; |
2095 | 2006 | open (F, "<$ufile"); |
— | — | @@ -2145,7 +2056,7 @@ |
2146 | 2057 | |
2147 | 2058 | if (($o{update} eq "auto") && !$updated) { return } |
2148 | 2059 | if ($o{proxy}) { return } |
2149 | | - exit 0; |
| 2060 | + exit $xval; |
2150 | 2061 | } |
2151 | 2062 | |
2152 | 2063 | sub out { |
— | — | @@ -2183,6 +2094,13 @@ |
2184 | 2095 | } |
2185 | 2096 | |
2186 | 2097 | sub calculateage { |
| 2098 | + my $id=$_[0]; |
| 2099 | + |
| 2100 | + if (!$p{$id}{age}) { $p{$id}{age}=date2days($p{$id}{reldate}) } |
| 2101 | + return ($p{$id}{age}); |
| 2102 | +} |
| 2103 | + |
| 2104 | +sub date2days { |
2187 | 2105 | my ($tmonth, $day, $year)=split(/\//, $_[0]); |
2188 | 2106 | my %months=("Jan",0,"Feb",1,"Mar",2,"Apr",3,"May",4,"Jun",5,"Jul",6,"Aug",7,"Sep",8,"Oct",9,"Nov",10,"Dec",11); |
2189 | 2107 | my $month=$months{$tmonth}; |
— | — | @@ -2197,7 +2115,7 @@ |
2198 | 2116 | lock_free ($lockd, $tag, $maxretry) || return (0); |
2199 | 2117 | |
2200 | 2118 | unlink "$lockf"; |
2201 | | - sysopen (LOCKF, $lockf, O_RDWR|O_CREAT|O_EXCL) || err ("Can't write $lockf ($!)"); |
| 2119 | + sysopen (LOCKF, $lockf, O_RDWR|O_CREAT|O_EXCL) || errx ("Can't write $lockf ($!)"); |
2202 | 2120 | print LOCKF "$$\n"; |
2203 | 2121 | close LOCKF; |
2204 | 2122 | chmod 0666, $lockf; |
— | — | @@ -2236,17 +2154,21 @@ |
2237 | 2155 | } |
2238 | 2156 | |
2239 | 2157 | sub log_msg { |
2240 | | - ($o{syslog}) && system("$o{logger} -t pca -p $o{syslog}.info \"@_\""); |
| 2158 | + my $priority=$o{syslog}; |
| 2159 | + |
| 2160 | + if ($priority eq "none") { return } |
| 2161 | + if ($priority !~ /\./) { $priority .= ".notice" } |
| 2162 | + system("$o{logger} -t pca -p $priority \"@_\""); |
2241 | 2163 | } |
2242 | 2164 | |
2243 | | -sub err { |
| 2165 | +sub errx { |
2244 | 2166 | out ('error', @_); |
2245 | 2167 | cleanup(); |
2246 | | - exit 1; |
| 2168 | + exit ($xval=1); |
2247 | 2169 | } |
2248 | 2170 | |
2249 | 2171 | sub handler { |
2250 | | - err ("Caught a SIG@_"); |
| 2172 | + errx ("Caught a SIG@_"); |
2251 | 2173 | } |
2252 | 2174 | |
2253 | 2175 | sub cleanup { |
— | — | @@ -2311,15 +2233,16 @@ |
2312 | 2234 | |
2313 | 2235 | # Get defaults from optional configuration file(s) |
2314 | 2236 | my @conf=(); |
2315 | | - push (@conf, dirname($0)."/pca.conf"); |
2316 | | - push (@conf, dirname($0)."/../etc/pca.conf"); |
2317 | | - push (@conf, "/etc/pca.conf"); |
2318 | | - $ENV{HOME} && push (@conf, $ENV{HOME}."/.pca"); |
2319 | | - push (@conf, "pca.conf"); |
2320 | 2237 | if ($o{proxy}) { |
2321 | 2238 | push (@conf, dirname($0)."/../etc/pca-proxy.conf"); |
2322 | 2239 | push (@conf, "/etc/pca-proxy.conf"); |
2323 | 2240 | push (@conf, "pca-proxy.conf"); |
| 2241 | + } else { |
| 2242 | + push (@conf, dirname($0)."/pca.conf"); |
| 2243 | + push (@conf, dirname($0)."/../etc/pca.conf"); |
| 2244 | + push (@conf, "/etc/pca.conf"); |
| 2245 | + $ENV{HOME} && push (@conf, $ENV{HOME}."/.pca"); |
| 2246 | + push (@conf, "pca.conf"); |
2324 | 2247 | } |
2325 | 2248 | foreach my $i (@conf) { read_cffile ($i) } |
2326 | 2249 | |
— | — | @@ -2341,14 +2264,14 @@ |
2342 | 2265 | |
2343 | 2266 | # Proxy mode ? |
2344 | 2267 | if ($o{proxy}) { |
2345 | | - if ($#ARGV != 0) { err ("Missing argument") } |
| 2268 | + if ($#ARGV != 0) { errx ("Missing argument") } |
2346 | 2269 | if ($ARGV[0] =~ /:force/) { $ARGV[0] =~ s/:force//; $o{pforce}=1 } |
2347 | 2270 | if ((($ARGV[0] !~ /^patchdiag.xref$/) && |
2348 | 2271 | ($ARGV[0] !~ /^\d{6}-\d{2}\.(zip|jar|tar|tar\.Z)$/) && |
2349 | 2272 | ($ARGV[0] !~ /^\d{6}-\d{2}$/) && |
2350 | 2273 | ($ARGV[0] !~ /^README\.\d{6}-\d{2}$/) && |
2351 | 2274 | ($ARGV[0] !~ /^pca$/))) { |
2352 | | - err ("Illegal argument"); |
| 2275 | + errx ("Illegal argument"); |
2353 | 2276 | } |
2354 | 2277 | $o{proxy}=$ARGV[0]; |
2355 | 2278 | } else { |
— | — | @@ -2363,12 +2286,12 @@ |
2364 | 2287 | } |
2365 | 2288 | Getopt::Long::config ("bundling", "no_ignore_case"); |
2366 | 2289 | $o{cffile}=sub { read_cffile ($_[1]) }; |
2367 | | - GetOptions (\%o, @olist) || usage() && exit 1; |
| 2290 | + GetOptions (\%o, @olist) || usage() && exit ($xval=2); |
2368 | 2291 | delete $o{cffile}; |
2369 | 2292 | } |
2370 | | - if ($o{help}) { usage(); exit 0 } |
2371 | | - if ($o{man}) { man(); exit 0 } |
2372 | | - if ($o{version}) { version(); exit 0 } |
| 2293 | + if ($o{help}) { usage(); exit $xval } |
| 2294 | + if ($o{man}) { man(); exit $xval } |
| 2295 | + if ($o{version}) { version(); exit $xval } |
2373 | 2296 | |
2374 | 2297 | $o{listhtml} && ($o{list}=1); |
2375 | 2298 | $o{pretend} && ($o{install}=1); |
— | — | @@ -2403,9 +2326,10 @@ |
2404 | 2327 | dbg ("ARGV: @ARGV"); |
2405 | 2328 | dbg ("Version: $version"); |
2406 | 2329 | ($conf_dbg) && dbg ("Config files: $conf_dbg"); |
| 2330 | + ($o{debug} && !$o{proxy}) && log_msg ("Running pca $version in debug mode"); |
2407 | 2331 | |
2408 | 2332 | if ($o{update} !~ /^(never|check|now|auto)$/) { |
2409 | | - err ("Invalid TYPE specified with --update: $o{update}"); |
| 2333 | + errx ("Invalid TYPE specified with --update: $o{update}"); |
2410 | 2334 | } |
2411 | 2335 | } |
2412 | 2336 | |
— | — | @@ -2416,7 +2340,7 @@ |
2417 | 2341 | if ($j =~ /^all$/) { $o{$i}='all'; last } |
2418 | 2342 | if ($j =~ /^(\d{6})$/) { init_patch($1); ($p{$1}{$i}= "00"); next } |
2419 | 2343 | if ($j =~ /^(\d{6})-(\d{2})$/) { init_patch($1); ($p{$1}{$i}= $2); next } |
2420 | | - err ("Invalid patch ID with --$i: $j") |
| 2344 | + errx ("Invalid patch ID with --$i: $j") |
2421 | 2345 | } |
2422 | 2346 | } |
2423 | 2347 | } |
— | — | @@ -2426,7 +2350,7 @@ |
2427 | 2351 | foreach my $j (@{$o{$i}}) { |
2428 | 2352 | #dbg ("$i: $j"); |
2429 | 2353 | if ($j =~ /^(\d{6})(-\d{2})*$/) { init_patch($1); ($p{$1}{"${i}f"}= 1); next } |
2430 | | - err ("Invalid patch ID with --$i: $j") |
| 2354 | + errx ("Invalid patch ID with --$i: $j") |
2431 | 2355 | } |
2432 | 2356 | } |
2433 | 2357 | } |
— | — | @@ -2493,7 +2417,7 @@ |
2494 | 2418 | |
2495 | 2419 | sub man { |
2496 | 2420 | eval "use Pod::Usage"; |
2497 | | - if ($@) { err ('Required module Pod::Usage not found') } |
| 2421 | + if ($@) { errx ('Required module Pod::Usage not found') } |
2498 | 2422 | |
2499 | 2423 | # Change uid to something secure as pod2usage does not run as root. |
2500 | 2424 | # This snippet is taken from perldoc. See the comments there. |
— | — | @@ -2543,8 +2467,9 @@ |
2544 | 2468 | Here's some sample output from I<pca -l all>, which shows a list |
2545 | 2469 | of all installed and missing patches: |
2546 | 2470 | |
| 2471 | + Using /var/tmp/patchdiag.xref from Feb/29/04 |
2547 | 2472 | Host: myhost (SunOS 5.9/Generic_117171-09/sparc/sun4u) |
2548 | | - List: all |
| 2473 | + List: all (7/2182) |
2549 | 2474 | |
2550 | 2475 | Patch IR CR RSB Age Synopsis |
2551 | 2476 | ------ -- - -- --- --- -------------------------------------------------- |
— | — | @@ -2556,6 +2481,12 @@ |
2557 | 2482 | 113477 02 > -- --- 999 NOT FOUND IN CROSS REFERENCE FILE! |
2558 | 2483 | 117114 -- < 02 --- 4 CDE 1.5: sdtwebclient patch |
2559 | 2484 | |
| 2485 | +The header includes some general information about the patchdiag.xref |
| 2486 | +file, the host (I<Host:>) and the listed patches (I<List:>). The numbers |
| 2487 | +in parantheses are the number of listed patches and the sum of their ages |
| 2488 | +in days; when listing missing patches, this is a rough indicator of the |
| 2489 | +current patch state. |
| 2490 | + |
2560 | 2491 | The first column (I<Patch>) contains the patch number, followed by the |
2561 | 2492 | installed revision (I<IR>) and the current revision |
2562 | 2493 | (I<CR>), with one of E<lt>, E<gt>, or = between |
— | — | @@ -2587,7 +2518,7 @@ |
2588 | 2519 | |
2589 | 2520 | =head1 OPTIONS |
2590 | 2521 | |
2591 | | -=over 5 |
| 2522 | +=over |
2592 | 2523 | |
2593 | 2524 | =item -l, --list |
2594 | 2525 | |
— | — | @@ -2741,8 +2672,11 @@ |
2742 | 2673 | |
2743 | 2674 | =item --syslog=TYPE |
2744 | 2675 | |
2745 | | -Syslog facility (eg. user or local0) to log successful patch |
2746 | | -installs to. |
| 2676 | +Syslog priority to log patch installs to. The default is |
| 2677 | +I<daemon.notice> which gets logged to I</var/adm/messages>. Specify |
| 2678 | +facility and severity (e.g. I<local7.info>) or a facility only |
| 2679 | +(e.g. I<local7>, the default severity is I<notice>). Use I<none> to |
| 2680 | +disable logging to syslog. |
2747 | 2681 | |
2748 | 2682 | =item -k, --nobackup=ID |
2749 | 2683 | |
— | — | @@ -2944,7 +2878,7 @@ |
2945 | 2879 | and I<pca.conf> in the current |
2946 | 2880 | directory, in this order. In proxy mode the files I<../etc/pca-proxy.conf>, |
2947 | 2881 | I</etc/pca-proxy.conf> and |
2948 | | -I<pca-proxy.conf> in the current directory are read, too. |
| 2882 | +I<pca-proxy.conf> in the current directory are read instead. |
2949 | 2883 | Options are set by specifying |
2950 | 2884 | I<option=value> in the file. Example: To set the path of the wget command, |
2951 | 2885 | use I<wget=/opt/bin/wget>. To enable debug output, use |
— | — | @@ -3121,6 +3055,7 @@ |
3122 | 3056 | If the apache2 server is not running yet, create I</etc/apache2/httpd.conf> |
3123 | 3057 | and enable the server with I<svcadm>: |
3124 | 3058 | |
| 3059 | + # cp /etc/apache2/httpd.conf-example /etc/apache2/httpd.conf |
3125 | 3060 | # svcadm enable svc:/network/http:apache2 |
3126 | 3061 | |
3127 | 3062 | Test the caching proxy on a client: |
— | — | @@ -3345,17 +3280,13 @@ |
3346 | 3281 | as options; see CONFIGURATION for details. Furthermore, these environment |
3347 | 3282 | variables are used by pca: |
3348 | 3283 | |
3349 | | -=over 5 |
| 3284 | +=over |
3350 | 3285 | |
3351 | 3286 | =item PAGER |
3352 | 3287 | |
3353 | 3288 | Path to the command which is used to display patch README |
3354 | 3289 | files |
3355 | 3290 | |
3356 | | -=back |
3357 | | - |
3358 | | -=over 5 |
3359 | | - |
3360 | 3291 | =item TMPDIR |
3361 | 3292 | |
3362 | 3293 | During patch installation, patches are extracted under this |
— | — | @@ -3363,6 +3294,22 @@ |
3364 | 3295 | |
3365 | 3296 | =back |
3366 | 3297 | |
| 3298 | +=head1 EXIT STATUS |
| 3299 | + |
| 3300 | +The following exit values are returned: |
| 3301 | + |
| 3302 | + 0 No error |
| 3303 | + |
| 3304 | + 1 Unknown error |
| 3305 | + |
| 3306 | + 2 Usage error |
| 3307 | + |
| 3308 | + 3 Reboot required to continue patch installation |
| 3309 | + |
| 3310 | + 4 Reboot required |
| 3311 | + |
| 3312 | + 5 Reboot recommended |
| 3313 | + |
3367 | 3314 | =head1 AUTHORS |
3368 | 3315 | |
3369 | 3316 | Martin Paul E<lt>martin@par.univie.ac.atE<gt> |
— | — | @@ -3420,23 +3367,20 @@ |
3421 | 3368 | Jan Holzhueter, Liam Carey, Alex Docauer, Christopher S. Chan, Philip Kime, |
3422 | 3369 | Michael Schmarck, Kevin L. Bliss, Thomas Bleek, Albert White, Ron Helzer, |
3423 | 3370 | Sergei Haramundanis, Steven M. Christensen, Felix Schattschneider, |
3424 | | -Rajiv G Gunja, Jeremy Simpson, Jesse Caldwell, Amy Rich. |
| 3371 | +Rajiv G Gunja, Jeremy Simpson, Jesse Caldwell, Amy Rich, Jens Elkner, |
| 3372 | +Stephen Matich, Justus J. Addiss, Fred Chagnon, David French, Don O'Malley. |
3425 | 3373 | |
3426 | 3374 | =head1 MAILING LISTS |
3427 | 3375 | |
3428 | 3376 | Two mailing lists are available: |
3429 | 3377 | |
3430 | | -=over 5 |
| 3378 | +=over |
3431 | 3379 | |
3432 | 3380 | =item pca-news |
3433 | 3381 | |
3434 | 3382 | This is a one-way list for announcements of new versions and news. |
3435 | 3383 | To join, send an empty message to E<lt>pca-news-join@lists.univie.ac.atE<gt>. |
3436 | 3384 | |
3437 | | -=back |
3438 | | - |
3439 | | -=over 5 |
3440 | | - |
3441 | 3385 | =item pca |
3442 | 3386 | |
3443 | 3387 | This is a discussion and support list. Messages from pca-news will be |
— | — | @@ -3449,7 +3393,7 @@ |
3450 | 3394 | |
3451 | 3395 | =head1 SEE ALSO |
3452 | 3396 | |
3453 | | -=over 5 |
| 3397 | +=over |
3454 | 3398 | |
3455 | 3399 | =item pca web site: |
3456 | 3400 | |
— | — | @@ -3459,14 +3403,46 @@ |
3460 | 3404 | |
3461 | 3405 | =head1 CHANGES |
3462 | 3406 | |
3463 | | -=head2 Version 20080911-01 |
| 3407 | +=head2 Version 20081218-01 |
3464 | 3408 | |
3465 | | - * Remove check for patches which are only partly installed |
| 3409 | + * Enable syslog messages to daemon.notice by default |
| 3410 | + * Enhance possible values for syslog option |
| 3411 | + * Log sample message to syslog in debug mode |
| 3412 | + * New generic handling of unknown, non-Sun patches |
| 3413 | + * Documentation: Add cp command in local server setup example |
| 3414 | + * Rename internal function err() to avoid keyword clash with recent perl |
| 3415 | + * Mark patch 114147 as BAD |
| 3416 | + * Whitelist: add 137137, 137138, 121308, 121309, 138270 |
| 3417 | + * Whitelist: remove obsolete patch |
| 3418 | + * Apply check: add 110936, 110937, 110938, 110971, 110972, 110973 |
| 3419 | + * Apply check: add 118386, 118387, 118388, 118389 |
| 3420 | + * Apply check: add 118828, 118829 |
| 3421 | + * Apply check: add 118836, 118837, 118838, 118839 |
| 3422 | + * Apply check: add 127680, 127681, 127682, 127683, 127684 |
| 3423 | + * Apply check: add 138550, 138551, 138552, 138553, 138554 |
| 3424 | + * Update list of contributors |
3466 | 3425 | |
3467 | | -=head2 Version 20080909-02 |
| 3426 | +=head2 Version 20081024-01 |
3468 | 3427 | |
3469 | | - * False positive with partly installed patches: add 120011, 127127 |
| 3428 | + * Read only pca-proxy.conf (not pca.conf) in proxy mode |
| 3429 | + * Provide more detailed exit status |
| 3430 | + * Include patch count and sum of patch ages in header |
| 3431 | + * Fix handling of downloaded files that are too short |
| 3432 | + * Check whether patch already exists before announcing download |
| 3433 | + * Fix handling of PTF/ACSLS patches |
| 3434 | + * Read architecture information from pkginfo output |
| 3435 | + * Accept wrong entries in the arch column in patchdiag.xref |
| 3436 | + * Handle special characters in package version string |
| 3437 | + * Fix erroneous behaviour with checking for patch existance |
| 3438 | + * Simplify internal handling of extra patch requirements |
| 3439 | + * Calculate patch age only once |
| 3440 | + * Apply check: add 116413, 119775, 116831, 116832 |
| 3441 | + * Update list of contributors |
3470 | 3442 | |
| 3443 | +=head2 Version 20080911-01 |
| 3444 | + |
| 3445 | + * Remove check for patches which are only partly installed |
| 3446 | + |
3471 | 3447 | =head2 Version 20080909-01 |
3472 | 3448 | |
3473 | 3449 | * Check for patches which are only partly installed |