Click here to Skip to main content
15,904,287 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Build started at 17:03...
1>------ Build started: Project: revision, Configuration: Debug Any CPU ------
1>revision -> C:\Users\dylan\source\repos\revisionn\revisionn\bin\Debug\net8.0\revision.dll
2>------ Publish started: Project: revision, Configuration: Debug Any CPU ------
2>revision -> C:\Users\dylan\source\repos\revisionn\revisionn\bin\Debug\net8.0\revision.dll
2>RuntimeIdentifier is required for native compilation. Try running dotnet publish with the -r option value specified.
========== Build: 1 succeeded, 0 failed, 0 up-to-date, 0 skipped ==========
========== Build completed at 17:03 and took 01.346 seconds ==========
========== Publish: 0 succeeded, 1 failed, 0 skipped ==========
========== Publish completed at 17:03 and took 01.346 seconds ==========

What I have tried:

lots of reserch cant find anything to help
Posted

1 solution

All you had was Google the one phrase "RuntimeIdentifier is required for native compilation".

Chances are when you created the ASP.NET Project, you picked the template that mentions "native AOT". All this does is turn on the Native AOT option in your Project Properties. All you need to do is turn that off.

Go to the Project menu, click on <yourprojectname> Properties at the bottom of the menu. In the Properties window that shows up, in the search bar at the top, type native and you'll find the Publish Native AOT option. Turn that off and close the Properties window. Try your Publish again.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900