#!/usr/bin/env ruby

if(ARGV.length > 0)
  msg = %{
    Trying to install older version #{ARGV[2]} over 
    version #{ARGV[1]} of #{ARGV[0]}.
    
    The install will proceed but you will not be able 
    to install this component. 
    
    Use the Uninstaller in /Applications/AJA Utilities 
    if you wish to remove the previously installed 
    driver then launch the installer again.
  }
else  
  msg = %{ 
    Problem with previously installed driver version 
    or easy setups version.
  }
end

system("osascript -e 'tell application \"Finder\"' -e 'activate' -e 'display dialog \"#{msg}\" buttons {\"Ok\"}' -e 'end tell'")
system("osascript -e 'tell application \"Installer\"' -e 'activate' -e 'end tell'")