Mantis - pkgutil
Viewing Issue Advanced Details
4898 regular use major always 2012-02-17 16:55 2012-02-21 10:16
mikera  
bonivart  
normal  
closed  
fixed  
none    
none  
0004898: Packages CSWcas- won't install on Solaris 9
Solaris 9 (and probaly Solaris 8) systems missing /bin/pkgcond command will fail to install CSWcas- packages.

In the /opt/csw/bin/pkgutil script the /bin/pkgcond command is used to check if the directory /usr/sadm/install/scripts directory is read only. If the pkgcond command is missing (patch level?) the package installation will fail as the pkgutil logic assumes the directory is not writable and not that the command is missing.
Simple fix

$ diff -c pkgutil.orig pkgutil
*** pkgutil.orig Fri Feb 17 09:47:33 2012
--- pkgutil Sat Feb 4 08:30:52 2012
***************
*** 1413,1419 ****
      if ( grep { /^CSWcas-/ } @dlpkglist ) { # CAS pkg in the list?
          my $status = system( "/bin/pkgcond", "is_path_writable",
              "/usr/sadm/install/scripts" ); # /usr ro?
! if ($status) {
              myexit(
                  "A class action script is about to be installed but\n"
                    . "/usr/sadm/install/scripts is read-only so it will fail.\n"
--- 1413,1419 ----
      if ( grep { /^CSWcas-/ } @dlpkglist ) { # CAS pkg in the list?
          my $status = system( "/bin/pkgcond", "is_path_writable",
              "/usr/sadm/install/scripts" ); # /usr ro?
! if (! -w "/usr/sadm/install/scripts") {
              myexit(
                  "A class action script is about to be installed but\n"
                    . "/usr/sadm/install/scripts is read-only so it will fail.\n"
Issue History
2012-02-17 16:55 mikera New Issue
2012-02-17 18:07 bonivart Status new => assigned
2012-02-17 18:07 bonivart Assigned To => bonivart
2012-02-17 18:59 bonivart Note Added: 0009610
2012-02-21 10:16 bonivart Note Added: 0009624
2012-02-21 10:16 bonivart Status assigned => closed
2012-02-21 10:16 bonivart Resolution open => fixed

Notes
(0009610)
bonivart   
2012-02-17 18:59   
Please test the packages here and get back to me:

http://buildfarm.opencsw.org/experimental.html#pkgutil [^]
(0009624)
bonivart   
2012-02-21 10:16   
Released as 2.6.3.