PURPOSE

buildclt - construct a TUXEDO System/T Workstation client program for MS-DOS, Windows, Windows NT, and OS/2.

SYNOPSIS

SYNOPSISbuildclt
[ -C ]
[ -v ]
[ -m {m | l} ]
[ -c {m | b | i} ]
[ -o name ]
[ -f firstfiles ]
[ -F Firstlibs ]
[ -l libfiles ]
[ -W ]
[ -O ]
[ -P ]
[ -d deffile ]

DESCRIPTION

buildclt is used to construct a TUXEDO System/T workstation client program for MS-DOS, Windows, Windows NT, and OS/2. The command combines the files supplied by the -f and -l options with the standard TUXEDO System/T libraries to form an executable program. The load module is built by buildclt using the C and COBOL language compilation commands defined for the operating system in use. The options to buildclt have the following meaning:

-v
specifies that buildclt should work in verbose mode. In particular, it writes the compilation command to its standard output.

-o name
specifies the file name of the output program. If not supplied, the program is named client.exe.

-f firstfiles
specifies one or more user files (or options to the compiler or linker) to be included on the command line first, before the System/T libraries. If more than one file is specified, file names must be separated by white space and the entire list must be enclosed in double quotation marks. This option may be specified multiple times.

-F Firstlibs
specifies one or more standard or import (not dynamic-link) libraries to be included before the System/T libraries. If more than one file is specified, file names must be separated by white space and the entire list must be enclosed in double quotation marks. This option may be specified multiple times.

-l libfiles
specifies one or more standard or import (not dynamic-link) libraries to be included after the System/T libraries. If more than one file is specified, file names must be separated by white space and the entire list must be enclosed in double quotation marks. This option may be specified multiple times.

-d deffile
specifies a module definition file used for linking a MS Windows, Windows NT or OS/2 program.

-m {m | l}
specifies the memory model to be used for compilation and linking of a client. The values for this option are m and l for the medium and large memory models, respectively. The large memory model is the default value for this option. The medium memory model is no longer supported for DOS. The memory model needs only to be specified for Windows and OS/2 16-bit compilation.

-c {m | i}
specifies the compilation system to be used. The supported values for this option are m or i for the Microsoft C/C++ compiler, or the IBM CSET2 compiler, respectively. The Microsoft C compiler is the default value for this option. The IBM CSET2 compiler can only be used for OS/2 32-bit compilation.

-W
Compile and link an MS Windows or Windows NT client.

-O
Compile and link an OS/2 character-mode client.

-P
Compile and link an OS/2 Presentation Manager client.

-C
specifies COBOL compilation.

The following environment variables must be set for the cobol environment.

COBCPY

The environment variable COBCPY indicates which directories contain a set of COBOL copy files to be used by the COBOL compiler.

Microsoft C Compilation

The buildclt command assumes that directories for needed libraries are specified in the environment variables INCLUDE and LIB. They might look like the following:

INCLUDE=C:\;TUXEDO\;INCLUDE;C:\NET\TOOLKIT\INCLUDE;C:\MSVC\INCLUDE
LIB=C:\NET\TOOLKIT\LIB;C:\WINDEV\LIB;C:\MSVC\LIB;C:\TUXEDO\LIB;

Note that in the above example, C:\MSVC is the directory where MS Visual C++ resides; earlier versions such as C600 or C700 can be used. Note that in the above example, C:\NET is the directory where Novell Lan Workplace resides; earlier versions resided in C:\XLN and can be used.

Note that COBOL source files that reference ATMI calls must be compiled with the LITLINK option.

The names of all libraries used for linking the client followed by the files specified in the -l option are put into a temporary "response file" and linking is done using the command line:

LINK firstfiles, outname  @tmpfile
firstfiles are the filenames specified with the -f option, outname is the output file name (default client.exe) tmpfile is the temporary response file name. The -f option should be used to included any necessary options to be passed to LINK (for example, /ST:10000 to set the default stack size to 10000 bytes). The -l option should be used to included any necessary network provider libraries (for example, mlibsock.lib). To create an executable that can be debugged using Codeview (assuming that the object files have been compiled with the -Zi option), use -f /CO.

EXAMPLES

MS-DOS C Compilation:

buildclt -cm -ml -o emp.exe -f "/CO/ST:10000/SE:200" -f emp.obj \
  -l llibsock.lib
WINDOWS C Compilation:
buildclt -W -cm -mm -o emp.exe -f "/CO emp.obj" -d emp.def
rc -k emp.res emp.exe
OS2 16-Bit:
buildclt -O -cm -ml -o emp.exe -f "/NOI/ST:15000/CO emp.obj" -d emp.def
OS2 32-Bit IBM:
buildclt -O -ci -f "/NOI/ST:25000 /CO emp.obj" -o emp.exe
Windows NT:
!include <ntwin32.mak>
rc -r emp.rc
buildclt -W -f "emp.obj emp.res" -l "$(winlibs)" -oemp.exe
DOS/WINDOWS/OS2 COBOL Compilation:
COBCPY=C:\TUXEDO\COBINC
COBDIR=C:\COBOL\LBR;C:\COBOL\EXEDLL
PATH=C:\C700\BIN;C:\COBOL\EXEDLL;...
TUXDIR=C:\TUXEDO
INCLUDE=C:\TUXEDO\INCLUDE;C:\XLN\TOOLKIT\INCLUDE;C:\C700\INCLUDE
LIB=C:\XLN\TOOLKIT\LIB;C:\C700\LIB;C:\TUXEDO\LIB;C:\COBOL\LIB
COBOL EMP.CBL OMF"OBJ" LITLINK
DOS:
BUILDCLT -C -o EMP.EXE -f EMP+MFC7INTF+C7DOSIF+C7DOSLB \
	-f "/NOD/NOE/SE:300/CO/ST:10000" -l LLIBSOCK
WINDOWS:
BUILDCLT -C -W -o EMP.EXE -f EMP -d EMP.DEF \
	-f "/NOD/NOE/CO/SE:300"
OS2:
BUILDCLT -C -P -o EMP.EXE -f EMP+MFC6INTF+C6OS2IF+C6OS2LB -d EMP.DEF \
	-f "/NOD/NOE/SE:300/CO"

SEE ALSO

Microsoft C/C++ Programming Techniques, Microsoft Corporation. Micro Focus COBOL/2 Operating Guide, Micro Focus Ltd. Micro Focus COBOL/2 Workbench for DOS and OS2, Micro Focus Ltd.