opencl: fix MSVC builds (string length error)

This commit is contained in:
Max Krasnyansky 2024-12-12 22:03:27 -08:00
parent b25a4caaf4
commit b41b6e679f

View file

@ -2,7 +2,7 @@
import sys
import logging
logger = logging.getLogger("opencl-embed-kernerl")
logger = logging.getLogger("opencl-embed-kernel")
def main():
@ -15,9 +15,8 @@ def main():
ifile = open(sys.argv[1], "r")
ofile = open(sys.argv[2], "w")
ofile.write("R\"(\n\n")
ofile.write(ifile.read())
ofile.write("\n)\"")
for i in ifile:
ofile.write('R"({})"\n'.format(i))
ifile.close()
ofile.close()