Skip to content

Dotnet build fails for Windows arm64 #42393

@kunalspathak

Description

@kunalspathak

Version Used:
Microsoft (R) Visual C# Compiler version 3.6.0-2.20153.4 (6f2112b)

** Platform **
Windows ARM64 netcoreapp5.0

Steps to Reproduce:

  1. dotnet new console
  2. dotnet build created_project.csproj

Expected Behavior:
Project builds

Actual Behavior:

CSC : error CS0041: Unexpected error writing debug information -- 'An attempt was made to load a program with an incorrect format. (0x8007000B)

The reason being that CSC tries to load amd64 version of Microsoft.DiaSymReader.Native.amd64.dll to write symbols.

@jaredpar suggested to use /debug:pdbonly which makes it works, but I am trying to run BenchmarkDotNet which builds project on fly and it doesn't pass that flag to individual benchmark project causing it to fail with the above error.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions