1.2.32 $IFDEF Name : Start conditional compilation

If the symbol Name is not defined then the {$IFDEF name} will skip the compilation of the text that follows it to the first {$ELSE} or {$ENDIF} directive. If Name is defined, then compilation continues as if the directive wasn’t there.

The $IFDEF directive will only check the first word of what follows, all the rest is ignored. This means that code after a

{$IFDEF RED}

and

{$IFDEF RED check that red is defined}

and

{$IFDEF RED or Blue}

will only be parsed if RED is defined. The other words are ignored. In particular, the existence of BLUE will not be checked for the last case. If you need to check multiple values, you should use the {$IF} construct instead.