PROCEDURE install_cdcnet_tip (
  status)


  "$FORMAT=OFF
  VAR
    di_object_library: file
    ignore_status: status
    local_status: status
    message: string

    name_of_tip: name

    rav$subproduct_information: (XREF) rat$subproduct_information
    rav$installation_defaults: (XREF) rat$installation_defaults
    rav$installation_environment: (XREF) rat$installation_environment

    tip_library: file
  VAREND
  "$FORMAT=ON"

*IF $variable(wev$proc_doc,declared)<>'UNKNOWN'
"
"  This procedure installs a CDCNET separately priced tip.  This same
"  procedure can install any tip; the tip name is obtained from the
"  subproduct_name field of the subproduct_information variable.
"
*IFEND


  install_block: ..
    BLOCK

  name_of_tip = rav$subproduct_information.subproduct_name

  message = ' Merging the DI product '//$string(name_of_tip)//' onto DI_OBJECT.'
  $system.put_line l=message o=$job_log

  di_object_library = ..
    rav$subproduct_information.actual_installation_path.DI_OBJECT
  tip_library = ..
    rav$subproduct_information.actual_installation_path.DI_PRODUCTS//name_of_tip


*IF $variable(wev$prod_doc,declared)<>'UNKNOWN'
"
"  Call UPDATE_LIBRARY if the di object library already exists; otherwise
"  call INSTALL_FILE to create a new di object library file.
"
*IFEND

  IF $file(di_object_library permanent) THEN
    update_library f=tip_library l=di_object_library status=local_status
  ELSE
    install_file f=tip_library t=di_object_library status=local_status
  IFEND
  EXIT install_block WHEN NOT local_status.normal

  $system.put_line l=' Merge complete.' o=$job_log

  BLOCKEND install_block

  EXIT_PROC WITH local_status WHEN NOT local_status.normal

PROCEND install_cdcnet_tip
