summaryrefslogtreecommitdiff
path: root/qmake
authoreilers <eilers>2003-11-03 16:52:18 (UTC)
committer eilers <eilers>2003-11-03 16:52:18 (UTC)
commitd34dc773591a2d467c68875a68a671d6a809f861 (patch) (unidiff)
treeb57e5ae15c51e3d87ca95d57aedfd1ca3db57bfe /qmake
parentce84f2d8bdd65c438821f0457cdad6bbbfa73380 (diff)
downloadopie-d34dc773591a2d467c68875a68a671d6a809f861.zip
opie-d34dc773591a2d467c68875a68a671d6a809f861.tar.gz
opie-d34dc773591a2d467c68875a68a671d6a809f861.tar.bz2
Porting Opie to MacOS-X.
The base system and all platform independent applications and platforms should work. Please see $OPIEDIR/development/macosx for details
Diffstat (limited to 'qmake') (more/less context) (ignore whitespace changes)
-rw-r--r--qmake/include/qglobal.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/qmake/include/qglobal.h b/qmake/include/qglobal.h
index d212bff..94e5607 100644
--- a/qmake/include/qglobal.h
+++ b/qmake/include/qglobal.h
@@ -1,541 +1,548 @@
1/**************************************************************************** 1/****************************************************************************
2** $Id$ 2** $Id$
3** 3**
4** Global type declarations and definitions 4** Global type declarations and definitions
5** 5**
6** Created : 920529 6** Created : 920529
7** 7**
8** Copyright (C) 1992-2002 Trolltech AS. All rights reserved. 8** Copyright (C) 1992-2002 Trolltech AS. All rights reserved.
9** 9**
10** This file is part of the tools module of the Qt GUI Toolkit. 10** This file is part of the tools module of the Qt GUI Toolkit.
11** 11**
12** This file may be distributed under the terms of the Q Public License 12** This file may be distributed under the terms of the Q Public License
13** as defined by Trolltech AS of Norway and appearing in the file 13** as defined by Trolltech AS of Norway and appearing in the file
14** LICENSE.QPL included in the packaging of this file. 14** LICENSE.QPL included in the packaging of this file.
15** 15**
16** This file may be distributed and/or modified under the terms of the 16** This file may be distributed and/or modified under the terms of the
17** GNU General Public License version 2 as published by the Free Software 17** GNU General Public License version 2 as published by the Free Software
18** Foundation and appearing in the file LICENSE.GPL included in the 18** Foundation and appearing in the file LICENSE.GPL included in the
19** packaging of this file. 19** packaging of this file.
20** 20**
21** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition 21** Licensees holding valid Qt Enterprise Edition or Qt Professional Edition
22** licenses may use this file in accordance with the Qt Commercial License 22** licenses may use this file in accordance with the Qt Commercial License
23** Agreement provided with the Software. 23** Agreement provided with the Software.
24** 24**
25** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE 25** This file is provided AS IS with NO WARRANTY OF ANY KIND, INCLUDING THE
26** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. 26** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
27** 27**
28** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for 28** See http://www.trolltech.com/pricing.html or email sales@trolltech.com for
29** information about Qt Commercial License Agreements. 29** information about Qt Commercial License Agreements.
30** See http://www.trolltech.com/qpl/ for QPL licensing information. 30** See http://www.trolltech.com/qpl/ for QPL licensing information.
31** See http://www.trolltech.com/gpl/ for GPL licensing information. 31** See http://www.trolltech.com/gpl/ for GPL licensing information.
32** 32**
33** Contact info@trolltech.com if any conditions of this licensing are 33** Contact info@trolltech.com if any conditions of this licensing are
34** not clear to you. 34** not clear to you.
35** 35**
36**********************************************************************/ 36**********************************************************************/
37 37
38#ifndef QGLOBAL_H 38#ifndef QGLOBAL_H
39#define QGLOBAL_H 39#define QGLOBAL_H
40 40
41#define QT_VERSION_STR "3.1.2" 41#define QT_VERSION_STR "3.1.2"
42/* 42/*
43 QT_VERSION is (major << 16) + (minor << 8) + patch. 43 QT_VERSION is (major << 16) + (minor << 8) + patch.
44 */ 44 */
45#define QT_VERSION 0x030102 45#define QT_VERSION 0x030102
46 46
47/* 47/*
48 The operating system, must be one of: (Q_OS_x) 48 The operating system, must be one of: (Q_OS_x)
49 49
50 MACX- Mac OS X 50 MACX- Mac OS X
51 MAC9- Mac OS 9 51 MAC9- Mac OS 9
52 MSDOS- MS-DOS and Windows 52 MSDOS- MS-DOS and Windows
53 OS2- OS/2 53 OS2- OS/2
54 OS2EMX- XFree86 on OS/2 (not PM) 54 OS2EMX- XFree86 on OS/2 (not PM)
55 WIN32- Win32 (Windows 95/98/ME and Windows NT/2000/XP) 55 WIN32- Win32 (Windows 95/98/ME and Windows NT/2000/XP)
56 CYGWIN- Cygwin 56 CYGWIN- Cygwin
57 SOLARIS- Sun Solaris 57 SOLARIS- Sun Solaris
58 HPUX- HP-UX 58 HPUX- HP-UX
59 ULTRIX- DEC Ultrix 59 ULTRIX- DEC Ultrix
60 LINUX- Linux 60 LINUX- Linux
61 FREEBSD- FreeBSD 61 FREEBSD- FreeBSD
62 NETBSD- NetBSD 62 NETBSD- NetBSD
63 OPENBSD- OpenBSD 63 OPENBSD- OpenBSD
64 BSDI- BSD/OS 64 BSDI- BSD/OS
65 IRIX- SGI Irix 65 IRIX- SGI Irix
66 OSF- HP Tru64 UNIX 66 OSF- HP Tru64 UNIX
67 SCO- SCO OpenServer 5 67 SCO- SCO OpenServer 5
68 UNIXWARE- UnixWare 7, Open UNIX 8 68 UNIXWARE- UnixWare 7, Open UNIX 8
69 AIX- AIX 69 AIX- AIX
70 HURD- GNU Hurd 70 HURD- GNU Hurd
71 DGUX- DG/UX 71 DGUX- DG/UX
72 RELIANT- Reliant UNIX 72 RELIANT- Reliant UNIX
73 DYNIX- DYNIX/ptx 73 DYNIX- DYNIX/ptx
74 QNX- QNX 74 QNX- QNX
75 QNX6- QNX RTP 6.1 75 QNX6- QNX RTP 6.1
76 LYNX- LynxOS 76 LYNX- LynxOS
77 BSD4- Any BSD 4.4 system 77 BSD4- Any BSD 4.4 system
78 UNIX- Any UNIX BSD/SYSV system 78 UNIX- Any UNIX BSD/SYSV system
79*/ 79*/
80 80
81#if defined(__APPLE__) && defined(__GNUC__) 81#if defined(__APPLE__) && defined(__GNUC__)
82# define Q_OS_MACX 82# define Q_OS_MACX
83#elif defined(__MACOSX__) 83#elif defined(__MACOSX__)
84# define Q_OS_MACX 84# define Q_OS_MACX
85#elif defined(macintosh) 85#elif defined(macintosh)
86# define Q_OS_MAC9 86# define Q_OS_MAC9
87#elif defined(__CYGWIN__) 87#elif defined(__CYGWIN__)
88# define Q_OS_CYGWIN 88# define Q_OS_CYGWIN
89#elif defined(MSDOS) || defined(_MSDOS) 89#elif defined(MSDOS) || defined(_MSDOS)
90# define Q_OS_MSDOS 90# define Q_OS_MSDOS
91#elif defined(__OS2__) 91#elif defined(__OS2__)
92# if defined(__EMX__) 92# if defined(__EMX__)
93# define Q_OS_OS2EMX 93# define Q_OS_OS2EMX
94# else 94# else
95# define Q_OS_OS2 95# define Q_OS_OS2
96# endif 96# endif
97#elif !defined(SAG_COM) && (defined(WIN64) || defined(_WIN64) || defined(__WIN64__)) 97#elif !defined(SAG_COM) && (defined(WIN64) || defined(_WIN64) || defined(__WIN64__))
98# define Q_OS_WIN32 98# define Q_OS_WIN32
99# define Q_OS_WIN64 99# define Q_OS_WIN64
100#elif !defined(SAG_COM) && (defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__)) 100#elif !defined(SAG_COM) && (defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__))
101# define Q_OS_WIN32 101# define Q_OS_WIN32
102#elif defined(__MWERKS__) && defined(__INTEL__) 102#elif defined(__MWERKS__) && defined(__INTEL__)
103# define Q_OS_WIN32 103# define Q_OS_WIN32
104#elif defined(__sun) || defined(sun) 104#elif defined(__sun) || defined(sun)
105# define Q_OS_SOLARIS 105# define Q_OS_SOLARIS
106#elif defined(hpux) || defined(__hpux) 106#elif defined(hpux) || defined(__hpux)
107# define Q_OS_HPUX 107# define Q_OS_HPUX
108#elif defined(__ultrix) || defined(ultrix) 108#elif defined(__ultrix) || defined(ultrix)
109# define Q_OS_ULTRIX 109# define Q_OS_ULTRIX
110#elif defined(sinix) 110#elif defined(sinix)
111# define Q_OS_RELIANT 111# define Q_OS_RELIANT
112#elif defined(__linux__) || defined(__linux) 112#elif defined(__linux__) || defined(__linux)
113# define Q_OS_LINUX 113# define Q_OS_LINUX
114#elif defined(__FreeBSD__) 114#elif defined(__FreeBSD__)
115# define Q_OS_FREEBSD 115# define Q_OS_FREEBSD
116# define Q_OS_BSD4 116# define Q_OS_BSD4
117#elif defined(__NetBSD__) 117#elif defined(__NetBSD__)
118# define Q_OS_NETBSD 118# define Q_OS_NETBSD
119# define Q_OS_BSD4 119# define Q_OS_BSD4
120#elif defined(__OpenBSD__) 120#elif defined(__OpenBSD__)
121# define Q_OS_OPENBSD 121# define Q_OS_OPENBSD
122# define Q_OS_BSD4 122# define Q_OS_BSD4
123#elif defined(__bsdi__) 123#elif defined(__bsdi__)
124# define Q_OS_BSDI 124# define Q_OS_BSDI
125# define Q_OS_BSD4 125# define Q_OS_BSD4
126#elif defined(__sgi) 126#elif defined(__sgi)
127# define Q_OS_IRIX 127# define Q_OS_IRIX
128#elif defined(__osf__) 128#elif defined(__osf__)
129# define Q_OS_OSF 129# define Q_OS_OSF
130#elif defined(_AIX) 130#elif defined(_AIX)
131# define Q_OS_AIX 131# define Q_OS_AIX
132#elif defined(__Lynx__) 132#elif defined(__Lynx__)
133# define Q_OS_LYNX 133# define Q_OS_LYNX
134#elif defined(__GNU_HURD__) 134#elif defined(__GNU_HURD__)
135# define Q_OS_HURD 135# define Q_OS_HURD
136#elif defined(__DGUX__) 136#elif defined(__DGUX__)
137# define Q_OS_DGUX 137# define Q_OS_DGUX
138#elif defined(__QNXNTO__) 138#elif defined(__QNXNTO__)
139# define Q_OS_QNX6 139# define Q_OS_QNX6
140#elif defined(__QNX__) 140#elif defined(__QNX__)
141# define Q_OS_QNX 141# define Q_OS_QNX
142#elif defined(_SEQUENT_) 142#elif defined(_SEQUENT_)
143# define Q_OS_DYNIX 143# define Q_OS_DYNIX
144#elif defined(_SCO_DS) /* SCO OpenServer 5 + GCC */ 144#elif defined(_SCO_DS) /* SCO OpenServer 5 + GCC */
145# define Q_OS_SCO 145# define Q_OS_SCO
146#elif defined(__USLC__) /* all SCO platforms + UDK or OUDK */ 146#elif defined(__USLC__) /* all SCO platforms + UDK or OUDK */
147# define Q_OS_UNIXWARE 147# define Q_OS_UNIXWARE
148# define Q_OS_UNIXWARE7 148# define Q_OS_UNIXWARE7
149#elif defined(__svr4__) && defined(i386) /* Open UNIX 8 + GCC */ 149#elif defined(__svr4__) && defined(i386) /* Open UNIX 8 + GCC */
150# define Q_OS_UNIXWARE 150# define Q_OS_UNIXWARE
151# define Q_OS_UNIXWARE7 151# define Q_OS_UNIXWARE7
152#else 152#else
153# error "Qt has not been ported to this OS - talk to qt-bugs@trolltech.com" 153# error "Qt has not been ported to this OS - talk to qt-bugs@trolltech.com"
154#endif 154#endif
155 155
156#if defined(Q_OS_MAC9) || defined(Q_OS_MACX) 156#if defined(Q_OS_MAC9) || defined(Q_OS_MACX)
157# define Q_OS_MAC 157/* This hack forces the generater to compile qmake not for maxosx native. It is
158 * compiled for Linux and generates usual makefiles..
159 * Does anyone has a better solution for this ? (eilers)
160 */
161// # define Q_OS_MAC
162#define Q_OS_LINUX
163#warning "boeser Hack !! (se)"
164#undef Q_OS_MACX
158#endif 165#endif
159 166
160#if defined(Q_OS_MAC9) || defined(Q_OS_MSDOS) || defined(Q_OS_OS2) || defined(Q_OS_WIN32) || defined(Q_OS_WIN64) 167#if defined(Q_OS_MAC9) || defined(Q_OS_MSDOS) || defined(Q_OS_OS2) || defined(Q_OS_WIN32) || defined(Q_OS_WIN64)
161# undef Q_OS_UNIX 168# undef Q_OS_UNIX
162#elif !defined(Q_OS_UNIX) 169#elif !defined(Q_OS_UNIX)
163# define Q_OS_UNIX 170# define Q_OS_UNIX
164#endif 171#endif
165 172
166 173
167/* 174/*
168 The compiler, must be one of: (Q_CC_x) 175 The compiler, must be one of: (Q_CC_x)
169 176
170 SYM- Symantec C++ for both PC and Macintosh 177 SYM- Symantec C++ for both PC and Macintosh
171 MPW- MPW C++ 178 MPW- MPW C++
172 MWERKS- Metrowerks CodeWarrior 179 MWERKS- Metrowerks CodeWarrior
173 MSVC- Microsoft Visual C/C++ 180 MSVC- Microsoft Visual C/C++
174 BOR- Borland/Turbo C++ 181 BOR- Borland/Turbo C++
175 WAT- Watcom C++ 182 WAT- Watcom C++
176 GNU- GNU C++ 183 GNU- GNU C++
177 COMEAU- Comeau C++ 184 COMEAU- Comeau C++
178 EDG- Edison Design Group C++ 185 EDG- Edison Design Group C++
179 OC - CenterLine C++ 186 OC - CenterLine C++
180 SUN- Sun WorkShop, Forte Developer, or Sun ONE Studio C++ 187 SUN- Sun WorkShop, Forte Developer, or Sun ONE Studio C++
181 MIPS- MIPSpro C++ 188 MIPS- MIPSpro C++
182 DEC- DEC C++ 189 DEC- DEC C++
183 HP - HPUX C++ 190 HP - HPUX C++
184 HPACC- HPUX ANSI C++ 191 HPACC- HPUX ANSI C++
185 USLC- SCO OUDK, UDK, and UnixWare 2.X C++ 192 USLC- SCO OUDK, UDK, and UnixWare 2.X C++
186 CDS- Reliant C++ 193 CDS- Reliant C++
187 KAI- KAI C++ 194 KAI- KAI C++
188 INTEL- Intel C++ 195 INTEL- Intel C++
189 HIGHC- MetaWare High C/C++ 196 HIGHC- MetaWare High C/C++
190 PGI- Portland Group C++ 197 PGI- Portland Group C++
191 GHS- Green Hills Optimizing C++ Compilers 198 GHS- Green Hills Optimizing C++ Compilers
192 199
193 Should be sorted most to least authoritative. 200 Should be sorted most to least authoritative.
194*/ 201*/
195 202
196/* Symantec C++ is now Digital Mars */ 203/* Symantec C++ is now Digital Mars */
197#if defined(__DMC__) || defined(__SC__) 204#if defined(__DMC__) || defined(__SC__)
198# define Q_CC_SYM 205# define Q_CC_SYM
199/* "explicit" semantics implemented in 8.1e but keyword recognized since 7.5 */ 206/* "explicit" semantics implemented in 8.1e but keyword recognized since 7.5 */
200# if defined(__SC__) && __SC__ < 0x750 207# if defined(__SC__) && __SC__ < 0x750
201# define Q_NO_EXPLICIT_KEYWORD 208# define Q_NO_EXPLICIT_KEYWORD
202# endif 209# endif
203# define Q_NO_USING_KEYWORD 210# define Q_NO_USING_KEYWORD
204# if !defined(_CPPUNWIND) 211# if !defined(_CPPUNWIND)
205# define Q_NO_EXCEPTIONS 212# define Q_NO_EXCEPTIONS
206# endif 213# endif
207 214
208#elif defined(applec) 215#elif defined(applec)
209# define Q_CC_MPW 216# define Q_CC_MPW
210# define Q_NO_BOOL_TYPE 217# define Q_NO_BOOL_TYPE
211# define Q_NO_EXPLICIT_KEYWORD 218# define Q_NO_EXPLICIT_KEYWORD
212# define Q_NO_USING_KEYWORD 219# define Q_NO_USING_KEYWORD
213 220
214#elif defined(__MWERKS__) 221#elif defined(__MWERKS__)
215# define Q_CC_MWERKS 222# define Q_CC_MWERKS
216/* "explicit" recognized since 4.0d1 */ 223/* "explicit" recognized since 4.0d1 */
217# define QMAC_PASCAL pascal 224# define QMAC_PASCAL pascal
218# define Q_NO_USING_KEYWORD /* ### check "using" status */ 225# define Q_NO_USING_KEYWORD /* ### check "using" status */
219 226
220#elif defined(_MSC_VER) 227#elif defined(_MSC_VER)
221# define Q_CC_MSVC 228# define Q_CC_MSVC
222/* proper support of bool for _MSC_VER >= 1100 */ 229/* proper support of bool for _MSC_VER >= 1100 */
223# define Q_CANNOT_DELETE_CONSTANT 230# define Q_CANNOT_DELETE_CONSTANT
224# define Q_INLINE_TEMPLATES inline 231# define Q_INLINE_TEMPLATES inline
225/* Visual C++.Net issues for _MSC_VER >= 1300 */ 232/* Visual C++.Net issues for _MSC_VER >= 1300 */
226# if _MSC_VER >= 1300 233# if _MSC_VER >= 1300
227# define Q_CC_MSVC_NET 234# define Q_CC_MSVC_NET
228# if _MSC_VER < 1310 235# if _MSC_VER < 1310
229# define Q_TYPENAME 236# define Q_TYPENAME
230# endif 237# endif
231# endif 238# endif
232# define Q_NO_USING_KEYWORD /* ### check "using" status */ 239# define Q_NO_USING_KEYWORD /* ### check "using" status */
233 240
234#elif defined(__BORLANDC__) || defined(__TURBOC__) 241#elif defined(__BORLANDC__) || defined(__TURBOC__)
235# define Q_CC_BOR 242# define Q_CC_BOR
236# if __BORLANDC__ < 0x502 243# if __BORLANDC__ < 0x502
237# define Q_NO_BOOL_TYPE 244# define Q_NO_BOOL_TYPE
238# define Q_NO_EXPLICIT_KEYWORD 245# define Q_NO_EXPLICIT_KEYWORD
239# endif 246# endif
240# define Q_NO_USING_KEYWORD /* ### check "using" status */ 247# define Q_NO_USING_KEYWORD /* ### check "using" status */
241 248
242#elif defined(__WATCOMC__) 249#elif defined(__WATCOMC__)
243# define Q_CC_WAT 250# define Q_CC_WAT
244# if defined(Q_OS_QNX4) 251# if defined(Q_OS_QNX4)
245/* compiler flags */ 252/* compiler flags */
246# define Q_TYPENAME 253# define Q_TYPENAME
247# define Q_NO_BOOL_TYPE 254# define Q_NO_BOOL_TYPE
248# define Q_CANNOT_DELETE_CONSTANT 255# define Q_CANNOT_DELETE_CONSTANT
249# define mutable 256# define mutable
250/* ??? */ 257/* ??? */
251# define Q_BROKEN_TEMPLATE_SPECIALIZATION 258# define Q_BROKEN_TEMPLATE_SPECIALIZATION
252/* no template classes in QVariant */ 259/* no template classes in QVariant */
253# define QT_NO_TEMPLATE_VARIANT 260# define QT_NO_TEMPLATE_VARIANT
254/* Wcc does not fill in functions needed by valuelists, maps, and 261/* Wcc does not fill in functions needed by valuelists, maps, and
255 valuestacks implicitly */ 262 valuestacks implicitly */
256# define Q_FULL_TEMPLATE_INSTANTIATION 263# define Q_FULL_TEMPLATE_INSTANTIATION
257/* can we just compare the structures? */ 264/* can we just compare the structures? */
258# define Q_FULL_TEMPLATE_INSTANTIATION_MEMCMP 265# define Q_FULL_TEMPLATE_INSTANTIATION_MEMCMP
259/* these are not useful to our customers */ 266/* these are not useful to our customers */
260# define QT_QWS_NO_SHM 267# define QT_QWS_NO_SHM
261# define QT_NO_QWS_MULTIPROCESS 268# define QT_NO_QWS_MULTIPROCESS
262# define QT_NO_SQL 269# define QT_NO_SQL
263# define QT_NO_QWS_CURSOR 270# define QT_NO_QWS_CURSOR
264# endif 271# endif
265 272
266#elif defined(__GNUC__) 273#elif defined(__GNUC__)
267# define Q_CC_GNU 274# define Q_CC_GNU
268# define Q_C_CALLBACKS 275# define Q_C_CALLBACKS
269# if __GNUC__ == 2 && __GNUC_MINOR__ <= 7 276# if __GNUC__ == 2 && __GNUC_MINOR__ <= 7
270# define Q_FULL_TEMPLATE_INSTANTIATION 277# define Q_FULL_TEMPLATE_INSTANTIATION
271# endif 278# endif
272/* GCC 2.95 knows "using" but does not support it correctly */ 279/* GCC 2.95 knows "using" but does not support it correctly */
273# if __GNUC__ == 2 && __GNUC_MINOR__ <= 95 280# if __GNUC__ == 2 && __GNUC_MINOR__ <= 95
274# define Q_NO_USING_KEYWORD 281# define Q_NO_USING_KEYWORD
275# endif 282# endif
276/* GCC 3.1 and GCC 3.2 wrongly define _SB_CTYPE_MACROS on HP-UX */ 283/* GCC 3.1 and GCC 3.2 wrongly define _SB_CTYPE_MACROS on HP-UX */
277# if defined(Q_OS_HPUX) && __GNUC__ == 3 && __GNUC_MINOR__ >= 1 284# if defined(Q_OS_HPUX) && __GNUC__ == 3 && __GNUC_MINOR__ >= 1
278# define Q_WRONG_SB_CTYPE_MACROS 285# define Q_WRONG_SB_CTYPE_MACROS
279# endif 286# endif
280# if (defined(__arm__) || defined(__ARMEL__)) && !defined(QT_MOC_CPP) 287# if (defined(__arm__) || defined(__ARMEL__)) && !defined(QT_MOC_CPP)
281# define Q_PACKED __attribute__ ((packed)) 288# define Q_PACKED __attribute__ ((packed))
282# endif 289# endif
283# if !defined(__EXCEPTIONS) 290# if !defined(__EXCEPTIONS)
284# define Q_NO_EXCEPTIONS 291# define Q_NO_EXCEPTIONS
285# endif 292# endif
286 293
287/* IBM compiler versions are a bit messy. There are actually two products: 294/* IBM compiler versions are a bit messy. There are actually two products:
288 the C product, and the C++ product. The C++ compiler is always packaged 295 the C product, and the C++ product. The C++ compiler is always packaged
289 with the latest version of the C compiler. Version numbers do not always 296 with the latest version of the C compiler. Version numbers do not always
290 match. This little table (I'm not sure it's accurate) should be helpful: 297 match. This little table (I'm not sure it's accurate) should be helpful:
291 298
292 C++ product C product 299 C++ product C product
293 300
294 C Set 3.1 C Compiler 3.0 301 C Set 3.1 C Compiler 3.0
295 ... ... 302 ... ...
296 C++ Compiler 3.6.6 C Compiler 4.3 303 C++ Compiler 3.6.6 C Compiler 4.3
297 ... ... 304 ... ...
298 Visual Age C++ 4.0 ... 305 Visual Age C++ 4.0 ...
299 ... ... 306 ... ...
300 Visual Age C++ 5.0 C Compiler 5.0 307 Visual Age C++ 5.0 C Compiler 5.0
301 308
302 Now: 309 Now:
303 __xlC__ is the version of the C compiler in hexadecimal notation 310 __xlC__ is the version of the C compiler in hexadecimal notation
304 is only an approximation of the C++ compiler version 311 is only an approximation of the C++ compiler version
305 __IBMCPP__ is the version of the C++ compiler in decimal notation 312 __IBMCPP__ is the version of the C++ compiler in decimal notation
306 but it is not defined on older compilers like C Set 3.1 */ 313 but it is not defined on older compilers like C Set 3.1 */
307#elif defined(__xlC__) 314#elif defined(__xlC__)
308# define Q_CC_XLC 315# define Q_CC_XLC
309# define Q_FULL_TEMPLATE_INSTANTIATION 316# define Q_FULL_TEMPLATE_INSTANTIATION
310# if __xlC__ < 0x400 317# if __xlC__ < 0x400
311# define Q_NO_BOOL_TYPE 318# define Q_NO_BOOL_TYPE
312# define Q_NO_EXPLICIT_KEYWORD 319# define Q_NO_EXPLICIT_KEYWORD
313# define Q_NO_USING_KEYWORD 320# define Q_NO_USING_KEYWORD
314# define Q_TYPENAME 321# define Q_TYPENAME
315# define Q_INLINE_TEMPLATES inline 322# define Q_INLINE_TEMPLATES inline
316# define Q_BROKEN_TEMPLATE_SPECIALIZATION 323# define Q_BROKEN_TEMPLATE_SPECIALIZATION
317# define Q_CANNOT_DELETE_CONSTANT 324# define Q_CANNOT_DELETE_CONSTANT
318# endif 325# endif
319 326
320/* Older versions of DEC C++ do not define __EDG__ or __EDG - observed 327/* Older versions of DEC C++ do not define __EDG__ or __EDG - observed
321 on DEC C++ V5.5-004. New versions do define __EDG__ - observed on 328 on DEC C++ V5.5-004. New versions do define __EDG__ - observed on
322 Compaq C++ V6.3-002. 329 Compaq C++ V6.3-002.
323 This compiler is different enough from other EDG compilers to handle 330 This compiler is different enough from other EDG compilers to handle
324 it separately anyway. */ 331 it separately anyway. */
325#elif defined(__DECCXX) 332#elif defined(__DECCXX)
326# define Q_CC_DEC 333# define Q_CC_DEC
327/* Compaq C++ V6 compilers are EDG-based but I'm not sure about older 334/* Compaq C++ V6 compilers are EDG-based but I'm not sure about older
328 DEC C++ V5 compilers. */ 335 DEC C++ V5 compilers. */
329# if defined(__EDG__) 336# if defined(__EDG__)
330# define Q_CC_EDG 337# define Q_CC_EDG
331# endif 338# endif
332/* Compaq have disabled EDG's _BOOL macro and use _BOOL_EXISTS instead 339/* Compaq have disabled EDG's _BOOL macro and use _BOOL_EXISTS instead
333 - observed on Compaq C++ V6.3-002. 340 - observed on Compaq C++ V6.3-002.
334 In any case versions prior to Compaq C++ V6.0-005 do not have bool. */ 341 In any case versions prior to Compaq C++ V6.0-005 do not have bool. */
335# if !defined(_BOOL_EXISTS) 342# if !defined(_BOOL_EXISTS)
336# define Q_NO_BOOL_TYPE 343# define Q_NO_BOOL_TYPE
337# endif 344# endif
338/* Spurious (?) error messages observed on Compaq C++ V6.5-014. */ 345/* Spurious (?) error messages observed on Compaq C++ V6.5-014. */
339# define Q_NO_USING_KEYWORD 346# define Q_NO_USING_KEYWORD
340/* Apply to all versions prior to Compaq C++ V6.0-000 - observed on 347/* Apply to all versions prior to Compaq C++ V6.0-000 - observed on
341 DEC C++ V5.5-004. */ 348 DEC C++ V5.5-004. */
342# if __DECCXX_VER < 60060000 349# if __DECCXX_VER < 60060000
343# define Q_TYPENAME 350# define Q_TYPENAME
344# define Q_BROKEN_TEMPLATE_SPECIALIZATION 351# define Q_BROKEN_TEMPLATE_SPECIALIZATION
345# define Q_CANNOT_DELETE_CONSTANT 352# define Q_CANNOT_DELETE_CONSTANT
346# endif 353# endif
347/* avoid undefined symbol problems with out-of-line template members */ 354/* avoid undefined symbol problems with out-of-line template members */
348# define Q_INLINE_TEMPLATES inline 355# define Q_INLINE_TEMPLATES inline
349 356
350/* Compilers with EDG front end are similar. To detect them we test: 357/* Compilers with EDG front end are similar. To detect them we test:
351 __EDG documented by SGI, observed on MIPSpro 7.3.1.1 and KAI C++ 4.0b 358 __EDG documented by SGI, observed on MIPSpro 7.3.1.1 and KAI C++ 4.0b
352 __EDG__ documented in EDG online docs, observed on Compaq C++ V6.3-002 */ 359 __EDG__ documented in EDG online docs, observed on Compaq C++ V6.3-002 */
353#elif defined(__EDG) || defined(__EDG__) 360#elif defined(__EDG) || defined(__EDG__)
354# define Q_CC_EDG 361# define Q_CC_EDG
355/* From the EDG documentation (does not seem to apply to Compaq C++): 362/* From the EDG documentation (does not seem to apply to Compaq C++):
356 _BOOL 363 _BOOL
357 Defined in C++ mode when bool is a keyword. The name of this 364 Defined in C++ mode when bool is a keyword. The name of this
358 predefined macro is specified by a configuration flag. _BOOL 365 predefined macro is specified by a configuration flag. _BOOL
359 is the default. 366 is the default.
360 __BOOL_DEFINED 367 __BOOL_DEFINED
361 Defined in Microsoft C++ mode when bool is a keyword. */ 368 Defined in Microsoft C++ mode when bool is a keyword. */
362# if !defined(_BOOL) && !defined(__BOOL_DEFINED) 369# if !defined(_BOOL) && !defined(__BOOL_DEFINED)
363# define Q_NO_BOOL_TYPE 370# define Q_NO_BOOL_TYPE
364# endif 371# endif
365 372
366/* The Portland Group compiler is based on EDG and does define __EDG__ */ 373/* The Portland Group compiler is based on EDG and does define __EDG__ */
367# if defined(__COMO__) 374# if defined(__COMO__)
368# define Q_CC_COMEAU 375# define Q_CC_COMEAU
369# define Q_C_CALLBACKS 376# define Q_C_CALLBACKS
370 377
371/* Using the `using' keyword avoids KAI C++ warnings */ 378/* Using the `using' keyword avoids KAI C++ warnings */
372# elif defined(__KCC) 379# elif defined(__KCC)
373# define Q_CC_KAI 380# define Q_CC_KAI
374# if !defined(_EXCEPTIONS) 381# if !defined(_EXCEPTIONS)
375# define Q_NO_EXCEPTIONS 382# define Q_NO_EXCEPTIONS
376# endif 383# endif
377 384
378/* Using the `using' keyword avoids Intel C++ warnings */ 385/* Using the `using' keyword avoids Intel C++ warnings */
379# elif defined(__INTEL_COMPILER) 386# elif defined(__INTEL_COMPILER)
380# define Q_CC_INTEL 387# define Q_CC_INTEL
381# if !defined(__EXCEPTIONS) 388# if !defined(__EXCEPTIONS)
382# define Q_NO_EXCEPTIONS 389# define Q_NO_EXCEPTIONS
383# endif 390# endif
384 391
385/* The Portland Group compiler is based on EDG and does define __EDG__ */ 392/* The Portland Group compiler is based on EDG and does define __EDG__ */
386# elif defined(__PGI) 393# elif defined(__PGI)
387# define Q_CC_PGI 394# define Q_CC_PGI
388# if !defined(__EXCEPTIONS) 395# if !defined(__EXCEPTIONS)
389# define Q_NO_EXCEPTIONS 396# define Q_NO_EXCEPTIONS
390# endif 397# endif
391 398
392/* Never tested! */ 399/* Never tested! */
393# elif defined(__ghs) 400# elif defined(__ghs)
394# define Q_CC_GHS 401# define Q_CC_GHS
395 402
396/* The UnixWare 7 UDK compiler is based on EDG and does define __EDG__ */ 403/* The UnixWare 7 UDK compiler is based on EDG and does define __EDG__ */
397# elif defined(__USLC__) && defined(__SCO_VERSION__) 404# elif defined(__USLC__) && defined(__SCO_VERSION__)
398# define Q_CC_USLC 405# define Q_CC_USLC
399/* The latest UDK 7.1.1b does not need this, but previous versions do */ 406/* The latest UDK 7.1.1b does not need this, but previous versions do */
400# if !defined(__SCO_VERSION__) || (__SCO_VERSION__ < 302200010) 407# if !defined(__SCO_VERSION__) || (__SCO_VERSION__ < 302200010)
401# define Q_INLINE_TEMPLATES inline 408# define Q_INLINE_TEMPLATES inline
402# endif 409# endif
403# define Q_NO_USING_KEYWORD /* ### check "using" status */ 410# define Q_NO_USING_KEYWORD /* ### check "using" status */
404 411
405/* Never tested! */ 412/* Never tested! */
406# elif defined(CENTERLINE_CLPP) || defined(OBJECTCENTER) 413# elif defined(CENTERLINE_CLPP) || defined(OBJECTCENTER)
407# define Q_CC_OC 414# define Q_CC_OC
408# define Q_NO_USING_KEYWORD 415# define Q_NO_USING_KEYWORD
409 416
410/* CDS++ defines __EDG__ although this is not documented in the Reliant 417/* CDS++ defines __EDG__ although this is not documented in the Reliant
411 documentation. It also follows conventions like _BOOL and this documented */ 418 documentation. It also follows conventions like _BOOL and this documented */
412# elif defined(sinix) 419# elif defined(sinix)
413# define Q_CC_CDS 420# define Q_CC_CDS
414# define Q_NO_USING_KEYWORD 421# define Q_NO_USING_KEYWORD
415# if defined(__cplusplus) && (__cplusplus < 2) /* Cfront C++ mode */ 422# if defined(__cplusplus) && (__cplusplus < 2) /* Cfront C++ mode */
416# define Q_NO_EXCEPTIONS 423# define Q_NO_EXCEPTIONS
417# endif 424# endif
418 425
419/* The MIPSpro compiler in o32 mode is based on EDG but disables features 426/* The MIPSpro compiler in o32 mode is based on EDG but disables features
420 such as template specialization nevertheless */ 427 such as template specialization nevertheless */
421# elif defined(__sgi) 428# elif defined(__sgi)
422# define Q_CC_MIPS 429# define Q_CC_MIPS
423# if defined(_MIPS_SIM) && (_MIPS_SIM == _ABIO32) /* o32 ABI */ 430# if defined(_MIPS_SIM) && (_MIPS_SIM == _ABIO32) /* o32 ABI */
424# define Q_TYPENAME 431# define Q_TYPENAME
425# define Q_BROKEN_TEMPLATE_SPECIALIZATION 432# define Q_BROKEN_TEMPLATE_SPECIALIZATION
426# define Q_STRICT_INLINING_RULES 433# define Q_STRICT_INLINING_RULES
427# define Q_NO_EXPLICIT_KEYWORD 434# define Q_NO_EXPLICIT_KEYWORD
428# define Q_INLINE_TEMPLATES inline 435# define Q_INLINE_TEMPLATES inline
429# elif defined(_COMPILER_VERSION) && (_COMPILER_VERSION < 730) /* 7.2 */ 436# elif defined(_COMPILER_VERSION) && (_COMPILER_VERSION < 730) /* 7.2 */
430# define Q_TYPENAME 437# define Q_TYPENAME
431# define Q_BROKEN_TEMPLATE_SPECIALIZATION 438# define Q_BROKEN_TEMPLATE_SPECIALIZATION
432# endif 439# endif
433# define Q_NO_USING_KEYWORD /* ### check "using" status */ 440# define Q_NO_USING_KEYWORD /* ### check "using" status */
434# endif 441# endif
435 442
436/* The older UnixWare 2.X compiler? */ 443/* The older UnixWare 2.X compiler? */
437#elif defined(__USLC__) 444#elif defined(__USLC__)
438# define Q_CC_USLC 445# define Q_CC_USLC
439# define Q_TYPENAME 446# define Q_TYPENAME
440# define Q_NO_BOOL_TYPE 447# define Q_NO_BOOL_TYPE
441# define Q_NO_EXPLICIT_KEYWORD 448# define Q_NO_EXPLICIT_KEYWORD
442# define Q_NO_USING_KEYWORD 449# define Q_NO_USING_KEYWORD
443# define Q_INLINE_TEMPLATES inline 450# define Q_INLINE_TEMPLATES inline
444 451
445/* Never tested! */ 452/* Never tested! */
446#elif defined(__HIGHC__) 453#elif defined(__HIGHC__)
447# define Q_CC_HIGHC 454# define Q_CC_HIGHC
448 455
449#elif defined(__SUNPRO_CC) 456#elif defined(__SUNPRO_CC)
450# define Q_CC_SUN 457# define Q_CC_SUN
451/* 5.0 compiler or better 458/* 5.0 compiler or better
452 'bool' is enabled by default but can be disabled using -features=nobool 459 'bool' is enabled by default but can be disabled using -features=nobool
453 in which case _BOOL is not defined 460 in which case _BOOL is not defined
454 this is the default in 4.2 compatibility mode triggered by -compat=4 */ 461 this is the default in 4.2 compatibility mode triggered by -compat=4 */
455# if __SUNPRO_CC >= 0x500 462# if __SUNPRO_CC >= 0x500
456# if !defined(_BOOL) 463# if !defined(_BOOL)
457# define Q_NO_BOOL_TYPE 464# define Q_NO_BOOL_TYPE
458# endif 465# endif
459# if defined(__SUNPRO_CC_COMPAT) && (__SUNPRO_CC_COMPAT <= 4) 466# if defined(__SUNPRO_CC_COMPAT) && (__SUNPRO_CC_COMPAT <= 4)
460# define Q_NO_USING_KEYWORD 467# define Q_NO_USING_KEYWORD
461# endif 468# endif
462# define Q_C_CALLBACKS 469# define Q_C_CALLBACKS
463/* 4.2 compiler or older */ 470/* 4.2 compiler or older */
464# else 471# else
465# define Q_NO_BOOL_TYPE 472# define Q_NO_BOOL_TYPE
466# define Q_NO_EXPLICIT_KEYWORD 473# define Q_NO_EXPLICIT_KEYWORD
467# define Q_NO_USING_KEYWORD 474# define Q_NO_USING_KEYWORD
468# endif 475# endif
469 476
470/* CDS++ does not seem to define __EDG__ or __EDG according to Reliant 477/* CDS++ does not seem to define __EDG__ or __EDG according to Reliant
471 documentation but nevertheless uses EDG conventions like _BOOL */ 478 documentation but nevertheless uses EDG conventions like _BOOL */
472#elif defined(sinix) 479#elif defined(sinix)
473# define Q_CC_EDG 480# define Q_CC_EDG
474# define Q_CC_CDS 481# define Q_CC_CDS
475# if !defined(_BOOL) 482# if !defined(_BOOL)
476# define Q_NO_BOOL_TYPE 483# define Q_NO_BOOL_TYPE
477# endif 484# endif
478# define Q_BROKEN_TEMPLATE_SPECIALIZATION 485# define Q_BROKEN_TEMPLATE_SPECIALIZATION
479 486
480#elif defined(Q_OS_HPUX) 487#elif defined(Q_OS_HPUX)
481/* __HP_aCC was not defined in first aCC releases */ 488/* __HP_aCC was not defined in first aCC releases */
482# if defined(__HP_aCC) || __cplusplus >= 199707L 489# if defined(__HP_aCC) || __cplusplus >= 199707L
483# define Q_CC_HPACC 490# define Q_CC_HPACC
484# else 491# else
485# define Q_CC_HP 492# define Q_CC_HP
486# define Q_NO_BOOL_TYPE 493# define Q_NO_BOOL_TYPE
487# define Q_FULL_TEMPLATE_INSTANTIATION 494# define Q_FULL_TEMPLATE_INSTANTIATION
488# define Q_BROKEN_TEMPLATE_SPECIALIZATION 495# define Q_BROKEN_TEMPLATE_SPECIALIZATION
489# define Q_NO_EXPLICIT_KEYWORD 496# define Q_NO_EXPLICIT_KEYWORD
490# endif 497# endif
491# define Q_NO_USING_KEYWORD /* ### check "using" status */ 498# define Q_NO_USING_KEYWORD /* ### check "using" status */
492 499
493#else 500#else
494# error "Qt has not been tested with this compiler - talk to qt-bugs@trolltech.com" 501# error "Qt has not been tested with this compiler - talk to qt-bugs@trolltech.com"
495#endif 502#endif
496 503
497#ifndef Q_PACKED 504#ifndef Q_PACKED
498# define Q_PACKED 505# define Q_PACKED
499#endif 506#endif
500 507
501 508
502/* 509/*
503 The window system, must be one of: (Q_WS_x) 510 The window system, must be one of: (Q_WS_x)
504 511
505 MACX- Mac OS X 512 MACX- Mac OS X
506 MAC9- Mac OS 9 513 MAC9- Mac OS 9
507 QWS- Qt/Embedded 514 QWS- Qt/Embedded
508 WIN32- Windows 515 WIN32- Windows
509 X11- X Window System 516 X11- X Window System
510 PM - unsupported 517 PM - unsupported
511 WIN16- unsupported 518 WIN16- unsupported
512*/ 519*/
513 520
514#if defined(Q_OS_MAC9) 521#if defined(Q_OS_MAC9)
515# define Q_WS_MAC9 522# define Q_WS_MAC9
516#elif defined(Q_OS_MSDOS) 523#elif defined(Q_OS_MSDOS)
517# define Q_WS_WIN16 524# define Q_WS_WIN16
518# error "Qt requires Win32 and does not work with Windows 3.x" 525# error "Qt requires Win32 and does not work with Windows 3.x"
519#elif defined(_WIN32_X11_) 526#elif defined(_WIN32_X11_)
520# define Q_WS_X11 527# define Q_WS_X11
521#elif defined(Q_OS_WIN32) 528#elif defined(Q_OS_WIN32)
522# define Q_WS_WIN32 529# define Q_WS_WIN32
523# if defined(Q_OS_WIN64) 530# if defined(Q_OS_WIN64)
524# define Q_WS_WIN64 531# define Q_WS_WIN64
525# endif 532# endif
526#elif defined(Q_OS_OS2) 533#elif defined(Q_OS_OS2)
527# define Q_WS_PM 534# define Q_WS_PM
528# error "Qt does not work with OS/2 Presentation Manager or Workplace Shell" 535# error "Qt does not work with OS/2 Presentation Manager or Workplace Shell"
529#elif defined(Q_OS_UNIX) 536#elif defined(Q_OS_UNIX)
530# if defined(QWS) 537# if defined(QWS)
531# define Q_WS_QWS 538# define Q_WS_QWS
532# define QT_NO_QWS_IM 539# define QT_NO_QWS_IM
533# elif defined(Q_OS_MACX) 540# elif defined(Q_OS_MACX)
534# define Q_WS_MACX 541# define Q_WS_MACX
535# else 542# else
536# define Q_WS_X11 543# define Q_WS_X11
537# endif 544# endif
538#endif 545#endif
539#if defined(Q_OS_MAC) && !defined(QMAC_PASCAL) 546#if defined(Q_OS_MAC) && !defined(QMAC_PASCAL)
540# define QMAC_PASCAL 547# define QMAC_PASCAL
541#endif 548#endif