aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authortobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-02-21 11:07:21 +0000
committertobigun <tobigun@b956fd51-792f-4845-bead-9b4dfca2ff2c>2008-02-21 11:07:21 +0000
commitcfbf0943be5d95b5b2aeccfa4149bc943fc1bc3c (patch)
tree20ff0cfb5da501c3faf2711c3517240eefb099c2
parent5142d64ca5edc5499098513912959834b971e75b (diff)
downloadusdx-cfbf0943be5d95b5b2aeccfa4149bc943fc1bc3c.tar.gz
usdx-cfbf0943be5d95b5b2aeccfa4149bc943fc1bc3c.tar.xz
usdx-cfbf0943be5d95b5b2aeccfa4149bc943fc1bc3c.zip
Delphi evaluates every $IF-directive even if it is disabled by a surrounding $IF or $IFDEF so the follwing will give you an error in delphi:
{$IFDEF FPC}{$IF (FPC_VERSION > 2)}...{$IFEND}{$ENDIF} The reason for this error is that FPC_VERSION is not a valid constant. To avoid this error, i defined dummy-consts for delphi. git-svn-id: svn://svn.code.sf.net/p/ultrastardx/svn/trunk@876 b956fd51-792f-4845-bead-9b4dfca2ff2c
Diffstat (limited to '')
-rw-r--r--Game/Code/Classes/UConfig.pas11
1 files changed, 11 insertions, 0 deletions
diff --git a/Game/Code/Classes/UConfig.pas b/Game/Code/Classes/UConfig.pas
index a7b0f328..f850b00f 100644
--- a/Game/Code/Classes/UConfig.pas
+++ b/Game/Code/Classes/UConfig.pas
@@ -130,6 +130,17 @@ const
// (PPC_VERSION_MINOR * VERSION_MINOR) +
// (PPC_VERSION_RELEASE * VERSION_RELEASE);
+ {$IFDEF Delphi}
+ // Delphi evaluates every $IF-directive even if it is disabled by a surrounding
+ // $IF or $IFDEF so the follwing will give you an error in delphi:
+ // {$IFDEF FPC}{$IF (FPC_VERSION > 2)}...{$IFEND}{$ENDIF}
+ // The reason for this error is that FPC_VERSION is not a valid constant.
+ // To avoid this error, we define dummys here.
+ FPC_VERSION = 0;
+ FPC_RELEASE = 0;
+ FPC_PATCH = 0;
+ {$ENDIF}
+
{$IFDEF LAZARUS}
LAZARUS_VERSION = (LAZARUS_VERSION_MAJOR * VERSION_MAJOR) +
(LAZARUS_VERSION_MINOR * VERSION_MINOR) +