Browse files

Handle output file names surrounded by quotation marks

It seems that Visual Studio tends to generate response files which specify
the output file name in quotation marks. We don't want those, so strip them
if they are given.
  • Loading branch information...
1 parent fc7c7b6 commit 9deea04d84ca3ab880afffda421b87761cb51e2c @frerich committed Dec 22, 2011
Showing with 6 additions and 0 deletions.
  1. +6 −0
@@ -353,6 +353,12 @@ def analyzeCommandLine(cmdline):
outputFile = os.path.join(os.getcwd(),
os.path.splitext(srcFileName)[0] + ".obj")
+ # Strip quotes around file names; seems to happen with source files
+ # with spaces in their names specified via a response file generated
+ # by Visual Studio.
+ if outputFile.startswith('"') and outputFile.endswith('"'):
+ outputFile = outputFile[1:-1]
printTraceStatement("Compiler output file: '%s'" % outputFile)
return AnalysisResult.Ok, sourceFiles[0], outputFile

0 comments on commit 9deea04

Please sign in to comment.