forked from exilon/QuickLib
-
Notifications
You must be signed in to change notification settings - Fork 0
/
QuickLib.inc
149 lines (127 loc) · 3.82 KB
/
QuickLib.inc
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
{
This file is part of QuickLib: https://github.com/exilon/QuickLib
QuickLibs. Copyright (C) 2018 Kike Pérez
Exilon - https://www.exilon.es
***************************************************************************
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
http://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
***************************************************************************
}
{$ifdef FPC}
{$MODE DELPHI}
{$INLINE ON}
{$define HASINLINE}
{$ifdef LINUX}
{$define FPCLINUX}
{$endif}
{$ifdef ANDROID}
{$define LINUX}
{$endif}
{$ifdef VER2_7}
{$define ISFPC27}
{$endif}
{$ifdef VER3_0}
{$define ISFPC27}
{$define ISFPC30}
{$endif}
{$ifdef VER3_1}
{$define ISFPC27}
{$define ISFPC30}
{$endif}
{$ifdef FPC_REQUIRES_PROPER_ALIGNMENT}
{$define FPC_ENUMHASINNER}
{$endif}
{$ifdef FPC_HAS_MANAGEMENT_OPERATORS}
{$define ISDELPHI2006ANDUP}
{$endif FPC_HAS_MANAGEMENT_OPERATORS}
{$else FPC}
{$ifdef CONDITIONALEXPRESSIONS} //Delphi 6 or newer
{$define HASINTERFACERTTI} //interface RTTI (not FPC)
{$ifndef LINUX}
{$ifdef VER140}
{$define DELPHI6_UP} //Delphi 6 or newer
{$else}
{$define DELPHI7_UP} //Delphi 7 or newer
{$endif}
{$endif LINUX}
{$if CompilerVersion >= 17}
{$define DELPHI2005_UP} //Delphi 2005 or newer
{$ifend}
{$if CompilerVersion >= 18}
{$define DELPHI2006_UP} //Delphi 2006 or newer
{$define HASINLINE}
{$ifend}
{$if CompilerVersion > 18}
{$define DELPHI2007_UP} //Delphi 2007 or newer
{$ifend}
{$if CompilerVersion = 20}
{$define DELPHI2009_UP} //Delphi 2009
{$ifend}
{$if CompilerVersion >= 21.0} //Delphi 2010
{$define DELPHI2010_UP}
{$define FPC_OR_UNICODE}
{$ifend}
{$if CompilerVersion >= 22.0} //Delphi XE
{$define DELPHIXE_UP}
{$ifend}
{$if CompilerVersion >= 23.0} //Delphi XE2
{$define DELPHIXE2_UP}
{$ifend}
{$if CompilerVersion >= 24.0} //Delphi XE3
{$define DELPHIXE3_UP}
{$ifend}
{$if CompilerVersion >= 25.0} //Delphi XE4
{$define DELPHIXE4_UP}
{$ifend}
{$if CompilerVersion >= 26.0} //Delphi XE5
{$define DELPHIXE5_UP}
{$ifend}
{$if CompilerVersion >= 27.0} //Delphi XE6
{$define DELPHIXE6_UP}
{$ifend}
{$if CompilerVersion >= 28.0} //Delphi XE7
{$define DELPHIXE7_UP}
{$ifend}
{$if CompilerVersion >= 29.0} //Delphi XE8
{$define DELPHIXE8_UP}
{$ifend}
{$if CompilerVersion >= 30.0} //Delphi XE10 Seattle
{$define DELPHIRX10_UP}
{$define DELPHISEATTLE_UP}
{$ifend}
{$if CompilerVersion >= 31.0} //Delphi RX10.1 Berlin
{$define DELPHIRX101_UP}
{$define DELPHIBERLIN_UP}
{$ifend}
{$if CompilerVersion >= 32.0} //Delphi RX10.2 Tokyo
{$define DELPHIRX102_UP}
{$define DELPHITOKYO_UP}
{$ifdef LINUX}
{$define DELPHILINUX}
{$ifend}
{$ifend}
{$else}
//Delphi 5 or older
{$define DELPHI6OROLDER}
{$define DELPHI5OROLDER}
{$define DELPHI5ORFPC}
{$define MSWINDOWS}
{$endif}
{$endif FPC}
{$ifdef VER150}
{$WARN SYMBOL_DEPRECATED OFF}
{$WARN UNSAFE_TYPE OFF}
{$WARN UNSAFE_CODE OFF}
{$WARN UNSAFE_CAST OFF}
{$ENDIF}
{$ifdef CONDITIONALEXPRESSIONS} //Delphi 6 or newer
{.$WARN SYMBOL_PLATFORM OFF}
{.$WARN UNIT_PLATFORM OFF}
{$endif}