--- ibx/trunk/fbintf/IBExternals.pas 2016/12/06 10:33:46 45 +++ ibx/trunk/fbintf/IBExternals.pas 2017/03/06 10:20:02 56 @@ -32,25 +32,30 @@ {************************************************************************} unit IBExternals; +{$IFDEF MSWINDOWS} +{$DEFINE WINDOWS} +{$ENDIF} + +{$IFDEF FPC} +{$mode delphi} +{$codepage UTF8} +{$ENDIF} { Some structures, declarations that we need for the IB stuff to work, but that aren't really part of the ib header file. } interface -uses -{$IFDEF WINDOWS } - Windows -{$ELSE} - unix -{$ENDIF} -; const MaxuShort = 65535; type - Int = LongInt; { 32 bit signed } - UInt = DWord; { 32 bit unsigned } - Long = LongInt; { 32 bit signed } - ULong = DWord; { 32 bit unsigned } + {$IF not declared(FixedInt)} + FixedInt = LongInt; + FixedUInt = LongWord; + {$IFEND} + Int = FixedInt; { 32 bit signed } + UInt = FixedUInt; { 32 bit unsigned } + Long = FixedInt; { 32 bit signed } + ULong = FixedUInt; { 32 bit unsigned } Short = SmallInt;{ 16 bit signed } UShort = Word; { 16 bit unsigned } Float = Single; { 32 bit } @@ -95,7 +100,7 @@ type tm_yday : integer; { Day of year (0--365) } tm_isdst : integer; { 0 if daylight savings time is not in effect) } tm_gmtoff: longint; - tm_zone: PChar; + tm_zone: PAnsiChar; end; PCTimeStructure = ^TCTimeStructure; TM = TCTimeStructure; @@ -103,7 +108,7 @@ type TISC_VARYING = record strlen: Short; - str: array[0..0] of Char; + str: array[0..0] of AnsiChar; end; {***************************} @@ -114,11 +119,11 @@ type {* in original ibase.h *} {***************************} TISC_BlobGetSegment = function(BlobHandle: PInt; - Buffer: PChar; + Buffer: PAnsiChar; BufferSize: Long; var ResultLength: Long): Short; cdecl; TISC_BlobPutSegment = procedure(BlobHandle: PInt; - Buffer: PChar; + Buffer: PAnsiChar; BufferLength: Short); cdecl; TBlob = record GetSegment : TISC_BlobGetSegment; @@ -130,10 +135,6 @@ type end; PBlob = ^TBlob; - {$IF FPC_FULLVERSION < 20700 } - RawByteString = string; {for backwards compatibility} - {$ENDIF} - const { Delphi consts } { Days of week }