Skip to content

Commit

Permalink
Net Core - SelfContained/PublishSingleFile exclude CefSharp.BrowserSu…
Browse files Browse the repository at this point in the history
…bprocess.runtimeconfig.json

For SelfContained and PublishSingleFile we remove the CefSharp.BrowserSubprocess.runtimeconfig.json file so
the BrowserSubprocess runs using the packages .net runtime

Issue #3407
  • Loading branch information
amaitland committed Feb 25, 2021
1 parent a5d5afe commit 34b17bd
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions NuGet/PackageReference/CefSharp.Common.NETCore.targets
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<!--
For SelfContained and PublishSingleFile we remove the CefSharp.BrowserSubprocess.runtimeconfig.json file so
the BrowserSubprocess runs using the packages .net runtime
-->
<Target Name="CefSharpExcludeBrowserSubprocessRuntimeConfigAfterResolveAssemblyReferences" AfterTargets="ResolveAssemblyReferences" Condition="'$(RuntimeIdentifier)' != '' AND ('$(SelfContained)' == 'true' OR '$(PublishSingleFile)' == 'true')">
<PropertyGroup>
<_CefSharpBrowserSubProcessRuntimeConfig>$([System.IO.Path]::GetFullPath('$(MSBuildThisFileDirectory)..\runtimes\$(RuntimeIdentifier)\native\CefSharp.BrowserSubprocess.runtimeconfig.json'))</_CefSharpBrowserSubProcessRuntimeConfig>
</PropertyGroup>
<ItemGroup>
<ReferenceCopyLocalPaths Remove="$(_CefSharpBrowserSubProcessRuntimeConfig)" />
</ItemGroup>
</Target>

<Choose>
<When Condition="$(RuntimeIdentifier.StartsWith('win')) and $(RuntimeIdentifier.Contains('-x64'))">
<ItemGroup>
Expand Down

0 comments on commit 34b17bd

Please sign in to comment.