EmccCompile: prefer TryRunProcess over RunShellCommand.#126150
EmccCompile: prefer TryRunProcess over RunShellCommand.#126150tmds wants to merge 11 commits intodotnet:mainfrom
Conversation
A shell is not needed to run emcc.
|
Thank you @tmds for the contribution! There are test failures related to the change https://github.com/dotnet/runtime/pull/126150/checks?check_run_id=68749851592 |
maraf
left a comment
There was a problem hiding this comment.
I'm thinking if there wasn't reason to put the command in batch file, something like too long input
|
Tagging subscribers to 'arch-wasm': @lewing, @pavelsavara |
|
There is problem with too long list of arguments. |
It seems that on Windows emcc is invokable as
I think this is independent of the changes made here. |
|
@maraf @pavelsavara please take another look. |
|
/azp run runtime-wasm |
|
Azure Pipelines successfully started running 1 pipeline(s). |
|
@pavelsavara can you take another look? |
|
I looked through the history here, and the shell wrapper appears to have been introduced for process execution reliability, not to avoid command-line length limits. Relevant history:
On the command-length question: storing the invocation in a
So the history supports that the wrapper was there for invoking |
|
@maraf that matches my understanding: wethether .NET or cmd launches a process, they are both subject to the same command length limit. The only way to pass something longer is by putting it in a response file. The change made here is meant to eliminate the shell on non-Windows. On Windows, we still need |
|
@pavelsavara @maraf is this good to merge? |
|
@tmds I'm sorry for the delay! Regarding the Windows invocation:
A safer pattern is to pass |
A shell is not needed to run emcc.