Reputation: 2350
I am trying to run an application (built using xbuild) using coreCLR on OSX and facing some issues.
Earlier I had "mono-complete" installed on OSX. I build my application using "xbuild" and then ran it using "mono my.exe". It all worked fine.
I would like to see if my application "my.exe" is compatible with coreCLR and if it is able to run it.
So I installed dnx sdk for OS X.
$ dnvm list
Active Version Runtime Arch OperatingSystem Alias
------ ------- ------- ---- --------------- -----
1.0.0-beta8-15120 coreclr x64 darwin
* 1.0.0-beta6 mono linux/darwin default
At this point if I run "dnx my.exe", it runs fine. ( I assume I am using mono runtime here ? )
But if I switch to coreCLR, "dnx my.exe" does not work. See below:
$ dnvm use 1.0.0-beta8-15120 -r coreclr
Adding /Users/test_user/.dnx/runtimes/dnx-coreclr-darwin-x64.1.0.0-beta8-15120/bin to process PATH
$ dnx my.exe
'my.exe' does not contain a static 'Main' method suitable for an entry point
Trace/BPT trap: 5
Am I doing something wrong?
Do I have to explicitly compile my application using coreCLR sdk?
I also noticed that people are using something called "corerun". I assume its similar to "mono" command which simply executes apps using coreCLR.
Then what is "dnx" is doing in this case?
I could not find "corerun" command on my system. Does not DNX SDK come up with corerun ?
Upvotes: 2
Views: 2627
Reputation: 63289
Mono is equivalent to .NET Framework. .NET Core is completely a different thing,
http://blogs.msdn.com/b/dotnet/archive/2014/12/04/introducing-net-core.aspx
Your application must be compiled and designed against .NET Core 5 profile so as to be able to run on .NET Core 5. That's not an automatic thing. Currently you can only use Visual Studio 2015 to do such development (or in a code editor with command line tools).
corerun
is described slightly in this sample,
https://github.com/dotnet/coreclr/blob/master/Documentation/building/osx-instructions.md
Upvotes: 3