close
The Wayback Machine - https://web.archive.org/web/20220401234123/https://github.com/dotnet/runtime/pull/67467
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

build: fix corehost.proj dac injection unquoted path #67467

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

Wraith2
Copy link
Contributor

@Wraith2 Wraith2 commented Apr 1, 2022

With a clean current repo running build.cmd resulted in this error:

E:\Programming\csharp7\runtime\src\native\corehost\corehost.proj(41,5): error MSB3073: The command "C:\Program Files\dotnet\dotnet exec E:\Programming\csharp7\runtime\artifacts\bin\coreclr\windows.x64.Debug\InjectResource\InjectResource.dll --bin "E:\Programming\csharp7\runtime\artifacts\bin\coreclr\windows.x64.Debug\/mscordaccore.dll" --image "E:\Programming\csharp7\runtime\artifacts\bin\win-x64.Debug\corehost\/singlefilehost.exe" --name MINIDUMP_EMBEDDED_AUXILIARY_PROVIDER" exited with code 9009. [E:\Programming\csharp7\runtime\src\native\corehost\corehost.proj]

I used the binlog to track that back to PrepareSingleFileHostWithEmbeddedDacCore which has an exec command that uses the systemwide location of dotnet.exe without quoting it. This fixes it.

@msftbot msftbot bot added the community-contribution label Apr 1, 2022
@msftbot
Copy link
Contributor

@msftbot msftbot bot commented Apr 1, 2022

Tagging subscribers to this area: @vitek-karas, @agocke, @VSadov
See info in area-owners.md if you want to be subscribed.

Issue Details

With a clean current repo running build.cmd resulted in this error:

E:\Programming\csharp7\runtime\src\native\corehost\corehost.proj(41,5): error MSB3073: The command "C:\Program Files\dotnet\dotnet exec E:\Programming\csharp7\runtime\artifacts\bin\coreclr\windows.x64.Debug\InjectResource\InjectResource.dll --bin "E:\Programming\csharp7\runtime\artifacts\bin\coreclr\windows.x64.Debug\/mscordaccore.dll" --image "E:\Programming\csharp7\runtime\artifacts\bin\win-x64.Debug\corehost\/singlefilehost.exe" --name MINIDUMP_EMBEDDED_AUXILIARY_PROVIDER" exited with code 9009. [E:\Programming\csharp7\runtime\src\native\corehost\corehost.proj]

I used the binlog to track that back to PrepareSingleFileHostWithEmbeddedDacCore which has an exec command that uses the systemwide location of dotnet.exe without quoting it. This fixes it.

Author: Wraith2
Assignees: -
Labels:

area-Host, community-contribution

Milestone: -

@@ -39,7 +39,7 @@
Condition="'$(RuntimeFlavor)' != 'Mono'">
<Copy SourceFiles="$(SingleFileHostPath);$(SingleFileHostSymbolsPath)" DestinationFiles="$(SingleFileHostDestinationPath);$(SingleFileHostSymbolsPath)" />
<Exec Condition="'$(TargetOS)' == 'windows'"
Command="$(NetCoreRoot)dotnet exec @(InjectResourceTool) --bin &quot;$(DacPath)&quot; --image &quot;$(SingleFileHostDestinationPath)&quot; --name MINIDUMP_EMBEDDED_AUXILIARY_PROVIDER" />
Command="&quot;$(NetCoreRoot)dotnet&quot; exec @(InjectResourceTool) --bin &quot;$(DacPath)&quot; --image &quot;$(SingleFileHostDestinationPath)&quot; --name MINIDUMP_EMBEDDED_AUXILIARY_PROVIDER" />
Copy link
Contributor

@EgorBo EgorBo Apr 1, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

can it use $(DotNetTool) here?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area-Host community-contribution
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants