diff options
-rw-r--r-- | share/qbs/modules/cpp/keil.js | 30 |
1 files changed, 17 insertions, 13 deletions
diff --git a/share/qbs/modules/cpp/keil.js b/share/qbs/modules/cpp/keil.js index 27e4e12d7..67b07dfe5 100644 --- a/share/qbs/modules/cpp/keil.js +++ b/share/qbs/modules/cpp/keil.js @@ -661,15 +661,16 @@ function compilerFlags(project, product, input, outputs, explicitlyDependsOn) { args.push(input.filePath); // Output. - args.push("OBJECT (" + outputs.obj[0].filePath + ")"); + args.push("OBJECT(" + FileInfo.toWindowsSeparators(outputs.obj[0].filePath) + ")"); // Defines. if (allDefines.length > 0) - args = args.concat("DEFINE (" + allDefines.join(",") + ")"); + args = args.concat("DEFINE(" + allDefines.join(",") + ")"); // Includes. if (allIncludePaths.length > 0) - args = args.concat("INCDIR (" + allIncludePaths.join(";") + ")"); + args = args.concat("INCDIR(" + allIncludePaths.map(function(path) { + return FileInfo.toWindowsSeparators(path); }).join(";") + ")"); // Debug information flags. if (input.cpp.debugInformation) @@ -704,7 +705,7 @@ function compilerFlags(project, product, input, outputs, explicitlyDependsOn) { if (!input.cpp.generateCompilerListingFiles) args.push("NOPRINT"); else - args.push("PRINT(" + outputs.lst[0].filePath + ")"); + args.push("PRINT(" + FileInfo.toWindowsSeparators(outputs.lst[0].filePath) + ")"); } else if (isArmArchitecture(architecture)) { // Input. args.push("-c", input.filePath); @@ -895,15 +896,16 @@ function assemblerFlags(project, product, input, outputs, explicitlyDependsOn) { args.push(input.filePath); // Output. - args.push("OBJECT (" + outputs.obj[0].filePath + ")"); + args.push("OBJECT(" + FileInfo.toWindowsSeparators(outputs.obj[0].filePath) + ")"); // Defines. if (allDefines.length > 0) - args = args.concat("DEFINE (" + allDefines.join(",") + ")"); + args = args.concat("DEFINE(" + allDefines.join(",") + ")"); // Includes. if (allIncludePaths.length > 0) - args = args.concat("INCDIR (" + adjusted.join(";") + ")"); + args = args.concat("INCDIR(" + allIncludePaths.map(function(path) { + return FileInfo.toWindowsSeparators(path); }).join(";") + ")"); // Debug information flags. if (input.cpp.debugInformation) @@ -916,7 +918,7 @@ function assemblerFlags(project, product, input, outputs, explicitlyDependsOn) { if (!input.cpp.generateAssemblerListingFiles) args.push("NOPRINT"); else - args.push("PRINT(" + outputs.lst[0].filePath + ")"); + args.push("PRINT(" + FileInfo.toWindowsSeparators(outputs.lst[0].filePath) + ")"); } else if (isArmArchitecture(architecture)) { // Input. args.push(input.filePath); @@ -1009,16 +1011,17 @@ function linkerFlags(project, product, inputs, outputs) { // Add all input objects as arguments (application and library object files). if (allObjectPaths.length > 0) - args = args.concat(allObjectPaths.join(",")); + args = args.concat(allObjectPaths.map(function(path) { + return FileInfo.toWindowsSeparators(path); }).join(",")); // Output. - args.push("TO", outputs.application[0].filePath); + args.push("TO", FileInfo.toWindowsSeparators(outputs.application[0].filePath)); // Map file generation flag. if (!product.cpp.generateLinkerMapFile) args.push("NOPRINT"); else - args.push("PRINT(" + outputs.mem_map[0].filePath + ")"); + args.push("PRINT(" + FileInfo.toWindowsSeparators(outputs.mem_map[0].filePath) + ")"); } else if (isArmArchitecture(architecture)) { // Inputs. if (inputs.obj) @@ -1077,10 +1080,11 @@ function archiverFlags(project, product, inputs, outputs) { // Add all input objects as arguments. if (allObjectPaths.length > 0) - args = args.concat(allObjectPaths.join(",")); + args = args.concat(allObjectPaths.map(function(path) { + return FileInfo.toWindowsSeparators(path); }).join(",")); // Output. - args.push("TO", outputs.staticlibrary[0].filePath); + args.push("TO", FileInfo.toWindowsSeparators(outputs.staticlibrary[0].filePath)); } else if (isArmArchitecture(architecture)) { // Note: The ARM archiver command line expect the output file // first, and then a set of input objects. |