CsWinRT icon indicating copy to clipboard operation
CsWinRT copied to clipboard

Error when debug symbols are embedded vs. in pdb file

Open BrianPeek opened this issue 2 years ago • 0 comments

Describe the bug In NET6, when Debug Symbols are "Embedded in DLL/EXE" instead of in a "PDB file", the IIDOptimizer step will fail with

Microsoft.Windows.CsWinRT.IIDOptimizer.targets(84,5): error MSB3030: Could not copy the file "<path>\<output>.pdb" because it was not found.

To Reproduce

  1. In project properties, change the Debug Symbols option to "Embedded in DLL/EXE", or in the csproj file, add the following: <DebugType>embedded</DebugType>
  2. Build the project

Expected behavior

Successful build

Version Info 1.5.0

Additional context Workaround: change the Debug Symbols setting to "PDB file" or use <DebugType>portable</DebugType> in the csproj file

BrianPeek avatar Feb 15 '22 20:02 BrianPeek