This topic includes the following sections:
Refer to Using the Oracle Tuxedo Workstation Component for more information on the Workstation platform.
The following sections describe how to write and build client programs, and set appropriate environment variables when developing, in COBOL, an Oracle Tuxedo application on a UNIX platform.
You can develop COBOL client programs for a UNIX platform in the same way that you develop COBOL clients in the Oracle Tuxedo administrative domain. All ATMI calls are available.
To compile and link-edit Workstation client programs, use the buildclient(1) command. If you are building a UNIX Workstation client on the native node, use the
-w option to have the client built using the Workstation libraries.
If you are building a client on a native node, and both native and Workstation libraries are present, the native libraries are used by default. In this case, specifying the
-w option ensures that the correct libraries for a Workstation client are used.
On a workstation, where only the Workstation libraries are present, it is not necessary to specify
Listing 12-3 shows how to use the
buildclient command on a native node.
ALTCC=cobcc ALTCFLAGS="-I /APPDIR/include"
COBOPT="-C ANS85 -C ALIGN=8 -C NOIBMCOMP -C TRUNC=ANSI -C OSEXT=cbl"
export COBOPT COBCPY ALTCC ALTCFLAGS
buildclient -C -w -o empclient -f name.cbl -f "userlib1.a userlib2.a"
-o option enables you to specify a name for your output file. Input files specified with the
-f option are linkedited before system libraries.
As illustrated, the
TUXDIR environment variable must be used to ensure that the
buildclient command can locate system libraries. Be sure that you have defined
CC environment variable defaults to
cc, but can be set to another compiler through
Workstation clients make use of several environment variables.
Table 12-1 lists the environment variables that are checked by
TPINITIALIZE when a Workstation client attempts to join an application.
Network address of the Workstation listener process through which the client gains access to the application. Use the value specified in the application configuration file for the Workstation listener to be called. If the value begins with the characters
Workstation type. Used by
Maximum amount of core memory that the ATMI uses for buffering application replies before dumping them to disk. Used by
The network address used by the Workstation client when connecting to the Workstation listener or Workstation handler. This variable, along with the
Other environment variables may be needed by Workstation COBOL clients on a UNIX workstation, depending on which components of the Oracle Tuxedo system are being used.
The following sections describe how to write and build client programs, build ACCEPT/DISPLAY clients, block network behavior, and restore the network environment when developing, in COBOL, an Oracle Tuxedo application for the Microsoft Windows platform.
All program-specific ATMI calls are available.
To compile the COBOL source files that call the ATMI, you must use the COBOL compiler with the
LITLINK option. To linkedit the Workstation client object files, use the buildclient(1) command. While the syntax of the command is straightforward, the usage varies according to the compilation system used.
Listing 12-2 shows how to use the
buildclient -C -o EMP.EXE -f EMP -f "/NOD/NOI/NOE/CO/SE:300" -l WLIBSOCK
For Windows NT:
buildclient -C -o EMP.EXE -f empobj
Table 12-2 describes the
buildclient command options used in the preceding example.
One or more object files to be included before the Oracle Tuxedo libraries. You can use the
The following example shows how to build an executable client for an
ACCEPT/DISPLAY application, such as
a) compile the COBOL module and create a file.obj
cobol file.cbl omf(obj) litlink;
b) use the following link statement
For Windows NT the link statement is:
cbllink -oEMP.exe EMP.obj \
cobws.lib ncobatmi.lib wtuxws32.lib \