Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include buildhost deps.json #71597

Merged
merged 3 commits into from
Jan 16, 2024
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,16 @@
<ItemGroup>
<EmbeddedResource Update="WorkspaceMSBuildBuildHostResources.resx" GenerateSource="true" />
</ItemGroup>
<PropertyGroup>
<!-- Force a deps.json to be included when packaging the language server, so we get proper assembly resolution using the directory as a binding path -->
<_UseBuildDependencyFile>true</_UseBuildDependencyFile>
</PropertyGroup>

<!--
This target is used by Microsoft.CodeAnalysis.Workspaces.MSBuild to copy the .deps.json file into its BuildHost subfolder.
The .deps.json file is required for the BuildHost to resolve assemblies using the directory as a binding path
-->
<Target Name="OutputProjectDepsJsonFile" Returns="@(ProjectDepsJsonFile)">
<ItemGroup Condition="'$(TargetFramework)' != 'net472'">
<ProjectDepsJsonFile Include="$(ProjectDepsFilePath)">
<TargetPath>$(ProjectDepsFileName)</TargetPath>
</ProjectDepsJsonFile>
</ItemGroup>
</Target>
</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -117,7 +117,7 @@
</ItemGroup>

<!-- We include Build as a target we invoke to work around https://github.com/dotnet/msbuild/issues/5433 -->
<MSBuild Projects="@(_NetFrameworkBuildHostProjectReference)" Targets="Build;BuiltProjectOutputGroup;ReferenceCopyLocalPathsOutputGroup" Properties="TargetFramework=%(_NetFrameworkBuildHostProjectReference.TargetFramework)">
<MSBuild Projects="@(_NetFrameworkBuildHostProjectReference)" Targets="Build;BuiltProjectOutputGroup;ReferenceCopyLocalPathsOutputGroup;OutputProjectDepsJsonFile" Properties="TargetFramework=%(_NetFrameworkBuildHostProjectReference.TargetFramework)">
<Output TaskParameter="TargetOutputs" ItemName="NetFrameworkBuildHostAssets" />
</MSBuild>

Expand Down
Loading