IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

Running a cprogram in mainframe


IBM Mainframe Forums -> All Other Mainframe Topics
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
yoonuskv

New User


Joined: 07 Apr 2006
Posts: 3

PostPosted: Fri Apr 07, 2006 6:02 pm
Reply with quote

I am trying to run a simple c program using catalogued procedure EDCCLG

here is the jcl
Code:

//A398614A JOB (P944,#711235),'C/C++ - COMPILE',       
//        CLASS=R,MSGCLASS=X,NOTIFY=&SYSUID,           
// USER=A398614,PASSWORD=                               
//*                                                     
//*-----------------------------------------------------
//* COMPILE THE C SOURCE.                               
//*-----------------------------------------------------
//*                                                     
//C0010308  EXEC EDCCLG,                               
//          INFILE='A398614.TEST.PROG(CPROG)',         
//          OUTFILE='A398614.LOAD(CPROG)',             
//* CPARM='OPT(0) NOSEQ NOMAR RENT',                   
//            GPARM='STACK(10K)/'                       
//*         SYSOUT6='*'                                 
//LKED.SYSLMOD  DD  DSNAME=A398614.LOAD(CPROG),DISP=SHR
//COMPILE.USERLIB DD DSNAME=SYS1.CEE.SCEEH.H,DISP=SHR   


The compilation and link edit is success but the execution is failing.
its abending witha soc7 .
Its a simple c program with a printf statement.

DO i need anything extra to the jcl?

Has anybody tried it out?
Back to top
View user's profile Send private message
martin9

Active User


Joined: 01 Mar 2006
Posts: 290
Location: Basel, Switzerland

PostPosted: Fri Apr 07, 2006 6:50 pm
Reply with quote

hy yoonuskv,

you know, s0c7 is a data exception,
this you have to solve in your program yourself,
this is a run time abend.
if you would have any s0c4, i.e. storage protection,
or something similar....

look at the variable which contains the faulty data...

martin9
Back to top
View user's profile Send private message
yoonuskv

New User


Joined: 07 Apr 2006
Posts: 3

PostPosted: Fri Apr 07, 2006 7:23 pm
Reply with quote

Thank You martin for ur reply

but i would like to point out that there is nothing much in the program

here is the program

#include"stdio.h"
MAIN() {
printf("hi") }

So i doubt this error is coming becoz of something ese
Back to top
View user's profile Send private message
yoonuskv

New User


Joined: 07 Apr 2006
Posts: 3

PostPosted: Fri Apr 07, 2006 7:26 pm
Reply with quote

Hi martin

i would like to add one more thing

i left out the ; in the program

but still it is giving the same error.

can u help me out pls
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> All Other Mainframe Topics

 


Similar Topics
Topic Forum Replies
No new posts FTP VB File from Mainframe retaining ... JCL & VSAM 8
No new posts Running REXX through JOB CLIST & REXX 13
No new posts Mainframe openings in Techmahnidra fo... Mainframe Jobs 0
No new posts Running a Job with the Default User ID JCL & VSAM 2
No new posts Error while running web tool kit REXX... CLIST & REXX 5
Search our Forums:

Back to Top