25 %macro _runProgramSpawned(i_program =
27 ,i_generateMcoverage = 0
31 %local l_cmdFile l_parms l_parenthesis l_tcgFilePath l_tcgOptionsString l_tcgOptionsStringLINUX l_rc l_macname;
32 %let l_macname=&sysmacroname.;
35 %let l_cmdFile=%sysfunc(pathname(work))/prep_sasuser.cmd;
38 PUT
"&g_removedir ""%sysfunc(pathname(work))/sasuser""&g_endcommand";
39 PUT
"&g_makedir ""%sysfunc(pathname(work))/sasuser""&g_endcommand";
40 %IF %length(&g_sasuser) %THEN %DO;
41 PUT
"&g_copydir ""&g_sasuser"" ""%sysfunc(pathname(work))/sasuser""&g_endcommand";
44 %_executeCMDFile(&l_cmdFile.);
45 %LET l_rc=%_delfile(&l_cmdFile.);
48 %let l_cmdFile=%sysfunc(pathname(work))/_runprogramspawned.cmd;
51 %IF
"&g_autoexec" NE
"" %THEN %DO;
52 %LET l_parms=&l_parms -autoexec
""&g_autoexec
"";
54 %IF
"&g_sascfg" NE
"" %THEN %DO;
55 options SET=SASCFGPATH
"&g_sascfg.";
58 %IF &i_generateMcoverage. EQ 1 %THEN %DO;
61 %LET l_tcgFilePath = &g_log./&i_scnid..tcg;
62 %LET l_tcgOptionsString = options mcoverage mcoverageloc=
'%sysfunc(tranwrd(&l_tcgFilePath.,%str( ), %str(\ )))';
67 _sCmdString LENGTH = $32000
77 !!
"-sysin %sysfunc(tranwrd(&i_program., %str( ), %str(\ ))) "
78 !!
"-initstmt "" &l_tcgOptionsString.; %nrstr(%%_scenario%(io_target=)&g_target%nrstr(%);%%let g_scnid=)&i_scnid.;"" "
79 !!
"-log %sysfunc(tranwrd(&g_log/&i_scnid..log, %str( ), %str(\ ))) "
80 !!
"-print %sysfunc(tranwrd(&g_testout/&i_scnid..lst, %str( ), %str(\ ))) "
84 !!
"-mcompilenote all "
85 !!
"-sasautos %sysfunc(tranwrd(&g_sasunit, %str( ), %str(\ ))) "
86 !!
"-sasuser %sysfunc(pathname(work))/sasuser "
87 !!
"-termstmt ""%nrstr(%%_termScenario())"" "
92 %_executeCMDFile(&l_cmdFile.);
93 %LET &r_sysrc. = &sysrc.;
94 %LET l_rc=%_delfile(&l_cmdFile.);
97 %let l_cmdFile=%sysfunc(pathname(work))/del_sasuser.cmd;
100 PUT
"&g_removedir ""%sysfunc(pathname(work))/sasuser""&g_endcommand";
102 %_executeCMDFile(&l_cmdFile.);
103 %LET l_rc=%_delfile(&l_cmdFile.);
105 %mend _runprogramspawned;