On Thu, Apr 6, 2017 at 3:53 PM, Farley, Peter x23353 < [email protected]> wrote:
> John, > > Not "nutso" at all, just very cool. > > I notice you are using "static" calls (quoted literal program names) in > upper case. Does that mean that you statically link the C subroutines with > your program? Does it require using any non-default compiler options? > Assuming you are using COBOL V4.2 or earlier, do you have to use PDSE's for > the load modules because of the C subroutines? > Well, I originally used a DYNAM compile parm. But when I did the cuserid() CALL, I got an S0C1. When I did a static link, I got what I was looking for. I haven't tried to track down the cause of the S0C1 yet. Good question about the PDS/E. I'm using COBOL 4.2 on z/OS 1.12 for my testing. My testing is done using a UNIX shell. I use the "cob2" command to compile my programs, then test them right there. I did a quickie test copying my UNIX resident program to a standard PDS data set using "cp -X". It ran fine, so I don't think that a PDSE is required. It may be for C++, but doesn't appear to be > > I am quite excited if this is all I have to do to use C library routines, > but static links make me uneasy, especially for system-level runtime code > like the C library functions. > > Peter > > -- "Irrigation of the land with seawater desalinated by fusion power is ancient. It's called 'rain'." -- Michael McClary, in alt.fusion Maranatha! <>< John McKown ---------------------------------------------------------------------- For IBM-MAIN subscribe / signoff / archive access instructions, send email to [email protected] with the message: INFO IBM-MAIN
