diff options
Diffstat (limited to 'Sluift/SConscript')
| -rw-r--r-- | Sluift/SConscript | 5 | 
1 files changed, 2 insertions, 3 deletions
diff --git a/Sluift/SConscript b/Sluift/SConscript index 5e0a030..a2b6748 100644 --- a/Sluift/SConscript +++ b/Sluift/SConscript @@ -73,9 +73,8 @@ elif env["SCONS_STAGE"] == "build" :  		data = f.read()  		f.close() -		data_bytes = bytearray(data)  		f = open(target[0].abspath, "w")  		f.write('#include <stddef.h>\n') -		f.write('const size_t ' + source[0].name.replace(".", "_") + "_size = " + str(len(data_bytes)) + ";\n") -		f.write('const char ' + source[0].name.replace(".", "_") + "[] = {" + ", ".join([str(b) for b in data_bytes]) + "};\n") +		f.write('const size_t ' + source[0].name.replace(".", "_") + "_size = " + str(len(data)) + ";\n") +		f.write('const char ' + source[0].name.replace(".", "_") + "[] = {" + ", ".join([str(ord(c)) for c in data]) + "};\n")  		f.close()  	sluift_env.Command("core.c", ["core.lua"], env.Action(generate_embedded_lua, cmdstr="$GENCOMSTR"))  | 
 Swift