【发布时间】:2016-05-12 12:24:14
【问题描述】:
在尝试安装 netmq vis nuget 时,出现以下错误:
Could not install package 'AsyncIO 0.1.18'. You are trying to install this package
into a project that targets '.NETPortable,Version=v4.5,Profile=Profile111',
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.
问题在于 netmq 依赖于 AsyncIO。安装时,nuget 发现该程序集与.Net 4.5 不兼容。
所以 nuget 安装 AsyncIO 失败,然后安装 netmq 失败。
所以我从 Github 下载了 AsyncIO 源并使用 .Net 4.5 在本地构建它。
然后添加本地构建的 AsyncIO 的 dll 作为我项目的参考。
理论上,使用 nuget 应该可以成功安装 NetMQ。因为我添加了对 AsyncIO 的所需引用。
但是在尝试重新安装 NetMQ 时,我得到了同样的错误:
Could not install package 'AsyncIO 0.1.18'. You are trying to install this package
into a project that targets '.NETPortable,Version=v4.5,Profile=Profile111',
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.
并且 nuget 没有检测到我在项目中添加了“AsyncIO 0.1.18”。
如何让 nuget 检测到我在项目中添加了此引用?
【问题讨论】:
-
您是使用 .Net Framework 4.5 还是 .Net Portable 4.5 来构建 AsyncIO?
-
我正在使用 .Net Framework 4.5 来构建它。
-
@ThePower:有 .Net Portable 4.5 吗?如何安装。
标签: c# visual-studio nuget zeromq netmq