InstallAware includes a native code setup engine beginning with InstallAware version 10. The native engine complements Microsoft's Windows Installer setup engine and provides faster execution speeds and greater flexibility at runtime.
Hybrid Installation Technology
Since Windows Installer is database based, the breadth of actions that are possible for execution are essentially locked-in at build-time. While InstallAware transcends the majority of these limitations through MSIcode scripting, certain language constructs like loops cannot be natively supported within the confines of Windows Installer. InstallAware's native engine transcends these limitations, while not sacrificing the flexibility of using the Windows Installer engine, along with the native engine, within the same setup.
The engine modes are even dynamically switchable at runtime.
The native engine also removes any dependencies on the Windows Installer runtime, and can successfully empower installations even when the Windows Installer stack on target systems has been corrupted.
An additional benefit of the native engine is that while the Windows Installer service is not accessible in Windows's Safe Mode, the native engine remains fully accessible. Windows Installer based applications cannot be removed/repaired while in Safe Mode, but this limitation is transcended by the native engine. Applications installed using InstallAware's native engine can be repaired/removed normally while in Safe Mode.
Enabling the Native Engine
You may begin taking advangate of the new native code setup engine in your existing projects with a single line of code:
Set Variable NATIVE_ENGINE to TRUE
There is also a new, pre-built template available, which illustrates how to perform 32 bit-64 bit hybrid installations using the new native code setup engine, including full support for uninstallation of old product versions and the modification of installed setup features during maintenance.
projectNative Engine Enhancements
Some commands behave differently with the native engine, featuring enhanced and more flexible runtime behavior compared to the Windows Installer engine. Below is the list of commands that perform differently between the two engines:
- Apply Changes
- Configure Service
- Configure Service Failure
- Control Service
- Copy/Move Local Files
- Create ODBC DSN
- Create Shortcut
- Delete Files
- Edit INI File
- Install Files
- Install Service
- Set Environment
Typically, where commands would not accept variables with the Windows Installer engine, they now do accept variables when the Native Engine is used instead - offering you greater runtime flexibility. Please refer to the command topics themselves for detailed descriptions of the new functionality provided by the native engine.
Native Engine Limitations
The native engine is not intended to duplicate the Windows Installer engine. Instead, it is designed to provide a faster, non-transactional alternative to the Windows Installer engine. The native engine may be used stand-alone or as a complement to the existing Windows Installer engine. The following are the limitations of the native code setup engine:
- You cannot create binary differential patches for setups built with the native engine.
- Setups built wih the native engine do not perform rollbacks, however they do perform cleanups after failed (or cancelled) installations.
Empowered by InstallAware's hybrid installation technology, you are free to choose the engine(s) best suited to your requirements. Remember, you are not limited to using just one engine, and may swap in and out of either engine mode at runtime, directly within your setup script.
Tweaking Native Engine Behavior
The following pre-defined variables control native engine behavior at runtime:
- DELAYUNTIL_APPLYCHANGES: Emulates Windows Installer behavior with the native engine by preventing changes to the target system until Apply Install is called in the setup script. Also affects progress calculation within the native engine and determines whether native engine errors are treated as fatal.
- NATIVE_ENGINE: Toggles the setup between native and Windows Installer modes. Each installation mode is logged separately and there is no restriction on the number of times a setup may change installation modes at runtime.
- NATIVE_ERROR: Controls how errors in the native code setup engine are handled.
- NATIVE_LOGGING: Enables or disables logging for the native setup engine. May also be used to bind setup to an existing setup log created by an external InstallAware setup.
- NATIVE_OLDLOG: Points to the native engine log file created by a previous version of the same installer.
- NATIVE_OVERWRITE: Controls how files are to be overwritten by the native code setup engine.
- NATIVE_OVERWRITE_OLDER: Determines whether the native engine is permitted to overwrite newer files with older versions.
- NATIVE_ROLLBACK: Controls whether a cancelled setup will attempt to roll back the changes that were logged.
- RECOMMENDEDUPGRADE: Indicates whether an old version of the same product has been installed using the native engine.
The following pre-defined compiler variables control native engine behavior at build time:
- NO_MSI: Controls whether Windows Installer support will be disabled at runtime - when disabled, this speeds up the setup build process.