Restoring support for not merging all kernels into a single file.
@@ -186,6 +186,9 @@ def writeSolutionsAndKernels(outputPath, problemTypes, solutions, kernels, kerne
kernelHeaderFile.write("\n\n")
else:
kernelHeaderFile.write("#include <string>\n")
+ else:
+ kernelSourceFile = None
+ kernelHeaderFile = None
kernelsWithBuildErrs = {}
@@ -264,14 +267,14 @@ def writeSolutionsAndKernels(outputPath, problemTypes, solutions, kernels, kerne
##############################################################################
# Write Solutions
##############################################################################
- if globalParameters["MergeFiles"]:
solutionSourceFile = open(os.path.join(outputPath, \
"Solutions.cpp"), "w")
solutionHeaderFile = open(os.path.join(outputPath, \
"Solutions.h"), "w")
- if globalParameters["MergeFiles"]:
solutionSourceFile.write(CHeader)
solutionHeaderFile.write(CHeader)
+
+ if globalParameters["MergeFiles"]:
solutionSourceFile.write("#include \"Solutions.h\"\n")
solutionSourceFile.write("#include <algorithm>\n")
solutionHeaderFile.write("#include \"TensileTypes.h\"\n")
