To avoid having to edit your configuration files too often, the compiler allows you to insert some variables in the paths that you specify for the compiler. They are specified as follows:
The above will be replaced with the value of the variable VARNAME.
Normally, only a set of compiler-defined variable names are recognized. In addition to these compiler-defined variable names, the following notation can be used
to substitute the value of an environment variable. The compiler will fetch the value of ENVVAR from the environment, and replace the $ENVVAR$ with this value.
The compiler defines the following variable names:
Additionally, under windows the following special variables are recognized:
The values of these can vary based on the installation, they are fetched from the operating system.
If none of the pre-defines variable names were matched, and the template name ends on $, then the environment variable with the same name is used:
This will refer to the directory FPC/currentversion under the user’s home directory on Unix (HOME is the environment variable that contains the location of the user’s directory).
So, have one of the above variables substituted, just insert them with a $ prepended, as follows:
This is equivalent to
if the compiler version is 2.6.2 and the target OS is linux.
These replacements are valid on the command line and also in the configuration file.
On the linux command line, you must be careful to escape the $ since otherwise the shell will attempt to expand the variable for you, which may have undesired effects.