Can't - the C compiler isn't licensed. John McKown
Systems Engineer IV IT Administrative Services Group HealthMarkets(r) 9151 Boulevard 26 * N. Richland Hills * TX 76010 (817) 255-3225 phone * [email protected] * www.HealthMarkets.com Confidentiality Notice: This e-mail message may contain confidential or proprietary information. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message. HealthMarkets(r) is the brand name for products underwritten and issued by the insurance subsidiaries of HealthMarkets, Inc. -The Chesapeake Life Insurance Company(r), Mid-West National Life Insurance Company of TennesseeSM and The MEGA Life and Health Insurance Company.SM > -----Original Message----- > From: IBM Mainframe Assembler List > [mailto:[email protected]] On Behalf Of Farley, > Peter x23353 > Sent: Friday, October 14, 2011 11:31 AM > To: [email protected] > Subject: Re: Need simple example - Calling c subroutine like > printf from HLASM program > > John, if you are playing with C subroutines and you don't > need anything fancy from the C library, try out the METALC > option of the C compiler. It generates HLASM code that you > then assemble into a load module, so you get to see real > assembler calling the METALC equivalents of the C library functions. > > Most of the more complex METALC functions are loaded in (I > think) LPA/ELPA or somewhere resident anyway and are accessed > via a z/OS-resident vector list, so they (usually) don't get > linked in. Some functions are implemented with generated > inline code (like memcpy). > > Plus using the OPT, ARCH and TUNE compiler parameters allows > you to take advantage of the C compiler's optimization code, > including some pretty cool AGI (address generation interlock) > avoidance. > > Only a subset of C library functions are supported by METALC, > but they are generally the most useful ones. > > HTH > > Peter > > > -----Original Message----- > > From: IBM Mainframe Assembler List [mailto:ASSEMBLER- > > [email protected]] On Behalf Of McKown, John > > Sent: Friday, October 14, 2011 9:33 AM > > To: [email protected] > > Subject: Need simple example - Calling c subroutine like > printf from HLASM > > program > > > > I know that I've seen somebody do this before. But I cannot > remember how > > they did it. Does anybody have a code snippet that shows > how to call a C > > subroutine like sprintf() or strncmp() from HLASM? Also the > compile & link > > JCL would be appreciated. I've tried reading the LE manuals > and the C > > manuals, but I'm just not finding it. > -- > > > This message and any attachments are intended only for the > use of the addressee and may contain information that is > privileged and confidential. If the reader of the message is > not the intended recipient or an authorized representative of > the intended recipient, you are hereby notified that any > dissemination of this communication is strictly prohibited. > If you have received this communication in error, please > notify us immediately by e-mail and delete the message and > any attachments from your system. > >
