hp.com home products and services support and drivers solutions how to buy
cd-rom home
End of Jump to page title
HP OpenVMS systems
documentation

Jump to content


POLYCENTER Software Installation Utility Developer's Guide

POLYCENTER Software Installation Utility Developer's Guide


Previous Contents Index

By default, the software function tests the state the product will be in when the operation finishes, not when the operation begins. The same effect is obtained when you include the installed after option. To test the state of the referenced product when the operation begins, you must specify the installed before option. If you specify the kit accessible option, the function tests whether the referenced product kit is present in the source directory.

Note

The default option, installed after, is reliably tested only after the user configuration phase concludes and the utility is about to begin the execution phase. Use caution when including this option with the software function.

The function value is true if the following conditions exist; otherwise, the value is false:

The software function is more appropriate than the software statement if you need only verify the existence of a certain product.

You use the software function with the if statement, as shown in the following example:


   if ( not < software HP AXPVMS PROD_A version minimum V4.0 > ) ; 
       information NO_PROD_A confirm ; 
       file [SYSEXE]PROD_A_SUBSTITUTE.EXE ; 
   end if ; 

Using the software function with the if statement gives you much more flexibility in forming expressions with other functions, and allows you to perform multiple actions in the form of groups of statements.

If the software function reference is not satisfied, you can display an error message with an error statement. This message allows a message of any size and contents. (Note that an error message induced by an unsatisfied software statement is rigid, short, and potentially less informative.)

You can use the abort option on an error statement to unconditionally terminate the software function operation, while the failed software statement leaves the user with an option to continue the product installation.


   if ( < software HP AXPVMS PROD_B version below V7.0 > ) ; 
       error NO_PROD_B abort ; 
   end if ; 

Summary of Differences Between the Statement and Function

Table 7-10 summarizes the differences between the software statement and the software function.

Table 7-10 Summary of software Statement and software Function Differences
Statement Function
If the referenced product is not installed and its kit is available to the utility during the installation of the referencing product, it will be installed by the utility just prior to the referencing product. If the referenced product is not installed, the function will evaluate to the boolean value FALSE (0). The referenced product will not be installed even though the kit may be available to the utility.
Causes the utility to create a permanent software reference in the database. Does not create any reference from the referencing to the referenced product.
Creates a risk of software reference conflicts. Since no permanent software reference is created, there is no risk of conflict.
Causes the utility to create a software reference and user interface related data structures in memory for the duration of the operation, thereby consuming additional system memory. Does not cause the utility to create software reference or user interface related data structures in memory.
Requires additional processing to check for software reference conflicts and for processing error messages. Requires no additional processing other than searching for the presence of the referenced products.
If software reference cannot be satisfied, a one-sentence message is displayed to the user. Allows any processing based on the value of the software function; error messages can be tailored in any desired way and size.
With the failure of a software reference, continuation of the operation is still possible. With the failure of a software reference, processing may be unconditionally aborted with an "error <message> abort" statement.
Use only if you are willing to install the referenced product. Use whenever you want only to check for the referenced product availability, but do not intend to install the referenced product.

Avoiding Common Mistakes

A common mistake is for a layered product's PDF to include a software statement reference to a VMS (OpenVMS operating system) product, or to an OPENVMS platform (product suite that includes the OpenVMS operating system).

It is acceptable to reference the OpenVMS operating system from a software statement if your product relies on the presence of the library files supplied by the operating system. However, do not reference the OpenVMS platform from a software statement.

If you need to verify the OpenVMS operating system version before the installation of the layered product can proceed and complete successfully, use the software function instead:


   if ( < software DEC AXPVMS VMS version below V6.2 > ) ; 
       error UNSUPP_VMS_VER abort ; 
   else ; 
       -- include your PDL statements here 
   end if ; 

If you do use the software statement, you should expect the following results:

See Also apply to
if
product
upgrade

Examples

#1

software HP VAXVMS FORTRAN 
    version minimum V3.0 version maximum V5.0 ; 
 
      

The software statement in this example specifies that this product requires HP Fortran software. The version must be between 3.0 and 5.0.

#2

software HP VAXVMS FORTRAN version below V5.0 ; 
      

The software statement in this example specifies that this product requires HP Fortran software. The version must be less than (but not equal to) 5.0.

#3

if ( < software HP AXPVMS COOL_PRODUCT 
          version minimum V3.0 kit accessible > ) ; 
    software HP AXPVMS COOL_PRODUCT version minimum V3.0 ; 
else if ( < option NO_COOL_REFERENCE default YES with helptext > ) ; 
    file [SYSEXE]COOL_SUBSTITUTE.EXE ; 
else ; 
    error MISSING_COOL ; 
end if ; 
 
      

In this example, the software function is used to search the source directory for the COOL_PRODUCT kit. If the POLYCENTER Software Installation utility finds the software package with Version 3.0 or higher on the system, the reference to it is created with a separate software statement.

If the COOL_PRODUCT V3.0 or higher is not found, an option to install its substitute ( file [SYSEXE]COOL_SUBSTITUTE.EXE] ) is offered to the user. If the user declines to accept the substitute image, an error is issued and the user is prompted to either terminate or continue the current session.


system parameter

The system parameter statement allows you to display a message to users that expresses system parameter requirements for your product.

Note

The utility does not change system parameters.

Syntax

system parameter name
{ { consume | require } value |
maximum value |
minimum value |
minimum value maximum value } ;


Parameter

name

Indicates the name of the system parameter. The parameter you specify must be valid on the system where the product executes.

Options

consume value

Indicates that the system parameter must be increased by the specified value. Use this option when the product consumes a resource that is controlled by the system parameter. The value must be a single unquoted string that specifies an unsigned integer value. You cannot use this option with either the maximum, minimum, or require options.

maximum value

Indicates that the system parameter must have a value less than or equal to the specified value. The value must be a single unquoted string that specifies an integer value.

minimum value

Indicates that the system parameter must have a value greater than or equal to the specified value. The value must be a single unquoted string that specifies an integer value.

require value

Indicates that the system parameter must have the specified value. The value must be a single string that specifies a value of the parameter's type. This option is valid for any parameter data type. You cannot use this option with either the maximum, minimum, or consume options.

Description

The system parameter statement displays a message to users about system parameter requirements for your product after the installation. Note that the utility does not adjust system parameters.
See Also information
process parameter

Example


system parameter vaxcluster require 1 ; 
system parameter tty_classname require "TT" ; 
system parameter pagedyn consume 200 ; 
      

The statements in this example display the following messages:


 
This product requires the following system parameters 
    VAXCLUSTER value 1 
 
This product requires the following system parameters 
    TTY_CLASSNAME value TT 
 
This product requires the following system parameters 
    PAGEDYN add 200 
      


upgrade

The upgrade statement specifies the versions of the product that can be upgraded by the product kit being installed. If the product is currently installed but its version does not meet the version selection criteria in the upgrade statement, the installation is terminated. The upgrade statement has no effect when the product is being installed for the first time.

The upgrade function tests whether a version of the product in the specified range is being upgraded by the current operation. If a version of the product in the specified range is currently installed, the function returns true; otherwise it evaluates to false. If no version criteria are given, the function tests whether any version of the product is currently installed.


Statement Syntax

upgrade
{ version above version |
version below version |
version maximum version |
version minimum version |
version required version |
version above version version below version |
version above version version maximum version |
version minimum version version below version |
version minimum version version maximum version } ;


Function Syntax

< upgrade
[ { version above version |
version below version |
version maximum version |
version minimum version |
version required version |
version above version version below version |
version above version version maximum version |
version minimum version version below version |
version minimum version version maximum version } ] >


Options

version above version

Establishes a lower version limit. The version identifier must be a single quoted or unquoted string. Use this option to specify that the product version must be greater than (but not equal to) the specified version. You cannot use this option with either the version minimum or version required option. By default, there is no lower version limit.

version below version

Establishes an upper version limit. The version identifier must be a single quoted or unquoted string. Use this option to specify that the product version must be less than (but not equal to) the specified version. You cannot use this option with either the version maximum or version required option. By default, there is no upper version limit.

version maximum version

Establishes an upper version limit. The version identifier must be a single quoted or unquoted string. Use this option to specify that the product version must be less than or equal to the specified version. You cannot use this option with either the version below or version required option. By default, there is no upper version limit.

version minimum version

Establishes a lower version limit. The version identifier must be a single quoted or unquoted string. Use this option to specify that the product version must be greater than or equal to the specified version. You cannot use this option with either the version above or version required option. By default, there is no lower version limit.

version required version

Establishes a required version. The version identifier must be a single quoted or unquoted string. Use this option to specify that the product version must be equal to the specified version. You cannot use this option with either the version above, version below, version maximum, or version minimum option. By default, there is no required version constraint.

Description

Statement

In a full, platform, or operating system PDF, the upgrade statement is optional. When present, the upgrade statement specifies the versions of the product that can be successfully upgraded by the product kit. If a version of the product is currently installed but does not meet the version selection criteria in the upgrade statement, the installation is terminated. The upgrade statement has no effect when the product is being installed for the first time. If an upgrade statement is not present in the PDF, the kit being installed is allowed to upgrade (or replace) any version of the product that might be installed. This includes a lower version, a higher version, or the same version of the product.

In a partial PDF, the upgrade statement is required. The statement specifies which versions of the product must be installed for the partial kit to be applied successfully.

You cannot use the upgrade statement for a patch, mandatory update, or transition PDF.

Function

The upgrade function tests whether a version of the product in the specified range is being upgraded by the current operation. If a version of the product in the specified range is currently installed, the function returns true; otherwise it evaluates to false. If no range is given, the function tests whether any version of the product is currently installed.

The upgrade function is not meaningful for a patch, mandatory update, or transition PDF. If included in these PDFs, the upgrade function always evaluates to false.

See Also apply to
if
product
software

Examples

#1

product HP AXPVMS ABC V4.0 full ; 
    upgrade version minimum V2.0 ; 
   .
   .
   .
end product ; 
      

The upgrade statement in this example does not allow product ABC V4.0 to upgrade versions of the product prior to V2.0. Product ABC, however, can upgrade to V2.0 or later of the product. Or, if a previous version of the product is not currently installed, it can perform a new installation.

#2

product HP AXPVMS DEF V4.2 partial ; 
    upgrade version required V4.1 ; 
   .
   .
   .
end product ; 
      

The upgrade statement in this PDF is required because this is a partial kit. It specifies that product DEF V4.1 must already be installed in order to apply this partial kit to upgrade the product to V4.2.

#3

product HP VAXVMS JKL V2.5 full ; 
    if (<upgrade>) ; 
    information UPG_MSG ; 
    end if ; 
   .
   .
   .
end product ; 
      

In this example, if any version of product JKL is currently installed, an informational message will be displayed to the user.

#4

product HP VAXVMS JKL V2.5 full ; 
    if (<upgrade version minimum A1.0 version below A2.0>) ; 
    file [sysupd]jkl_convert.com ; 
    end if ; 
   .
   .
   .
end product ; 
      

If version 1 of the product (from beta test through final release) is being upgraded, the upgrade function in this PDF is used to conditionally provide a file.


Previous Next Contents Index