Using IPWI to Repackage an Application
The application discovery process
- Start the process with a clean installation of Windows 2000. This means
that the OS and InstallShield Pro for Windows Installer (IPWI) version 2.03
are the only products installed.
- Run the “Spy” application. This is the IPWI equivalent of the Discover
process used by WinInstall or the SnAppShot process for creating NAL objects.
- Choose “Analyze the initial system status” to start the first snapshot
process and click Next.
- Check the “Change link analysis options” box and the “Registry” option. If
you know you need to change the default file exclusion, check the appropriate
box and click Next.
- Check the box marked “The installation to be analyzed will probably
require system-level modifications.” and click Next.
- Delete all folders listed in the “Drives/Paths:” window.
- Click the New button and add the “C:\” path to the “Drives/Paths:” window.
Click “Next”.
- The Link Analysis box will appear. Click the “Analyze shell links” radio
button and check the “Include Desktop, system folders and path list” checkbox.
Click Next.
- The Registry Exclusion box appears. Delete the following keys: HKLM\System,
HKLM\System\CCS\hardware, and HKLM\System\CCS\enum from registry exclusion
list.
- Click “Start” to create a snapshot of the current Windows system
configuration.
- Click “Ready” when the “Initial status analysis completed.” Window
appears.
- Install the application with the desired options. Skip the “Register the
product” option if present. If possible, avoid rebooting before running the
“Spy” process for the second time.
- Configure the app by adding and/or removing any desired shortcuts. Avoid
starting the application if possible.
- Run the “Spy” application again. Choose the “Analyze system status
changes.” radio button and click “Next”.
- In the “Project path to store files to:” window, select the location the
MSI file will reside (on the app install server) and click “Next”.
- “Change Preferences” dialog box appears. Check to make sure no variables
pointing to the directory where the original application install files are
stored. Uncheck the box next to any references to these files.
- Click “Start” to begin the process of creating the second snapshot of the
machine.
- When the “New Files Found” dialog box appears, check the “Disk/CD” radio
button unless the application was installed from an administrative install of
the application. Click “Continue”.
- When the “Analysis completed successfully!” dialog box appears, click the
“Finish” button. This completes the application discovery process by copying
all necessary files to the location specified during the Spy process.
- Click “OK” twice to close the NetInstall Spy window.
Creating a release version of the MSI file
- Rename the “Script.inc” file in the Application directory to reflect the
name of the application. When the project is opened in IPWI, it will choose
the name of this file as the name of the project. This needs to be as close to
the name of the application as possible to make the “Add/Remove Application”
process as user-friendly as possible. If you fail to do this, all applications
will appear as “Script” in the Add/Remove Programs” window, making it
impossible for the user to know which one to install or uninstall to add or
remove the desired application.
- Start the IPWI program. Click “File/Open” and browse for the location
where you stored the application. Click “Netinstall Script / *.inc file” in
the File type window and double-click the name of the
- Choose the application directory in the “Enter the project name and
location for the converted Netinstall script:” window and click “OK” to import
the *.inc file into IPWI as a *.ism project file. When the line “NetInstall
script conversion complete” appears, close the “Build/Validate/Results” window
at the bottom of the screen.
- Click “General Information” line. Information about the project appears.
- Click “Project Properties”. Enter the Setup Author Name. This information
is not referenced by anything other than the IPWI application.
- Click “Summary Information Stream”. This is the information that will be
displayed to end users in the Summary Panel of the setup package’s
“Properties” dialog box. Enter a Title and subject information. Enter Author
information and any appropriate keywords. If you wish to limit the languages
and/or processor types the application supports, choose them here. Enter any
comments about the application in the Comments window.
- Click the “Windows 2000” line in the center panel. This is information
provided to users in the Add/Remove Programs applet. Choose a Display Icon.
Change the publisher information to reflect the contact info of the installer.
- Click the “Product Properties” line in the center panel. Change the
Destination Folder to reflect where the app will install. Ex: [ProgramFilesFolder}/MathCad
- Click “Files” under the #2 blue circle. Browse through the list and delete
any files that were not intentionally included by the application install. Add
any files you wish the product to install that aren’t included in the Spy
discovery process.
- Click “Shortcuts / Folders” under the #3 circle. Delete any shortcuts you
do not wish for the application to install. Suggested values are any shortcut
that will uninstall the application and anything that shouldn’t run from the
startup folder. Add any shortcuts you want the app to install that weren’t
included in the Spy process. Suggestions are a desktop shortcut – this can be
deleted after installation, but can’t be (easily) added after the MSI has been
generated.
- Click the “Registry” tab. Browse the list of components looking for
anything that installs an entry in HKCU or HKLM. Check to make sure that only
necessary registry keys are being added when the application installs. Delete
any non-essential HKCU and HKLM entries.
- Click the “INI File Changes” tab under the #3 circle. Check to make sure
that only necessary changes are made.
- Click the “Path Variables” tab under the Advanced Views setting. Add any
necessary path variables and make sure that only necessary path additions are
made.
- Click the “Environment” tab under the Advanced Views setting. Look for
references to environment variables (in the form ‘%whatever%’) and replace
them with the absolute path values.
- If changes to components are necessary, or if you wish to add a component
(perhaps one that includes a product key addition to the registry), this can
be done in the Advanced Views/Components tab. Changes to resource keypaths can
also be done here.
- Advanced Views/PowerEditor can accomplish removal of files, registry
settings, make deletions to *.ini files, etc.
- When all changes to the release version of the product, click the Release
Wizard Icon on the toolbar. Click “Next”.
- Check the “New Product Configuration” window and enter a name for the
product name. Click “Next”.
- Click “New Release” and accept the default version of the product release.
Click “Next”.
- Click “Next” to skip the multi-lingual step.
- Choose “Network Image” to allow the MSI file to expand to fill available
space (as needed) on the application server. Click “Next”.
- Click the “Compress all files” radio button to compress the application
files into the cab file in the MSI file. Click “Next”.
- Click “Next” at the “Setup Languages” dialog box.
- Uncheck the “Create install launcher (Setup.exe)” box. In the “Release
Location” location window, choose the folder where the application files are
stored. Make sure the “Use long file names” box is checked and that all the
others are unchecked. Click “Next”.
- Click “Build” at the summary window to begin the MSI file creation
process. Watch the “Build” window for error messages. When the “\Release
1 build completed with 0 errors, 0 warnings line appears, close the IPWI
application
- Move the files in the application directory to a folder marked “Creation
files”. These are compressed into the MSI file and are therefore no longer
needed. In case the MSI file doesn’t work, we’ll save these files so the Spy
process doesn’t need to be run again if we need to build another release.
- Browse for the MSI file and copy the MSI file to the application
directory.
- Uninstall the product from Windows 2000 using the Add/remove Programs
feature of the control panel.
- Reboot (if necessary) and install the product from the MSI file. Test the
application to determine if it works correctly. When it does, add the wrapper
files to make the product a silent install and to add registry keys necessary
for login scripts.
Known Issues with IPWI
- Quotation marks in target path of application shortcuts should be
excluded. Be careful that NAL objects repackaged as MSIs sometimes have these
quotation marks in the target paths of shortcuts when command-line parameters
are included.
- REG_MULTI_SZ entries or changes are captured by Spy but are not imported
into an IPWI *.ism project. Examine the standard.nir file, and if those reg
entries are found, migrate them into the appropriate registry entries before
producing the MSI file.
- Sometimes SPY sets a variable that points to the original file install
location. Be sure to uncheck those boxes during the second running of Spy.
- Registry key removals aren’t captured during the Spy process. See the c:\ni_tmp\registry.del
file for information about those keys and import that information into the
removeregistry table. See the SDK help file topic labeled “removeregistry” for
more info.