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

PublishReadyToRunComposite and PublishReadyToRunUseCrossgen2 fails #22067

Closed
ocalvo opened this issue Oct 14, 2021 · 1 comment
Closed

PublishReadyToRunComposite and PublishReadyToRunUseCrossgen2 fails #22067

ocalvo opened this issue Oct 14, 2021 · 1 comment

Comments

@ocalvo
Copy link

ocalvo commented Oct 14, 2021

Describe the bug

When using this publishing profile:

  <PropertyGroup>
    <PublishProtocol>FileSystem</PublishProtocol>
    <Platform>arm64</Platform>
    <RuntimeIdentifier>win10-arm64</RuntimeIdentifier>
    <PublishDir>bin\$(Configuration)\$(TargetFramework)\$(RuntimeIdentifier)\publish\</PublishDir>
    <SelfContained>true</SelfContained>
    <PublishSingleFile>False</PublishSingleFile>
    <PublishReadyToRun>True</PublishReadyToRun>
    <PublishReadyToRunUseCrossgen2>True</PublishReadyToRunUseCrossgen2>
    <PublishReadyToRunComposite>True</PublishReadyToRunComposite>
    <PublishTrimmed>False</PublishTrimmed>
  </PropertyGroup>

Build fails with:

C:\Program Files\dotnet\sdk\5.0.402\Sdks\Microsoft.NET.Sdk\targets\Microsoft.NET.Publish.targets(316,5): error NETSDK1095: Optimizing assemblies for performance is not supported for the selected target p
latform or architecture. Please verify you are using a supported runtime identifier, or set the PublishReadyToRun property to false. [C:\src\WinUI-Samples\Samples\AllSamples\MyApp\MyApp.csproj]

To Reproduce

  1. Remove these comments:
    1.1. arm64
    1.2. x64
    1.3. x86
  2. Execute build

Exceptions (if any)

Further technical details

  • Include the output of dotnet --info : 5.0.402
  • The IDE (VS / VS Code/ VS4Mac) you're running on, and its version: 16.11.4
  • Attached bin log wap.Release.zip
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-ReadyToRun untriaged Request triage from a team member labels Oct 14, 2021
@ocalvo ocalvo changed the title <PublishReadyToRunComposite and PublishReadyToRunUseCrossgen2 fails PublishReadyToRunComposite and PublishReadyToRunUseCrossgen2 fails Oct 14, 2021
@AntonLapounov AntonLapounov removed the untriaged Request triage from a team member label Apr 7, 2022
@AntonLapounov
Copy link
Member

The error message has been improved in #24324.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants