TNS/R Native Application Migration Guide
Developing a Migration Strategy
TNS/R Native Application Migration Guide—523745-001
2-3
Maintaining Common Source Code for TNS and
Native Compilers
Maintaining Common Source Code for TNS
and Native Compilers
If your program requires few changes to migrate to native mode, you can often
maintain common source code for the TNS and native compilers. If your program
requires extensive or complex changes to migrate to native mode, maintaining
common source code is impractical.
By using D3x versions of the TNS compilers and D4x and G-series versions of the
native compilers, you can maintain common source code for the D3x, D4x, and
G-series operating system RVUs. (Because of differences between the D20 and D30
TNS compilers, it is too difficult to maintain a common source between the D20 and
D4x and G-series operating system RVUs.)
To maintain a common source, use features available in the D3x, D4x, and G-series
RVUs and features available to TNS and native programs. Features that you cannot
use include:
•
C++ language features that the cfront C++ preprocessor cannot process
•
pTAL language features that the TAL compiler does not support
•
The small-memory model in C and the 16-bit data model in C and C++
•
COBOL85 language features that are not supported by both the COBOL85 and
NMCOBOL compilers
To maintain a common source, you must use:
•
Separate build scripts to run the TNS and native compilers and other tools
•
D3x versions of the TNS C compiler
•
D32.00 or later versions of the COBOL85 compiler
•
D31 or later versions of the TAL compiler
•
Versions of the Guardian procedure external declaration files (EXTDECS and
CEXTDECS) and the C header files that correspond to the RVU
•
COBOL85 dummy files (COBOLEX0, COBOLEX1, COBOLEXT, NMCOBEX0,
NMCOBEX1, and NMCOBEXT)