This pane is part of the Preferences window which is shown when you select the Preferences menu item. It allows you to set up gmake variable overrides which are used every time you build a target.
The main scrolling list shows the current set of variable overrides, with their name, value, and type. The other items on this pane allow you to add, change and remove from this set. Clicking the OK button accepts the variable overrides so that they will apply to the next gmake run [1] .
Maketool supports overriding gmake variables in two different ways, shown in the scrolling list as the `Type' of the variable override.
Variable overrides of this type are passed the gmake on the commandline as a sequence of arguments of the form NAME='VALUE'. The %v escape sequence in maketool commands is replaced with this sequence of options (see % Escape Characters for other sequences).
Note that the behaviour of the Make type variable overrides with recursive builds depends on which make program is selected in the Make Program field in the Preferences; gmake will pass down the overrides to child makes and subdirectories, many other make programs do not.
Variable overrides of this type are passed to gmake in the process environment, as if you had used the shell export (sh, ksh, bash) or setenv (csh, tcsh) commands.
Note that the behaviour of variables set in the environment depends on which make program is selected in the Make Program field in the Preferences, and how the Makefile is written. The value you specify may well be ignored.
Environ type variables are useful for passing variables to autoconf configure scripts, particularly the CC and CFLAGS variables.
To add a new variable override:
enter a name in the Name text field,
enter a value in the Value text field,
choose a type from the Type combobox, and
click Set to add the new variable override to the scrolling list.
click OK to accept the set of variable overrides in the scrolling list.
To change an existing variable override:
select a variable override in the scrolling list,
change the value in the Value text field or the type in the Type combobox.
click Set to change the variable override.
click OK to accept the set of variable overrides in the scrolling list.
To remove a variable override:
select a variable override in the scrolling list,
click Unset to remove the variable override.
click OK to accept the set of variable overrides in the scrolling list.
The controls on this pane are described in detail below.
This text field shows the name of the currently selected variable override and allows you to enter names of new variable overrides. Names must obey the same rules as gmake variable names (see the gmake documentation).
In addition to the normal TAB key for moving between fields in a window, you can use the equals (=) key to advance to the Value text field.
This text field shows the value of the currently selected variable override and allows you to enter values of new variable overrides. Values can be any string and may include whitespace [2] and shell metacharacters (although see Metacharacters for pitfalls with metacharacters). Maketool will quote the string if necessary before passing it to a shell.
This combobox shows the type of the currently selected variable override and allows you to choose types of new variable overrides.
Click Set to add the name, value and type combination currently in the Name, Value and Type fields into the scrolling list. Note that you need to click the OK or Apply buttons before the variable override will be used in the next gmake run.
Click Unset to remove the variable override corresponding to the name currently in the Name text field from the scrolling list. Note that you need to click the OK or Apply button before the variable override will be removed from the next gmake run.
[1] | Variable overrides are currently not saved in the preferences file, so you have to enter them every time you start maketool. |
[2] | There is currently no way you can enter TAB or newline characters in Value text field. |