diff options
-rw-r--r-- | unicode/src/switches.inc | 30 | ||||
-rw-r--r-- | unicode/src/ultrastardx.dpr | 3 |
2 files changed, 26 insertions, 7 deletions
diff --git a/unicode/src/switches.inc b/unicode/src/switches.inc index cfd57fd4..55d8e619 100644 --- a/unicode/src/switches.inc +++ b/unicode/src/switches.inc @@ -15,14 +15,30 @@ {$ELSE} {$DEFINE Delphi} - // Delphi version numbers (ignore versions released before Delphi 6 as they miss the $IF directive): - // Delphi 6 (VER140), Delphi 7 (VER150), Delphi 8 (VER160) - // Delphi 9/2005 (VER170), Delphi 10/2006 (VER180) + // Delphi version numbers (ignore Delphi < 7 and Delphi 8 (VER160)) - // the inline-procedure directive was introduced with Delphi 2005 - {$IF not (Defined(VER140) or Defined(VER150) or Defined(VER160))} + {$IFDEF VER180} // Delphi 2006 (=10) + {$DEFINE DELPHI_10} + {$DEFINE DELPHI_7_UP} + {$DEFINE DELPHI_9_UP} + {$DEFINE DELPHI_10_UP} + {$ENDIF} + + {$IFDEF VER170} // Delphi 2005 (=9) + {$DEFINE DELPHI_9} + {$DEFINE DELPHI_7_UP} + {$DEFINE DELPHI_9_UP} + {$ENDIF} + + {$IFDEF VER150} // Delphi 7 + {$DEFINE DELPHI_7} + {$DEFINE DELPHI_7_UP} + {$ENDIF} + + // inline directive introduced with Delphi 2005 + {$IFDEF DELPHI_9_UP} {$DEFINE HasInline} - {$IFEND} + {$ENDIF} {$ENDIF} @@ -112,4 +128,4 @@ {$DEFINE UsePortaudio} {$IFEND} -{$ENDIF PASDOC}
\ No newline at end of file +{$ENDIF PASDOC} diff --git a/unicode/src/ultrastardx.dpr b/unicode/src/ultrastardx.dpr index 21e1b15f..0b2ff0bc 100644 --- a/unicode/src/ultrastardx.dpr +++ b/unicode/src/ultrastardx.dpr @@ -140,6 +140,9 @@ uses TntWideStrUtils in 'lib\TntUnicodeControls\TntWideStrUtils.pas', TntClasses in 'lib\TntUnicodeControls\TntClasses.pas', TntFormatStrUtils in 'lib\TntUnicodeControls\TntFormatStrUtils.pas', + {$IFNDEF DELPHI_10_UP} // WideStrings for FPC and Delphi < 2006 + TntWideStrings in 'lib\TntUnicodeControls\TntWideStrings.pas', + {$ENDIF} {$ENDIF} //------------------------------ |