23 #include "autotoolsconfig.h" |
23 #include "autotoolsconfig.h" |
24 #endif |
24 #endif |
25 |
25 |
26 #include <wtf/Platform.h> |
26 #include <wtf/Platform.h> |
27 |
27 |
28 #if PLATFORM(WIN_OS) && !defined(BUILDING_WX__) && !COMPILER(GCC) |
28 #if OS(WINDOWS) && !defined(BUILDING_WX__) && !COMPILER(GCC) |
29 #if defined(BUILDING_JavaScriptCore) || defined(BUILDING_WTF) |
29 #if defined(BUILDING_JavaScriptCore) || defined(BUILDING_WTF) |
30 #define JS_EXPORTDATA __declspec(dllexport) |
30 #define JS_EXPORTDATA __declspec(dllexport) |
31 #else |
31 #else |
32 #define JS_EXPORTDATA __declspec(dllimport) |
32 #define JS_EXPORTDATA __declspec(dllimport) |
33 #endif |
33 #endif |
|
34 #define JS_EXPORTCLASS JS_EXPORTDATA |
34 #else |
35 #else |
35 #define JS_EXPORTDATA |
36 #define JS_EXPORTDATA |
|
37 #define JS_EXPORTCLASS |
36 #endif |
38 #endif |
37 |
39 |
38 #if PLATFORM(WIN_OS) |
40 #if OS(WINDOWS) |
39 |
41 |
40 // If we don't define these, they get defined in windef.h. |
42 // If we don't define these, they get defined in windef.h. |
41 // We want to use std::min and std::max |
43 // We want to use std::min and std::max |
42 #define max max |
44 #define max max |
43 #define min min |
45 #define min min |
44 |
46 |
45 #if !COMPILER(MSVC7) && !PLATFORM(WINCE) |
47 #if !COMPILER(MSVC7_OR_LOWER) && !OS(WINCE) |
46 // We need to define this before the first #include of stdlib.h or it won't contain rand_s. |
48 // We need to define this before the first #include of stdlib.h or it won't contain rand_s. |
47 #ifndef _CRT_RAND_S |
49 #ifndef _CRT_RAND_S |
48 #define _CRT_RAND_S |
50 #define _CRT_RAND_S |
49 #endif |
51 #endif |
50 #endif |
52 #endif |
51 |
53 |
52 #endif |
54 #endif |
53 |
55 |
54 #if PLATFORM(FREEBSD) || PLATFORM(OPENBSD) |
56 #if OS(FREEBSD) || OS(OPENBSD) |
55 #define HAVE_PTHREAD_NP_H 1 |
57 #define HAVE_PTHREAD_NP_H 1 |
56 #endif |
58 #endif |
57 |
59 |
58 /* FIXME: if all platforms have these, do they really need #defines? */ |
60 /* FIXME: if all platforms have these, do they really need #defines? */ |
59 #define HAVE_STDINT_H 1 |
61 #define HAVE_STDINT_H 1 |
60 #define HAVE_STRING_H 1 |
|
61 |
62 |
62 #define WTF_CHANGES 1 |
63 #define WTF_CHANGES 1 |
63 |
64 |
64 #ifdef __cplusplus |
65 #ifdef __cplusplus |
65 #undef new |
66 #undef new |
72 // are used from wx headers. |
73 // are used from wx headers. |
73 #if !PLATFORM(QT) && !PLATFORM(WX) |
74 #if !PLATFORM(QT) && !PLATFORM(WX) |
74 #include <wtf/DisallowCType.h> |
75 #include <wtf/DisallowCType.h> |
75 #endif |
76 #endif |
76 |
77 |
|
78 #if PLATFORM(CHROMIUM) |
|
79 #if !defined(WTF_USE_V8) |
|
80 #define WTF_USE_V8 1 |
|
81 #endif |
|
82 #endif /* PLATFORM(CHROMIUM) */ |
|
83 |
|
84 #if !defined(WTF_USE_V8) |
|
85 #define WTF_USE_V8 0 |
|
86 #endif /* !defined(WTF_USE_V8) */ |
|
87 |
|
88 /* Using V8 implies not using JSC and vice versa */ |
|
89 #define WTF_USE_JSC !WTF_USE_V8 |