PDA

View Full Version : Guide to creating 32 & 64 in single project...



destek
09-20-2010, 10:03 AM
One of the most attractive features for IS2011 is the ability to maintain a single project for both 64 and 32 bit installations. I assume it creates two setup.exe files (which is just fine).

In their announcement (http://www.msigeek.com/5693/flexera-software-introduces-installshield-2011) Flexera states:


Enhances 64-bit support so developers can maintain a single installation project to support 32-bit and 64-bit platforms

But so far I have found no information on how to do this. Is there a tutorial, white paper, guide - or anything that explains this attractive and exciting capability?

Des

DebbieL
09-21-2010, 07:46 AM
This help topic would be a good place to start:
Targeting 64-Bit Operating Systems (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17helplib/IHelp64BitSupport.htm)
It has links to other help topics with more information.

I hope that helps.

morgan
09-22-2010, 04:58 PM
This help topic would be a good place to start:
Targeting 64-Bit Operating Systems (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17helplib/IHelp64BitSupport.htm)
It has links to other help topics with more information.

I hope that helps.

Debbie, we have Professional Edition where I work, so no Repackager. Our two projects are large, complex InstallScript projects. I am now tasked with getting them working with Intel 64-bit Windows OSes in addition to 32-bit. Is there any sort of document for people like me, having to support both 32-bit & 64-bit with InstallScript?

I'm running InstallShield 2011 Professional Edtion, just upgraded in hopes of a clear 64-bit path. I don't think I'll get spending approval for Premier edition.

Morgan

DebbieL
09-22-2010, 05:53 PM
What type of application are you planning to create? I can think of three general types:

A 32-bit application that can be installed on 32-bit systems and 64-bit systems. This application is installed to 32-bit folder and registry locations.
A 32-bit application that contains some 64-bit-specific data. All of the 32-bit data is installed on 32-bit and 64-bit systems. The 64-bit data is installed only on 64-bit systems.
An application that can be installed as 32 bit (using 32-bit folder and registry locations) on 32-bit systems and as 64 bit (using 64-bit folder and registry locations) on 64-bit systems.

morgan
09-29-2010, 02:47 PM
What type of application are you planning to create? I can think of three general types:

A 32-bit application that can be installed on 32-bit systems and 64-bit systems. This application is installed to 32-bit folder and registry locations.
A 32-bit application that contains some 64-bit-specific data. All of the 32-bit data is installed on 32-bit and 64-bit systems. The 64-bit data is installed only on 64-bit systems.
An application that can be installed as 32 bit (using 32-bit folder and registry locations) on 32-bit systems and as 64 bit (using 64-bit folder and registry locations) on 64-bit systems.


I'm really not sure where our project falls, in your list

Both of our projects are java applications, bundling java virtual machines and a web application server. In the case of the larger project, everything binary is 32-bit with the exception of two items that must be 64-bit to work on 64-bit hosts;


the 7-zip binary, so that I can do configuration operations on a zip file during installation (I wish InstallShield could operate on zip files)
the isapi binaries, so that I can do port 80 redirections from IIS


Additionally, I currently check the registry for MS SQL Server and MS Reporting Services during installation, and spawn error messages if they're not found. I need to add checks for the appropriate 64-bit registry strings on 64-bit systems.

The files I am installing are in large part the same, across both architectures, between both projects. So far the smaller project does not need any changes for 64-bit systems.

Morgan

DebbieL
09-30-2010, 01:31 PM
You should be able to create one InstallScript installation that works on both 32-bit and 64-bit systems. Here are a few things that may be useful for installing binaries in 64-bit locations, and for installing and checking registry entries in the 64-bit part of the registry.

You can use SYSINFO.bIsWow64 in your code to determine if the target system is 64 bit, and then launch some of your 64-bit-specific code only if appropriate. For more information, see SYSINFO (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefSYSINFO.htm).

To install certain files to 64-bit directories on 64-bit systems, call Enable(WOW64FSREDIRECTION); to switch back to installing to 32-bit directories on both 32-bit and 64-bit systems, call Disable(WOW64FSREDIRECTION). To learn more, see Enable (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefEnable00000679.htm) and Disable (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefDisable00000677.htm).

If you want to check the 64-bit area of the registry, you can set the REGDB_OPTIONS equal to REGDB_OPTION_WOW64_64KEY. Set it equal to REGDB_OPTION_USE_DEFAULT_OPTIONS if you want to switch back to the 32-bit area. For more information, see REGDB_OPTIONS (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefREGDB_OPTIONS.htm).

The Platform Suites setting in the Components view lets you indicate that the selected component is for 32-bit or 64-bit systems. The default value of this setting is Suite Independent, meaning that the component is installed on both 32-bit and 64-bit systems. You can also use the FeatureFilterOS function to override the behavior that is configured through the Platform Suites setting. To learn more, see Settings for Platforms and Platform Suites (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17helplib/PlatformsSuitesLanguages.htm).

morgan
09-30-2010, 03:00 PM
You should be able to create one InstallScript installation that works on both 32-bit and 64-bit systems. Here are a few things that may be useful for installing binaries in 64-bit locations, and for installing and checking registry entries in the 64-bit part of the registry.

You can use SYSINFO.bIsWow64 in your code to determine if the target system is 64 bit, and then launch some of your 64-bit-specific code only if appropriate. For more information, see SYSINFO (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefSYSINFO.htm).

To install certain files to 64-bit directories on 64-bit systems, call Enable(WOW64FSREDIRECTION); to switch back to installing to 32-bit directories on both 32-bit and 64-bit systems, call Disable(WOW64FSREDIRECTION). To learn more, see Enable (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefEnable00000679.htm) and Disable (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefDisable00000677.htm).

If you want to check the 64-bit area of the registry, you can set the REGDB_OPTIONS equal to REGDB_OPTION_WOW64_64KEY. Set it equal to REGDB_OPTION_USE_DEFAULT_OPTIONS if you want to switch back to the 32-bit area. For more information, see REGDB_OPTIONS (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17langref/LangrefREGDB_OPTIONS.htm).

The Platform Suites setting in the Components view lets you indicate that the selected component is for 32-bit or 64-bit systems. The default value of this setting is Suite Independent, meaning that the component is installed on both 32-bit and 64-bit systems. You can also use the FeatureFilterOS function to override the behavior that is configured through the Platform Suites setting. To learn more, see Settings for Platforms and Platform Suites (http://helpnet.flexerasoftware.com/Robo/BIN/Robo.dll?tpc=/robo/projects/installshield17helplib/PlatformsSuitesLanguages.htm).

Thanks!

Morgan