• Before you can begin to work with FML fielded buffers, or to use the VIEWS functions that move fields between structures and fielded buffers, you must set up your environment to accommodate these methods by setting the necessary environment variables. This section provides instructions for doing so.The FML software delivered with the Oracle Tuxedo system resides in a subtree of the local file system. Several FML modules depend on the subtree structure described here. We assume that you have set the TUXDIR environment variable to the full path name of the directory in which the Oracle Tuxedo ATMI Server is installed.
• include—contains header files needed by writers of C application code.
• cobinclude—contains COPY files needed by writers of COBOL application code. (This directory is named cobinclu for operating systems with an 8.3 file name limitation.)
• bin—contains the executable commands of FML.
• lib—contains subroutine packages of FML. When compiling a program that uses FML functions, you should include $TUXDIR/lib/libfml.suffix and $TUXDIR/lib/libgp.suffix on the C compiler command line to resolve external references. libfml32.suffix contains the FML32 and VIEW32 functions. (The suffix is .a for POSIX operating systems without shared objects, .so.release for use of shared objects, .lib for Windows; it is part of the Oracle Tuxedo system DLL for platforms that use dynamic link libraries.)The file fml.h or fml32.h contains definitions for structures, symbolic constants, and macros used by the FML software.
• TUXDIR—this variable should be set to the topmost node of the installed Oracle Tuxedo system software including FML.
• FIELDTBLS—this variable should contain a comma-separated list of field table files for the application. Files given as full path names are used as is; files listed as relative path names are searched for through the list of directories specified by the FLDTBLDIR variable. FIELDTBLS32 is used for FML32. If FIELDTBLS is not set, then the single file name fld.tbl is used. (FLDTBLDIR still applies; see below.)
• FLDTBLDIR—this variable specifies a colon-separated list of directories to be used to find field table files with relative filenames. Its usage is similar to the PATH environment variable. If FLDTBLDIR is not set or is NULL, then its value is taken to be the current directory. FLDTBLDIR32 is used for FML32.
• VIEWS functions use the same environment variables used by FML (namely, FLDTBLDIR and FIELDTBLS) plus two other environment variables:
• VIEWFILES—this variable should contain a comma-separated list of object viewfiles for the application. Files given as full path names are used as is; files listed as relative path names are searched for through the list of directories specified by the VIEWDIR variable (see the following list item). VIEWFILES32 is used for VIEW32.
• VIEWDIR—this variable specifies a colon-separated list of directories to be used to find view object files with relative filenames. It is set and used in the same way that the PATH environment variable is set and used. If VIEWDIR is not set or is NULL, then its value is assumed to be the current directory. VIEWDIR32 is used for VIEW32.
• The following variables are used in FML32 to support the FLD_MBSTRING field type:
• TPMBENC—this variable specifies the code-set encoding name that the application server or client running Oracle Tuxedo 8.1 or later includes for an FLD_MBSTRING field in an FML32 typed buffer. When an application server or client process allocates and sends an FML32 buffer containing a FLD_MBSTRING field, the code-set encoding name defined in TPMBENC is automatically used by Fmbpack32() if its enc argument is not defined and its flag argument is not set to FBUFENC.When the application server or client process receives an FML32 buffer that includes an FLD_MBSTRING field, and assuming another environment variable named TPMBACONV is set, the code-set encoding name defined in TPMBENC is automatically compared to the code-set encoding name included for the FLD_MBSTRING field in the received buffer; if the names are not the same, the FLD_MBSTRING field data is automatically converted to the encoding defined in TPMBENC before being delivered to the server or client process.TPMBENC has no default value. For an application server or client using FLD_MBSTRING fields, TPMBENC must be defined for automatic conversion to work.
Note: TPMBENC is used in a similar way for MBSTRING typed buffers.
• TPMBACONV—this variable specifies whether the application server or client running Oracle Tuxedo 8.1 or later automatically converts the FLD_MBSTRING field data in a received FML32 buffer to the encoding defined in TPMBENC. By default, the automatic conversion is turned off, meaning that the FLD_MBSTRING field data is delivered to the destination server or client process as is—no encoding conversion. Setting TPMBACONV to any non-NULL value, say Y (yes), turns on the automatic conversion.
Note: TPMBACONV is used in a similar way for MBSTRING typed buffers.Starting with Tuxedo 9.0, VIEW32 supports MBSTRING typed buffers which correspond to the FLD_MBSTRING field type in FML32.Fmbpack32(3fml)prepares an MBSTRING field in a VIEW32 buffer for encoding and Fmbunpack32(3fml)extracts it. TPMBENC and TPMBACONV environment variables are also used in VIEW32.