Setting up for Unicode Services conversion is similar to setting
up for Enhanced ASCII with the following changes:
- _BPXK_AUTOCVT can be set to ALL, which enables a Unicode Services
conversion environment for the program or user.
- AUTOCVT(ALL) can be specified in the BPXPRMxx parmlib member,
which enables a Unicode Services conversion program for all programs
and users. The SETOMVS or SET OMVS operator commands can turn AUTOCVT
to ALL.
- Instead of setting the ThliCcsid field the environment variable
_BPXK_PCCSID should be set. For a description of the _BPXK_PCCSID
environment variable, see _BPXK environment variables.
Before you begin: You need to have an overall understanding
of the limitations of Unicode Services, as explained in Considerations beyond that of Enhanced ASCII.
Perform the following steps to set up Enhanced ASCII.
- Set up Unicode Services. Base your choice on your particular situation.
If this situation exists .
. . |
Then use . . . |
---|
The application wants to exploit Unicode
Services when enabling automatic conversion. |
The _BPXK_AUTOCVT environment variable can be
set to ALL or fcntl(), or BPX1FCT can be called to enable to conversion. For
the XL C/C++ runtime environment, refer to z/OS XL C/C++ Programming Guide. |
The application is run in the z/OS® UNIX shell
or BPXBATCH. |
The _BPXK_AUTOCVT environment variable.
_BPXK_AUTOCVT can be set to ALL, which enables a Unicode Services
conversion environment for the program or user. |
You are enabling automatic conversion for
the z/OS UNIX environment. |
AUTOCVT(ALL) in BPXPRMxx, which enables
Unicode Services conversion environment for all programs and users. Tip: Use the SETOMVS and SET OMVS operator commands to turn
AUTOCVT on or off.
|
- Assign the appropriate file tag for each file that is to be converted.
Base your choice on your particular situation.
_______________________________________________________________
- Assign a coded character set identifier (CCSID) to each program
or thread in the shell. By default, the initial CCSID for every thread
is IBM®-1047 (EBCDIC).
- For entire programs written in C/C++, use the ASCII compiler to
change it to 819 (ISO8859-1 ASCII).
- For C/C++ threads, use the F_CONTROL_CVT subcommand of fcntl().
- For Assembler programs and threads, use the F_CONTROL_CVT subcommand
of the BPX1FCT callable service. F_CONTROL_CVT sets the CCSID of
the program associated with each opened file. (That is, the program
CCSID can be different depending on which file is chosen.)
- Set environment variable _BPXK_PCCSID.
When you are done, you have set up Unicode Services.