Install GitExtensions on a machine with .NET 4.0 only

瘦欲@ 提交于 2019-12-10 11:49:38

问题


.NET 4.0 / Visual Studio 2010 is installed on my machine. When I execute the current installer (GitExtensions224SetupComplete.msi) it tells me that I need to install .NET 3.5.
Can one use GitExtensions with .NET 4.0 or do you have to install .NET 3.5? If yes, how do I force the installer to use .NET 4.0?
Is there a general approach to this, which also works with other programs and installers?

Thanks


回答1:


As far as I can see from GitExtensions224SetupComplete.msi, it has an explicit launch condition Installed OR NETFRAMEWORK35. That's why it doesn't let you proceed without .NET 3.5 installed.

This can mean 3 things:

  1. .NET 3.5 is required for the application and/or the installation to run. In this case you have no choice apart from installing .NET 3.5
  2. .NET 3.5 prerequisite is a left over. In this case you can try to cheat :)

DON'T DO THIS ON CRITICAL ENV - IT'S JUST FOR FUN

The property NETFRAMEWORK35 is set in case the registry value Install equals 1 under registry key SOFTWARE\Microsoft\NET Framework Setup\NDP\v3.5. Add this fake registry key with the only value Install and set it to 1. Then run the installer. In case it succeeds - then it's a left over. Otherwise, there's a real dependency to .NET 3.5 and you have to live with this.

Eventually, the easiest and safest way to go is to install .NET 3.5, that's for sure.




回答2:


This seems to be a general problem for installers based on WiX (like a lot of Open Source programs are) In reality you could probably use it with .Net 4 but you can't force the installer to recognize it. In other words you can (probably) either compile from source and remove the .Net 3.5 version check or just give up and install .Net 3.5 (The easy way out). 3.5 works fine in parallel with .Net 4 and can be installed after .Net 4.

This is from experience, I've had the exact same problem.



来源:https://stackoverflow.com/questions/7431943/install-gitextensions-on-a-machine-with-net-4-0-only

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!