在.net 2机器上部署.net 4应用程序 [英] Deploying .net 4 apps on .net 2 machines

查看:202
本文介绍了在.net 2机器上部署.net 4应用程序的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我们的组织只在台式机上运行.net 2.0。将所有机器升级到.net 4.0将是很好的,但这不会发生。
我希望使用.net 4.0功能。

Our organisation only runs .net 2.0 on desktops. It would be nice to upgrade all machines to .net 4.0, but that is not going to happen. I wish to use .net 4.0 features.

有没有办法将.net 4.0运行时库静态链接到我的.net 4.0可执行文件中,以便运行在.net 2.0环境中?

Is there a way to statically link .net 4.0 runtime libraries into my .net 4.0 executables so they will run on a .net 2.0 environment?

推荐答案

为了防止马克的评论不够明确:没有办法在地狱。组装元数据格式在.NET 4.0中已更改,2.0 CLR不知道如何读取它。您有2.0版本的CLR在2.0 RTM和3.5 SP1之间的任何.NET版本中运行。

Just in case Marc's comment wasn't explicit enough: no way in hell. The assembly metadata format was changed in .NET 4.0, the 2.0 CLR doesn't know how to read it. You got the 2.0 version of the CLR running in any .NET version between 2.0 RTM and 3.5 SP1.

使用安装程序进行修复很简单,但它肯定会妨碍我喜欢我所知道的工作人员的态度。打破蛋壳是一个政治问题,而不是编程问题。祝你好运,造成伤害。

It is trivial to fix with a Setup project, but it certainly does get in the way of staff that takes the "I like what I know" attitude. Breaking through that egg shell is a political problem, not a programming problem. Good luck doing the damage.

这篇关于在.net 2机器上部署.net 4应用程序的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆