Some tests I rebaselined on Windows are now passing on Linux.
[chromium-blink-merge.git] / webkit / config.h.in
blob45609d7df6bc108f7a08c4d69335bcbacc9a0fab
1 /*
2 * Copyright (C) 2004, 2005, 2006 Apple Inc.
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Library General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Library General Public License for more details.
14 * You should have received a copy of the GNU Library General Public License
15 * along with this library; see the file COPYING.LIB. If not, write to
16 * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
17 * Boston, MA 02110-1301, USA.
21 #if defined(HAVE_CONFIG_H) && HAVE_CONFIG_H
22 #include "autotoolsconfig.h"
23 #endif
25 #include <wtf/Platform.h>
27 #define MOBILE 0
29 #ifdef __APPLE__
30 #define HAVE_FUNC_USLEEP 1
31 #endif /* __APPLE__ */
33 #if PLATFORM(WIN_OS)
35 #ifndef _WIN32_WINNT
36 #define _WIN32_WINNT 0x0500
37 #endif
39 #ifndef WINVER
40 #define WINVER 0x0500
41 #endif
43 // If we don't define these, they get defined in windef.h.
44 // We want to use std::min and std::max.
45 #ifndef max
46 #define max max
47 #endif
48 #ifndef min
49 #define min min
50 #endif
52 // CURL needs winsock, so don't prevent inclusion of it
53 #if !USE(CURL)
54 #ifndef _WINSOCKAPI_
55 #define _WINSOCKAPI_ // Prevent inclusion of winsock.h in windows.h
56 #endif
57 #endif
59 #endif /* PLATFORM(WIN_OS) */
61 // On MSW, wx headers need to be included before windows.h is.
62 // The only way we can always ensure this is if we include wx here.
63 #if PLATFORM(WX)
64 // The defines in KeyboardCodes.h conflict with Windows as well, and the only way I've found
65 // to address the problem is include KeyboarddCodes.h before windows.h, so do it here.
66 #include "KeyboardCodes.h"
67 #include <wx/defs.h>
68 #endif
70 #if !PLATFORM(SYMBIAN)
71 #define IMPORT_C
72 #define EXPORT_C
73 #endif
75 #ifdef __cplusplus
77 // These undefs match up with defines in WebCorePrefix.h for Mac OS X.
78 // Helps us catch if anyone uses new or delete by accident in code and doesn't include "config.h".
79 #undef new
80 #undef delete
81 #include <wtf/FastMalloc.h>
83 #endif
85 // this breaks compilation of <QFontDatabase>, at least, so turn it off for now
86 // Also generates errors on wx on Windows, presumably because these functions
87 // are used from wx headers.
88 #if !PLATFORM(QT) && !PLATFORM(WX) && !PLATFORM(CHROMIUM)
89 #include <wtf/DisallowCType.h>
90 #endif
92 #if COMPILER(MSVC)
93 #define SKIP_STATIC_CONSTRUCTORS_ON_MSVC 1
94 #else
95 #define SKIP_STATIC_CONSTRUCTORS_ON_GCC 1
96 #endif
98 #if PLATFORM(WIN)
99 #define WTF_PLATFORM_CG 1
100 #undef WTF_PLATFORM_CAIRO
101 #define WTF_USE_CFNETWORK 1
102 #undef WTF_USE_WININET
103 #define WTF_PLATFORM_CF 1
104 #define WTF_USE_PTHREADS 0
105 #endif
107 #if PLATFORM(SYMBIAN)
108 #undef WIN32
109 #undef _WIN32
110 #undef SKIP_STATIC_CONSTRUCTORS_ON_GCC
111 #define USE_SYSTEM_MALLOC 1
112 #define U_HAVE_INT8_T 0
113 #define U_HAVE_INT16_T 0
114 #define U_HAVE_INT32_T 0
115 #define U_HAVE_INT64_T 0
116 #define U_HAVE_INTTYPES_H 0
118 #include <stdio.h>
119 #include <snprintf.h>
120 #include <limits.h>
121 #include <wtf/MathExtras.h>
122 #endif
124 #if PLATFORM(CHROMIUM)
126 #define WTF_USE_GOOGLEURL 1
128 #if !PLATFORM(DARWIN)
129 // Don't define SKIA on Mac. Undefine other things as well that might get set
130 // as side-effects.
131 #define WTF_PLATFORM_SKIA 1
132 #undef WTF_PLATFORM_CG
133 #undef WTF_PLATFORM_CF
134 #endif
136 #if !defined(WTF_USE_V8)
137 #define WTF_USE_V8 1
138 #endif
140 #undef WTF_USE_CFNETWORK
141 // Upstream Platform.h's #ifdef check for other graphics libraries doesn't
142 // check SKIA, so it falls back on defining CAIRO. Undo that here.
143 // TODO(evanm): clean this up.
144 #undef WTF_PLATFORM_CAIRO
145 #endif // if PLATFORM(CHROMIUM)
147 #if !defined(WTF_USE_V8)
148 #define WTF_USE_V8 0
149 #endif
151 /* Using V8 implies not using JSC and vice versa */
152 #define WTF_USE_JSC !WTF_USE_V8
154 #if PLATFORM(CG)
155 #ifndef CGFLOAT_DEFINED
156 #ifdef __LP64__
157 typedef double CGFloat;
158 #else
159 typedef float CGFloat;
160 #endif
161 #define CGFLOAT_DEFINED 1
162 #endif
163 #endif /* PLATFORM(CG) */
165 #ifdef BUILDING_ON_TIGER
166 #undef ENABLE_FTPDIR
167 #define ENABLE_FTPDIR 0
168 #endif
170 #if PLATFORM(WIN) && PLATFORM(CG)
171 #define WTF_USE_SAFARI_THEME 1
172 #endif
174 #ifndef WEBCORE_NAVIGATOR_VENDOR
175 #ifdef GOOGLE_CHROME_BUILD
176 #define WEBCORE_NAVIGATOR_VENDOR "Google Inc."
177 #else
178 #define WEBCORE_NAVIGATOR_VENDOR ""
179 #endif // ifdef GOOGLE_CHROME_BUILD
180 #endif // ifndef WEBCORE_NAVIGATOR_VENDOR