Skip to content

Commit

Permalink
Fixed removal of dll references that report IsWinmdFile == true (#533)
Browse files Browse the repository at this point in the history
  • Loading branch information
Scottj1s authored Oct 21, 2020
1 parent fc55163 commit af63025
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions nuget/Microsoft.Windows.CsWinRT.targets
Original file line number Diff line number Diff line change
Expand Up @@ -27,11 +27,11 @@ Copyright (C) Microsoft Corporation. All rights reserved.
<Target Name="CsWinRTRemoveWinMDReferences" BeforeTargets="ResolveReferences;BeforeCompile" AfterTargets="AfterResolveReferences">
<ItemGroup>
<!--Move winmd references into private item group to prevent subsequent winmd reference errors-->
<CsWinRTRemovedReferences Include="@(ReferencePath)" Condition="'%(ReferencePath.WinMDFile)' == 'true'" />
<CsWinRTRemovedReferences Include="@(ReferencePath)" Condition="'%(ReferencePath.Extension)' == '.winmd'" />
<CsWinRTInputs Include="@(CsWinRTRemovedReferences)"/>

<!--Prevent NETSDK1130 errors from winmd references-->
<ReferencePath Remove="@(ReferencePath)" Condition="'%(ReferencePath.WinMDFile)' == 'true'" />
<ReferencePath Remove="@(ReferencePath)" Condition="'%(ReferencePath.Extension)' == '.winmd'" />
<ReferencePathWithRefAssemblies Remove="@(CsWinRTRemovedReferences)"
Condition="'%(CsWinRTRemovedReferences.Filename)%(CsWinRTRemovedReferences.Extension)' == '%(ReferencePathWithRefAssemblies.Filename)%(ReferencePathWithRefAssemblies.Extension)'" />
<!--Do not publish projection source winmds -->
Expand Down

0 comments on commit af63025

Please sign in to comment.