FIXUPVAR (Compact 2013)
3/26/2014
This configuration option is used to initialize a kernel global variable during the Make Binary Image phase of the build process.
Syntax
None
Parameters
None
Remarks
You can also use this flag for OS design-specific physical memory initialization with multiple possible values that can be controlled with MAKEIMG flags.
The following code example shows the declaration for a sample OAL (Nk.exe) global variable called gpdwVariable, with a value of 0.
#ifdef __cplusplus
extern "C" extern
#endif
const volatile gpdwVariable = 0;
Note
You might have to use the /INCLUDE linker switch to force inclusion of this variable.
The following code example shows how, after gpdwVariable is declared, to use FIXUPVAR to fix up gpdwVariable to the address 0x12345678.
nk.exe:gpdwVariable 00000000 0x12345678 FIXUPVAR
Note
This must be done in the MEMORY section of the .bib file.
FIXUPVAR does not work for uninitialized global variables and non-constant global variables that have been initialized to zero (0).
See Also
Reference
CONFIG Section
Binary Image Builder (.bib) File
Romimage Tool (romimage.exe)