Enterprise Library in 64 bit mode

Oct 25, 2007 at 4:59 PM
Hello,

we want to run some web applications in 64 bit mode. So i tried to compile our projects using the x64 configuration platform. This raises an error because the used enterprise library 2 (jan. 2006) is compiled in 32 bit mode. So there is a precompiles 64 bit version available?
I tried to compile the src files on my own but it always failes with the error that the "mscorlib.dll target to a different processor". I added the mscorlib of the 64 bit framework to the GAC with no success.

thank you for your support.
Oct 25, 2007 at 7:05 PM
Hi,

Can you post the build error?

Thanks,
Fernando


KidSteele wrote:
Hello,

we want to run some web applications in 64 bit mode. So i tried to compile our projects using the x64 configuration platform. This raises an error because the used enterprise library 2 (jan. 2006) is compiled in 32 bit mode. So there is a precompiles 64 bit version available?
I tried to compile the src files on my own but it always failes with the error that the "mscorlib.dll target to a different processor". I added the mscorlib of the 64 bit framework to the GAC with no success.

thank you for your support.

Oct 25, 2007 at 9:31 PM
Hello,

thanks for your fast response.

I try to build the ObjectBuilder projects first and as written in the previous post the error "Referenced assembly 'mscorlib.dll' targets a different processor" raises. This error raises for the System.Data reference, too. The assembly referernce System.Data I updated using the framework 64 assembly and it solved the problem. But the mscorlib.dll can not be updated as reference because it is only available from the GAC. So i registered the framework 64 mscorlib.dll to the GAC using the commandline gacutil. The utility printed an succedded message but I there seems to be no change of the assemblies in the GAC and the building failure remains. Maybe it is not possible to add the mscorlib.dll to the GAC for some reasons.
Oct 26, 2007 at 2:37 AM
I'm confused, the generated MSIL should be independent of any processor architecture? So assuming you are using MSIL DLL's I was under the impression it would just work. Although I also believe the JIT on the 64 bit machines is not yet as mature as the 32 bit version.

Perhaps I'm too tired today :-)

Gareth
Oct 27, 2007 at 9:48 AM
Hello Gareth,

you're are right. But what is the use of configuration platforms in the configuration manager of the visual studio? I guessed it prepares the assemblies somehow but right now i think I'm wrong.

So I build the whole web app using "Any CPU" and the JIT handles the mode of the web and all its referal assemblies? If that's the case why there is a WOW64 mode? The WOW64 runs 32 bit assemblies in a 64 bit environment, but if the JIT runs all assemblies in 64 bit on its own, it seems to be useless...doesn't it?
Oct 29, 2007 at 1:33 PM
I'm afraid I'm no expert at this time on the 64bit platform. However WOW64 allows you to run native 32Bit applications (i.e. Native 32Bit C, C++, VB etc) on the 64Bit platform without recompiling. It shouldnt need to be involved by any native assemblies that are set to 'AnyCPU'.

I recently came across this article that seems to cover a lot of the questions I (and you) had: http://msdn2.microsoft.com/en-us/library/ms973190.aspx .

Also a quick search for "64Bit c#" shows a number of entries that would probably help your question here. I've included a couple if you want to read them. I found this one quite interesting as it covered a lot of scenarios (but not as nicely as the MS one above): http://www.microsoft.com/communities/newsgroups/en-us/default.aspx?dg=microsoft.public.dotnet.languages.csharp&tid=d91632d8-991b-4df7-a5ce-c2a92ebd1511&p=1

Either way I hope this helps in your configuration,

Gareth