Chapter Contents

Previous

Next
Using the indep Option for Interlanguage Communication

Link-Editing Multilanguage Programs

If your program is to be executed using the normal C framework, use the normal C resident library files as your autocall libraries (SASC.BASEOBJ and SASC.STDOBJ under OS/390, LC370BAS TXTLIB and LC370STD TXTLIB under CMS). These libraries include versions of L$UMAIN, L$UEXIT, and so on, suitable for use with the full execution framework. For example, this version of L$UMAIN creates a complete C execution framework, allowing the full use of all library functions.

Do not use the SPE object library when link-editing a program that is to execute with the normal C framework because you then obtain versions of L$UMAIN and L$UEXIT that are incompatible with the normal C framework.

Note that when you use the normal C framework, L$UPREP is the only interlanguage communication routine that can be modified. If you have modified L$UPREP, you can either replace the copy in the base library, as described earlier, or you can store the modified version in a separate library and include that library in the GLOBAL TXTLIB list (CMS) or SYSLIB concatenation (OS/390) before any other autocall libraries. (The latter is recommended for safety.) The sample L$UPREP can be used with either the full framework or with SPE. If you modify L$UPREP so that it depends on one of these two frameworks, be careful to always link with the version that is appropriate for your application.

If you write an L$URTOP routine, its object code also can be stored in the base resident library. However, usually this routine is highly application-specific, so it is probably more appropriate to store it in a separate library.


Location of indep Libraries

The sample source code for L$UPREP can be found in LSU MACLIB (CMS) or SASC.SOURCE (OS/390). The object code is in LC370SPE TXTLIB (CMS) or SASC.SPEOBJ (OS/390). The macro library is LCUSER MACLIB (CMS) and SASC.MACLIBA (OS/390). The library contains macros such as L$UCENV and L$UPENV. The macro library also contains members CRAB, DSA, and CPROLOG, which provide mappings of the minimal CRAB, the DSA (Dynamic Save Area), and the compiler-generated prolog code, respectively, which may be helpful in understanding the sample routines or in coding new ones.


Chapter Contents

Previous

Next

Top of Page

Copyright © 2001 by SAS Institute Inc., Cary, NC, USA. All rights reserved.