Some cleanup, and update to make those files usable both as self-executables and...
[blender.git] / release / datafiles / datatoc.py
index 564070dcf9f908889483154c42f0b1a480f02548..f1fce08d7dd18fabb6bde28e1e113cd6d7ebc12e 100755 (executable)
@@ -53,8 +53,8 @@ sys.stdout.write("Making C file <%s>\n" % cname)
 
 filename = filename.split("/")[-1].split("\\")[-1]
 filename = filename.replace(".", "_")
-sys.stdout.write(str(size))
-sys.stdout.write("\n")
+sys.stdout.write("%d\n" % size)
+
 try:
     fpout = open(cname, "w")
 except:
@@ -62,9 +62,9 @@ except:
     sys.exit(1)
 
 fpout.write("/* DataToC output of file <%s> */\n\n" % filename)
-fpout.write("int datatoc_%s_size= %d;\n" % (filename, size))
+fpout.write("int datatoc_%s_size = %d;\n" % (filename, size))
 
-fpout.write("char datatoc_%s[]= {\n" % filename)
+fpout.write("char datatoc_%s[] = {\n" % filename)
 
 while size > 0:
     size -= 1