#!/ibin/vtcl

# VTCL: script to let the user know they're on an unsupported OS

proc okCB {cbs } {
 VtClose
 exit 0
}

set osver [lindex $argv 0]
set pkgname [join [lrange $argv 1 end]]
set progTitle "Unsupported OS Version $osver"
set appRoot [VtOpen BadOSVersion]
set mainForm [VtMessageDialog $appRoot.BadOSVersion \
  -title $progTitle -ok -okCallback okCB -message "\n\
  The package you are installing:                                 \n\
\n\
  $pkgname \n\
\n\
  is not supported on this release of SCO OpenServer. Only SCO    \n\
  OpenServer Releases 5.0.5, 5.0.6 and 5.0.7 are supported. You   \n\
  may be able to successfully install and run this package on     \n\
  SCO OpenServer Release 5.0.4, but this is not supported by SCO  \n\
  in any way.                                                     \n\
\n\
  Please refer to the Release Notes for more details.\n" \
  ]

VtShow $mainForm
VtMainLoop
