batee.com

 

The Stories of My Life Gallery Projects Friends and Family Web Log Contact

 

Using IPWI to Repackage an Application

The application discovery process

  1. 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.

     

  2. Run the “Spy” application. This is the IPWI equivalent of the Discover process used by WinInstall or the SnAppShot process for creating NAL objects.

     

  3. Choose “Analyze the initial system status” to start the first snapshot process and click Next.

     

  4. 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.

     

  5. Check the box marked “The installation to be analyzed will probably require system-level modifications.” and click Next.

     

  6. Delete all folders listed in the “Drives/Paths:” window.

     

  7. Click the New button and add the “C:\” path to the “Drives/Paths:” window. Click “Next”.

     

  8. 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.

     

  9. The Registry Exclusion box appears. Delete the following keys: HKLM\System, HKLM\System\CCS\hardware, and HKLM\System\CCS\enum from registry exclusion list.

     

  10. Click “Start” to create a snapshot of the current Windows system configuration.

     

  11. Click “Ready” when the “Initial status analysis completed.” Window appears.

     

  12. 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.

     

  13. Configure the app by adding and/or removing any desired shortcuts. Avoid starting the application if possible.

     

  14. Run the “Spy” application again. Choose the “Analyze system status changes.” radio button and click “Next”.

     

  15. 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”.

     

  16. “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.

     

  17. Click “Start” to begin the process of creating the second snapshot of the machine.

     

  18. 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”.

     

  19. 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.

     

  20. Click “OK” twice to close the NetInstall Spy window.

Creating a release version of the MSI file

  1. 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.

     

  2. 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

     

  3. 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.

     

  4. Click “General Information” line. Information about the project appears.

     

  5. Click “Project Properties”. Enter the Setup Author Name. This information is not referenced by anything other than the IPWI application.

     

  6. 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.

     

  7. 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.

     

  8. Click the “Product Properties” line in the center panel. Change the Destination Folder to reflect where the app will install. Ex: [ProgramFilesFolder}/MathCad

     

  9. 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.

     

  10. 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.

     

  11. 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.

     

  12. Click the “INI File Changes” tab under the #3 circle. Check to make sure that only necessary changes are made.

     

  13. 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.

     

  14. 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.

     

  15. 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.

     

  16. Advanced Views/PowerEditor can accomplish removal of files, registry settings, make deletions to *.ini files, etc.

     

  17. When all changes to the release version of the product, click the Release Wizard Icon on the toolbar. Click “Next”.

     

  18. Check the “New Product Configuration” window and enter a name for the product name. Click “Next”.

     

  19. Click “New Release” and accept the default version of the product release. Click “Next”.

     

  20. Click “Next” to skip the multi-lingual step.

     

  21. Choose “Network Image” to allow the MSI file to expand to fill available space (as needed) on the application server. Click “Next”.

     

  22. Click the “Compress all files” radio button to compress the application files into the cab file in the MSI file. Click “Next”.

     

  23. Click “Next” at the “Setup Languages” dialog box.

     

  24. 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”.

     

  25. 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

     

  26. 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.

     

  27. Browse for the MSI file and copy the MSI file to the application directory.

     

  28. Uninstall the product from Windows 2000 using the Add/remove Programs feature of the control panel.

     

  29. 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

  1. 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.

     

  2. 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.

     

  3. 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.

     

  4. 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.

 

Unless otherwise specified, the text and images in this page are the copyrighted property of Bryan A. Thompson, 1996-2008.  All Rights Reserved.