.Net跨平台中遇到的问题小结

一:创建MVC网站,需要修改Views视图文件夹下的Web.config

二:需要添加web.config中的

  <system.web>
    <compilation debug="true" targetFramework="4.5"/>
    <httpRuntime targetFramework="4.5"/>
    <customErrors mode="Off"/>
    <globalization culture="en-us" enableClientBasedCulture="false"/>
  </system.web>

三:需要删除发布文件中 roslyn文件夹 以及Microsoft.Web.Infrastructure.dll类库

四:删除一下内容,不然后提示roslyn

<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 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=&quot;Web&quot; /optionInfer+"/>
    </compilers>
  </system.codedom>

五:需要找到jexus中的siteconf文件夹 

六:发布完成

各种mono版本:http://download.mono-project.com/sources/mono/

主要来源:http://www.cnblogs.com/gaobing/p/4955204.html

原文地址:https://www.cnblogs.com/xiaoyaodijun/p/5341279.html