Skip to content

Commit 33898df

Browse files
committed
Issue #96: Using WxsFiles and OutDir causes build to fail
1 parent de30a95 commit 33898df

1 file changed

Lines changed: 3 additions & 3 deletions

File tree

Source/src/WixSharp/Compiler.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -707,7 +707,7 @@ static string GenerateCandleCommand(Project project, string wxsFile, string outD
707707

708708
// if multiple files are specified candle expect a path for the -out switch
709709
// or no path at all (use current directory)
710-
710+
// note the '\' character must be escaped twice: as a C# string and as a CMD char
711711
if (outDir.IsNotEmpty())
712712
candleCmdLineParams.AppendFormat(" -out \"{0}\\\\\"", outDir);
713713
}
@@ -727,7 +727,7 @@ static string GenerateLightCommand(Project project, string msiFile, string outDi
727727

728728
string fragmentObjectFiles = project.WxsFiles
729729
.Distinct()
730-
.Join(" ", file => "\"" + IO.Path.GetFileNameWithoutExtension(file) + ".wixobj\"");
730+
.Join(" ", file => "\"" + outDir.PathCombine(IO.Path.GetFileNameWithoutExtension(file)) + ".wixobj\"" );
731731

732732
var lightCmdLineParams = new StringBuilder();
733733

@@ -2855,7 +2855,7 @@ static void ProcessCustomActions(Project wProject, XElement product)
28552855
}
28562856

28572857
sequences.ForEach(sequence =>
2858-
sequence.Add(new XElement("Custom",
2858+
sequence.Add(new XElement("Custom",
28592859
new XAttribute("Action", setPropValuesId),
28602860
stepAttr)));
28612861
}

0 commit comments

Comments
 (0)