The roslyn compiler path should be configurable via documented configuration settings instead of internal implementation details like environment variables.
The providerOption element under system.codedom/compilers/compiler is officially documented and also used by the integrated CodeDomProvider, e.g.
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" warningLevel="4" type="Microsoft.CSharp.CSharpCodeProvider, System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089">
<providerOption name="CompilerVersion" value="v4.0"/>
<providerOption name="WarnAsError" value="false"/>
</compiler>
</compilers>
</system.codedom>
So the RoslynCodeDomProvider should support something like
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform" warningLevel="4" compilerOptions="/langversion:default /nowarn:1659;1699;1701">
<providerOption name="CompilerPath" value="..\my\path\to\csc.exe"/>
</compiler>
The roslyn compiler path should be configurable via documented configuration settings instead of internal implementation details like environment variables.
The providerOption element under system.codedom/compilers/compiler is officially documented and also used by the integrated CodeDomProvider, e.g.
So the RoslynCodeDomProvider should support something like