【发布时间】:2015-07-23 15:48:25
【问题描述】:
我正在尝试在常规 .NET 4.5.2 Web 项目(不是 DNX)中安装 MVC 6 测试版。它给了我一个错误。这可能吗?还是最终会得到支持?
PM> install-package Microsoft.AspNet.Mvc -pre
Attempting to gather dependencies information for package 'Microsoft.AspNet.Mvc.6.0.0-beta5' with respect to project '6 - Entry Points\Sample.Web', targeting '.NETFramework,Version=v4.5.1'
Attempting to resolve dependencies for package 'Microsoft.AspNet.Mvc.6.0.0-beta5' with DependencyBehavior 'Lowest'
Resolving actions to install package 'Microsoft.AspNet.Mvc.6.0.0-beta5'
Resolved actions to install package 'Microsoft.AspNet.Mvc.6.0.0-beta5'
Install failed. Rolling back...
Package 'Microsoft.AspNet.Mvc 6.0.0-beta5' does not exist in project 'Sample.Web'
Package 'Microsoft.AspNet.Mvc 6.0.0-beta5' does not exist in folder 'C:\Dev\Sample\packages'
Install-Package : Could not install package 'Microsoft.AspNet.Mvc 6.0.0-beta5'. You are trying to install this
package into a project that targets '.NETFramework,Version=v4.5.1', but the package does not contain any assembly
references or content files that are compatible with that framework. For more information, contact the package
author.At line:1 char:1
+ install-package Microsoft.AspNet.Mvc -pre
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [Install-Package], Exception
+ FullyQualifiedErrorId : NuGetCmdletUnhandledException,NuGet.PackageManagement.PowerShellCmdlets.InstallPackage
Command
【问题讨论】:
-
我相信 mvc6 依赖于 .net 4.6
-
mvc6需要dnx类型的项目
-
那么您将永远无法在 IIS 上运行 MVC 6?
标签: asp.net asp.net-core asp.net-core-mvc