您的构建正在试图找到\bin\roslyn\csc.exe,因为以下包已添加到您的项目中。检查一下你的套餐。配置文件,你可以把它们都放在那里
Microsoft.CodeDom.Providers.DotNetCompilerPlatform
Microsoft.Net.Compilers
What is Roslyn and Who added them(packages) in the project : If you’re using .net Framework 4.5.2 to create projects
using VS2015, you might have noticed that the project templates use
Roslyn by default. Actually, Roslyn is one of open-source
compilers for .NET languages from Microsoft.
Why should we delete Roslyn :
If your project has Roslyn references and you are interested to deploy
it on server, you will get unwanted errors on the website as many
hosting providers still have not upgraded their servers and hence do
not support Roslyn. To resolve this issue, you will need to remove the
Roslyn compiler from the project template.
如果你不想利用罗斯林
按照下面的步骤删除它
1.
删除NuGet包,从NuGet包控制台使用以下命令
PM> Uninstall-package Microsoft.CodeDom.Providers.DotNetCompilerPlatform
PM> Uninstall-package Microsoft.Net.Compilers
2.
在你完成这些之后,你的网。配置文件应该自动更新。如果不是,请在web中查找下面的代码。配置文件,如果找到,删除这段代码。
<system.codedom>
<compilers>
<compiler language="c#;cs;csharp" extension=".cs" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.CSharpCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:6 /nowarn:1659;1699;1701"></compiler>
<compiler language="vb;vbs;visualbasic;vbscript" extension=".vb" type="Microsoft.CodeDom.Providers.DotNetCompilerPlatform.VBCodeProvider, Microsoft.CodeDom.Providers.DotNetCompilerPlatform, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" warningLevel="4" compilerOptions="/langversion:14 /nowarn:41008 /define:_MYTYPE=\"Web\" /optionInfer+"></compiler>
</compilers>
</system.codedom>