mirror of
https://github.com/sasjs/core.git
synced 2025-12-10 05:54:35 +00:00
fix: avoiding lua compilation issues by setting wide enough lrecl
This commit is contained in:
7
build.py
7
build.py
@@ -22,8 +22,15 @@ for file in files:
|
||||
for line in infile:
|
||||
ml.write(" put '" + line.rstrip().replace("'", "''") + " ';\n")
|
||||
ml.write("run;\n\n")
|
||||
|
||||
ml.write("/* ensure big enough lrecl to avoid lua compilation issues */\n")
|
||||
ml.write("%local optval;\n")
|
||||
ml.write("%let optval=%sysfunc(getoption(lrecl));\n")
|
||||
ml.write("options lrecl=1024;\n\n")
|
||||
ml.write("/* execute the lua code by using a .lua extension */\n")
|
||||
ml.write("%inc \"%sysfunc(pathname(work))/" +
|
||||
name + ".lua\" /source2;\n\n")
|
||||
ml.write("options lrecl=&optval;\n\n")
|
||||
ml.write("%mend " + name + ";\n")
|
||||
|
||||
ml.close()
|
||||
|
||||
@@ -39,6 +39,14 @@ data _null_;
|
||||
put 'io.close(file) ';
|
||||
run;
|
||||
|
||||
/* ensure big enough lrecl to avoid lua compilation issues */
|
||||
%local optval;
|
||||
%let optval=%sysfunc(getoption(lrecl));
|
||||
options lrecl=1024;
|
||||
|
||||
/* execute the lua code by using a .lua extension */
|
||||
%inc "%sysfunc(pathname(work))/ml_gsubfile.lua" /source2;
|
||||
|
||||
options lrecl=&optval;
|
||||
|
||||
%mend ml_gsubfile;
|
||||
|
||||
@@ -389,6 +389,14 @@ data _null_;
|
||||
put '-- JSON.LUA ENDS HERE ';
|
||||
run;
|
||||
|
||||
/* ensure big enough lrecl to avoid lua compilation issues */
|
||||
%local optval;
|
||||
%let optval=%sysfunc(getoption(lrecl));
|
||||
options lrecl=1024;
|
||||
|
||||
/* execute the lua code by using a .lua extension */
|
||||
%inc "%sysfunc(pathname(work))/ml_json.lua" /source2;
|
||||
|
||||
options lrecl=&optval;
|
||||
|
||||
%mend ml_json;
|
||||
|
||||
Reference in New Issue
Block a user