开发者

32-bit vs 64-bit custom framework

I have a custom built framework (.NET) for our internal applications. It is compiled in 32-bits.

Some of the applications are deployed on 32-bit servers, some of them on 64-bit servers (with 32-bit apps enabled).

The idea would be to have 2 versions of our framework, 32-bit and 64-bit.

In understand we could build 2 versions of the framework, but what we would like is to have a "unive开发者_Python百科rsal" framework build that would work on 32-bits or 64-bits machines.

Is this something that can be done or we have to stick with 2 separate versions?

And let's say we have 2 versions. On the development workstations (32-bits), when it's time to build for deployment on 64-bits machines, would the developer have to change all project properties to link to the 64-bit version of the framework assemblies?

Thanks, Alex


Do you have any native code? If not, just build all your assemblies (which I assume are class libraries) as "Any CPU" (the default for class libraries) and then you don't need to care.


you could just build 1 version, set to AnyCpu, and the jitter will compile it to either a 32 bit or 64 bit native image file when it is loaded, depending on the environment.

This assumes that you don't do anything with native code (PInvoke etc). If you start to do things with native code then, you need to build a 32 and a 64 bit version.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜