/* Copyright (c) Oracle Corporation 1992.  All Rights Reserved */
/*****************************************************************************
  NAME
    gui25.ins - V3 installation script for GUI Common Files 2.5.

  DESCRIPTION
    This script installs GUI Common Files 2.5.

  OWNER
    Rajesh Bansal

  MODIFIED   MM/DD/YY   Reason
   bsabol    07/01/94   Modified for CDE2 release.
   rbansal   13-MAY-94  Modified
  dgalatin   23-DEC-93  Made 3.0.10.1 compliant.
   akelley   22-OCT-93  Created.
*****************************************************************************/
{
    if (doit)
    {
        /*****************************
        Set the VRF-INS script ratchet
        ******************************/
        ins_ratchet = "2.1.4.1.0";
      
        execute("%installer_home%\windows.ins");

        permit_retry_operations  = TRUE;
        permit_ignore_operations = TRUE;
        permit_process_operations= TRUE;

        /******************
        Install the product
        *******************/
        ui_product(instantiate(display_product_label));

        ui_action( instantiate(install_dei) );
        copy(deinst);

        ui_action( instantiate(install_exe) );
        copy(exe);

        ui_action( instantiate(install_dll) );
        copy(dll);

        ui_action( instantiate(install_res) );
        copy(res);

        ui_action( instantiate(install_msb) );
        copy(msg);

        if(install_ctl3d)
		{
	        ui_action( instantiate(install_dll) );
	        copy(ctl3d);
		}
		
      if(install_ctl3dv2)
      {
	        ui_action(instantiate(install_dll));
	        copy(ctl3dv2);
		}
       

        /*************************
        Modify Config Variables...
        **************************/
        if(set_tk21)
	    {
	        ui_action( instantiate(modify_variables) );
	        {modify("TK21",tk21,ora_config,"Oracle");}
	    }

        if(set_tk21_icon)
	    {
	        ui_action( instantiate(modify_variables) );
	        {modify("TK21_ICON",tk21_icon,ora_config,"Oracle");}
	    }

        if(set_mm20)
	    {
	        ui_action( instantiate(modify_variables) );
	        modify("MM20",mm20,ora_config,"Oracle");
	    }

        permit_retry_operations = FALSE;

        /*******************
        Install dependencies
        ********************/
        ui_product(instantiate(display_product_label));
        ui_action( instantiate(install_dependencies) );
        install(RSF_PRODUCT);

        rsf_registry = registration(product_name(RSF_PRODUCT));
        if(earlier_version(rsf_registry,"7.1.4.0.1"))
	        signal('FAILURE,(instantiate(rsf_version_msg)));

        permit_retry_operations = TRUE;

        /*******************
        Register the product
        ********************/
        ui_product(instantiate(display_product_label));
        ui_action( instantiate(install_register) );
        register(current_product);
        
        if (member(selected_products,current_product))
	        reference(current_product);

        /*********************
        Reference dependencies
        **********************/
        ui_product(instantiate(display_product_label));
        ui_action(instantiate(reference_dependencies));
        reference(RSF_PRODUCT,current_product);

        permit_retry_operations = FALSE;
    }
	[
		 'UNREGISTERED_PRODUCT: continue();
		 'CANCEL: signal('FAILURE, instantiate(halt_installation));
	]
}
