Sorry for the late reply. I've been trying to find the documentation that talks about calling C/C++ library functions from other HLL code, such as Cobol. All I found was information about doing interlanguage calls, but this is all about "own" code, not the functions that the C/C++ runtime library provides.
>Subsequent COBOL V5.2 testing showed that including CEESG003 at link/bind time >also works for COBOL V5.2 dynamic call. SYS1.SCEELKED is still required in >STEPLIB/JOBLIB/LINKLIST for dynamic calls to work. Language Environment uses signature CSECTs CEESGnnn to represent those LE supported HLL languages that are being used in the current load module. When a new (or first) load module is loaded into the enclave, LE looks for the signature CSECTs that are present in the load module, compares that with the list of LE languages already initialized, and then initializes any new language. This process, amongst other things, lets the pointer in the CAA point to the correct structures. Pardon my ignorance, I'm not fluent in Cobol, but the code you showed does not seem to tell the compiler that the dynamically called routine CUSERID is a C routine. Therefore the compiler does not include CSECT CEESG003. Is there a means in Cobol to declare a certain dynamically called routine is written in C, so that the compiler would know? The stubs in SYS1.SCEELKED are not complete load modules, they are intended to be used in the link/bind step (yes, I'm still eager to find this documented explicitly). The do not the signature CSECTs, so LE has not handle to recognize a new language is to be initialized when one of those routines is dynamically called. Apart from all that, I still do not understand why it is so important to you to have those calls be dynamic calls. When you code a C routine, you are using a lot of the runtime library functions, aren't you? All of those are statically bound. If there was danger of missing an important LE service update with those, IBM would need to mark those PTFs with a HOLD action "Must rebind any and alll your programs using C functions". Not something I can imagine to ever happen. I would not have a good feeling with manually including signature CSECTs and running with SYS1.SCEELKED in the steplib concatention. -- Peter Hunkeler ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
