PDA

View Full Version : .NET Precompile Assemblies



MichaelHu
12-15-2008, 12:35 PM
Dear all!

The developers of our software want me to precompile about 20 .NET assemblies (they seem to be sure about it :) .

I just played around with InstallShield's ".NET Precompile Assembly" and I'm not really convinced about it... The DOS window that prompts up during the installation is pretty annoying...

My main problem is that the .NET assemblies have dependencies between each other and during the precompilation they don't seem to be able to "find" each other (i get a lot of errors). As far as i understand the order of this precompilation is crucial, can anybody confirm this?

I'm pretty sure that if i precompile these assemblies in the right order they will be able to find each other... Am I right that it is not possible to set the "precompilation order" of assemblies within InstallShield?

Has anybody experience with Assembly Precompilation? Do you use the InstallShield feature or do you manually call a batch file which uses ngen.exe? (with a batch file i'd be able to set the order or the precompilation)


Thanks for your help!
Michael

MichaelU
12-15-2008, 03:42 PM
If it's any help, I think you can set the order InstallShield implicitly requests by editing the Command Line of the ISJITCompileActionAtInstall and ISJITCompileActionAtUnInstallcustom actions (Show All custom actions to see them). I don't know if it will help for your use case though; I would have expected ngen to build a dependency tree instead of just failing.