Skip to content

Commit

Permalink
Move VSIX build workaround from ILSpy.csproj to ILSpy.AddIn.csproj.
Browse files Browse the repository at this point in the history
Fix #1400 by adding ILSpy.BamlDecompiler.Plugin.dll to the workaround file list.
  • Loading branch information
siegfriedpammer committed Jan 21, 2019
1 parent 96f7a4c commit e6e8fbe
Show file tree
Hide file tree
Showing 3 changed files with 36 additions and 34 deletions.
39 changes: 32 additions & 7 deletions ILSpy.AddIn/ILSpy.AddIn.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -103,13 +103,42 @@
</EmbeddedResource>
</ItemGroup>

<!--
BEGIN WORKAROUND:
Nuget packages do not get added to the vsix automatically.
(related to https://github.com/icsharpcode/ILSpy/issues/511)
-->
<PropertyGroup>
<ILSpyBuildPath>..\ILSpy\bin\$(Configuration)\$(TargetFramework)\</ILSpyBuildPath>
</PropertyGroup>

<ItemGroup>
<AdditionalDependencies Include="$(ILSpyBuildPath)System.ValueTuple.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Collections.Immutable.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Composition.AttributedModel.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Composition.Convention.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Composition.Hosting.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Composition.Runtime.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Composition.TypedParts.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Threading.Tasks.Dataflow.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)ICSharpCode.AvalonEdit.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)Humanizer.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)System.Reflection.Metadata.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)Microsoft.VisualStudio.Composition.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)Microsoft.VisualStudio.Validation.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)Mono.Cecil.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)Mono.Cecil.Pdb.dll" />
<AdditionalDependencies Include="$(ILSpyBuildPath)ILSpy.BamlDecompiler.Plugin.dll" />
</ItemGroup>

<ItemGroup>
<Content Include="Packages/*">
<Content Include="@(AdditionalDependencies)">
<IncludeInVSIX>true</IncludeInVSIX>
<VSIXSubPath>\</VSIXSubPath>
</Content>
</Content>
</ItemGroup>

<!-- END WORKAROUND -->

<ItemGroup>
<None Include="ILSpyAddIn.vsct" />
<None Include="source.extension.vsixmanifest.template" />
Expand Down Expand Up @@ -162,8 +191,4 @@
<ProjectReference Update="@(ProjectReference)" Name="%(Filename)" />
</ItemGroup>

<ItemGroup>
<Folder Include="Packages\" />
</ItemGroup>

</Project>
5 changes: 4 additions & 1 deletion ILSpy.sln
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,13 @@ EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILSpy.BamlDecompiler.Tests", "ILSpy.BamlDecompiler.Tests\ILSpy.BamlDecompiler.Tests.csproj", "{1169E6D1-1899-43D4-A500-07CE4235B388}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILSpy.AddIn", "ILSpy.AddIn\ILSpy.AddIn.csproj", "{9D7BE6C0-B7B3-4A50-A54E-18A2D84A3384}"
ProjectSection(ProjectDependencies) = postProject
{A6BAD2BA-76BA-461C-8B6D-418607591247} = {A6BAD2BA-76BA-461C-8B6D-418607591247}
EndProjectSection
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ICSharpCode.Decompiler.PdbProvider.Cecil", "ICSharpCode.Decompiler.PdbProvider.Cecil\ICSharpCode.Decompiler.PdbProvider.Cecil.csproj", "{B85A155A-9DD6-43BC-A624-2D8EC773D71F}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "ILSpy.Tests", "ILSpy.Tests\ILSpy.Tests.csproj", "{B51C6636-B8D1-4200-9869-08F2689DE6C2}"
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ILSpy.Tests", "ILSpy.Tests\ILSpy.Tests.csproj", "{B51C6636-B8D1-4200-9869-08F2689DE6C2}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Expand Down
26 changes: 0 additions & 26 deletions ILSpy/ILSpy.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -389,32 +389,6 @@
<None Include="@(Resource)" />
</ItemGroup>

<!--
Workaround: nuget packages do not get added to the vsix automatically.
Copy them to a local folder and then include them as Content-items in the AddIn.
(related to https://github.com/icsharpcode/ILSpy/issues/511)
-->
<Target Name="CopyNugetPackagesToAddIn" AfterTargets="PostBuildEvent">
<ItemGroup>
<NuGetPackagesToCopy Include="$(TargetDir)System.ValueTuple.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Collections.Immutable.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Composition.AttributedModel.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Composition.Convention.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Composition.Hosting.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Composition.Runtime.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Composition.TypedParts.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Threading.Tasks.Dataflow.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)ICSharpCode.AvalonEdit.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)Humanizer.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)System.Reflection.Metadata.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)Microsoft.VisualStudio.Composition.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)Microsoft.VisualStudio.Validation.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)Mono.Cecil.dll" />
<NuGetPackagesToCopy Include="$(TargetDir)Mono.Cecil.Pdb.dll" />
</ItemGroup>
<Copy SourceFiles="@(NuGetPackagesToCopy)" DestinationFolder="..\ILSpy.AddIn\packages" />
</Target>

<PropertyGroup>
<VCBasePath>$(MSBuildToolsPath)\..\..\..\VC\</VCBasePath>
<VCToolsVersionPropsFile>$(VCBasePath)Auxiliary\Build\Microsoft.VCToolsVersion.default.props</VCToolsVersionPropsFile>
Expand Down

0 comments on commit e6e8fbe

Please sign in to comment.