Bug 44937

Summary: System.Diagnostics.StartProcess does not detect dotnetcore compiled assemblies as managed
Product: [Mono] Runtime Reporter: Jon Dick <jon.dick>
Component: io-layerAssignee: Bugzilla <bugzilla>
Status: VERIFIED FIXED    
Severity: major CC: alkpli, masafa, mono-bugs+mono, mono-bugs+runtime, prashantm
Priority: ---    
Version: 4.6.0 (C8)   
Target Milestone: 4.8.0 (C9)   
Hardware: Macintosh   
OS: Mac OS   
Tags: Is this bug a regression?: ---
Last known good build:
Attachments: Repro solution

Description Jon Dick 2016-09-30 12:53:17 UTC
Created attachment 17828 [details]
Repro solution

Traditionally we've been able to do something like this in our code, running on Mono on OSX:
    System.Diagnostics.Process.Start ("/path/to/ManagedAssembly.exe");

Mono would implicitly detect that it was a .NET managed assembly and start it up without explicitly invoking it through mono.

It appears that this detection does not work to detect assemblies compiled with dotnetcore's compiler, even when they are compiled to target the .NET 4.5 Framework and otherwise run just fine under mono.

I've attached a very simple repro case to illustrate the issue (README contained inside the .zip).

While this may be seemingly innocent, it's causing major issues with projects such as http://cakebuild.net which is now being compiled with dotnetcore and relies heavily on Process.Start invocations with the implicit managed assembly detection.
Comment 2 Alexander Köplinger [MSFT] 2016-10-10 12:03:18 UTC
PR with fix: https://github.com/mono/mono/pull/3745
Comment 3 Alexander Köplinger [MSFT] 2016-10-11 15:31:22 UTC
Fixed in master/f7b73f070a5031f04837461757d8cf9ea34b5f67 and mono-4.8.0-branch/dca5ff953f24cf6d88f5977f5c45032938d5cb32