Inno Setup Preprocessor: Introduction

Inno Setup Preprocessor (ISPP) is a preprocessor add-on for Inno Setup.

The main purpose of ISPP is to automate compile-time tasks and avoid repetition in your scripts. For example, you can declare an ISPP variable (compile-time variable) – your application name, for instance – and then use its value in several places of your script. If for some reason you need to change the name of your application, you'll have to change it only once in your script. Without ISPP, you would need to change all occurrences of your application name throughout the script (AppName, AppVerName, DefaultGroupName etc. [Setup] section directives).

Another example of using ISPP would be gathering version information from your application at compile-time by reading the version info of an EXE file, and using it in AppVerName [Setup] section directive or anywhere else. Without ISPP, you would have to modify your script each time the version of your application changes.

Similarly, you can use ISPP to scan your source folder and generate script lines for the found files. Without ISPP, you would have to manually maintain the list of files.

Also, conditional in- and exclusion of portions of script is made possible by ISPP: you can create one single script for different versions/levels of your applications (for example, trial versus fully functional).

Finally, ISPP makes it possible to split long lines using a line spanning symbol.

Note: ISPP works exclusively at compile-time, and has no run-time functionality.

All topics