简体   繁体   中英

Running a .NET Core Console Application on Mac or Windows

Ive created a .net core console application. I want to build the app so that i can execute it on windows or mac without dotnet core is installed on the machine. So i need eg for windows a exe.

Ive read https://docs.microsoft.com/de-de/dotnet/articles/core/tools/dotnet-publish and i know how to compile the application for the different plattform(s).

But no executable gets created. What i am missing here and how to accomplish my goal?

What you need is to create a self-contained application . The link explains how exactly to modify your project.json to do that.

Also note that while a self-contained application does not have a dependency on .Net Core, it may have other dependencies. Specifically on OSX, I believe you will need to install a specific version of openssl from homebrew.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM