Remove home-brewed nullptr
[WebKit-https.git] / Source / WTF / wtf / CMakeLists.txt
1 set(WTF_HEADERS
2     ASCIICType.h
3     AVLTree.h
4     Assertions.h
5     Atomics.h
6     BitArray.h
7     BitVector.h
8     Bitmap.h
9     BoundsCheckedPointer.h
10     BumpPointerAllocator.h
11     ByteOrder.h
12     CompilationThread.h
13     Compiler.h
14     Compression.h
15     CryptographicallyRandomNumber.h
16     CurrentTime.h
17     DateMath.h
18     DataLog.h
19     DecimalNumber.h
20     Decoder.h
21     DeferrableRefCounted.h
22     Deque.h
23     DisallowCType.h
24     DoublyLinkedList.h
25     DynamicAnnotations.h
26     Encoder.h
27     FastMalloc.h
28     FeatureDefines.h
29     FilePrintStream.h
30     FixedArray.h
31     FlipBytes.h
32     Forward.h
33     FunctionDispatcher.h
34     Functional.h
35     GetPtr.h
36     GregorianDateTime.h
37     HashCountedSet.h
38     HashFunctions.h
39     HashIterators.h
40     HashMap.h
41     HashSet.h
42     HashTable.h
43     HashTraits.h
44     HexNumber.h
45     ListHashSet.h
46     Locker.h
47     MD5.h
48     MainThread.h
49     MallocPtr.h
50     MathExtras.h
51     MediaTime.h
52     MessageQueue.h
53     MetaAllocator.h
54     MetaAllocatorHandle.h
55     ThreadRestrictionVerifier.h
56     Ref.h
57     Noncopyable.h
58     NumberOfCores.h
59     RAMSize.h
60     OSAllocator.h
61     OSRandomSource.h
62     OwnArrayPtr.h
63     OwnPtr.h
64     OwnPtrCommon.h
65     PageAllocation.h
66     PageAllocationAligned.h
67     PageBlock.h
68     PageReservation.h
69     PassOwnPtr.h
70     PassRefPtr.h
71     PassTraits.h
72     ParallelJobs.h
73     ParallelJobsGeneric.h
74     ParallelJobsLibdispatch.h
75     ParallelJobsOpenMP.h
76     Platform.h
77     PossiblyNull.h
78     PrintStream.h
79     ProcessID.h
80     RandomNumber.h
81     RandomNumberSeed.h
82     RawPointer.h
83     RedBlackTree.h
84     RefCounted.h
85     RefCountedLeakCounter.h
86     RefPtr.h
87     RefPtrHashMap.h
88     RetainPtr.h
89     SaturatedArithmetic.h
90     SegmentedVector.h
91     SHA1.h
92     StackBounds.h
93     StaticConstructors.h
94     StdLibExtras.h
95     StringExtras.h
96     StringHasher.h
97     StringPrintStream.h
98     TCPackedCache.h
99     TCPageMap.h
100     TCSpinLock.h
101     TCSystemAlloc.h
102     ThreadIdentifierDataPthreads.h
103     ThreadSafeRefCounted.h
104     ThreadSpecific.h
105     Threading.h
106     ThreadingPrimitives.h
107     VMTags.h
108     ValueCheck.h
109     Vector.h
110     VectorTraits.h
111     WTFThreadData.h
112     WeakPtr.h
113     dtoa.h
114
115     dtoa/bignum-dtoa.h
116     dtoa/bignum.h
117     dtoa/cached-powers.h
118     dtoa/diy-fp.h
119     dtoa/double-conversion.h
120     dtoa/double.h
121     dtoa/fast-dtoa.h
122     dtoa/fixed-dtoa.h
123     dtoa/strtod.h
124     dtoa/utils.h
125
126     text/AtomicString.h
127     text/AtomicStringImpl.h
128     text/AtomicStringTable.h
129     text/Base64.h
130     text/CString.h
131     text/IntegerToStringConversion.h
132     text/StringBuffer.h
133     text/StringHash.h
134     text/StringImpl.h
135     text/WTFString.h
136
137     threads/BinarySemaphore.h
138
139     unicode/CharacterNames.h
140     unicode/Collator.h
141     unicode/UTF8.h
142     unicode/Unicode.h
143 )
144
145 set(WTF_SOURCES
146     Assertions.cpp
147     Atomics.cpp
148     BitVector.cpp
149     CompilationThread.cpp
150     Compression.cpp
151     CryptographicallyRandomNumber.cpp
152     CurrentTime.cpp
153     DateMath.cpp
154     DataLog.cpp
155     DecimalNumber.cpp
156     DynamicAnnotations.cpp
157     FastMalloc.cpp
158     FilePrintStream.cpp
159     FunctionDispatcher.cpp
160     GregorianDateTime.cpp
161     HashTable.cpp
162     MD5.cpp
163     MainThread.cpp
164     MediaTime.cpp
165     MetaAllocator.cpp
166     OSRandomSource.cpp
167     NumberOfCores.cpp
168     RAMSize.cpp
169     PageAllocationAligned.cpp
170     PageBlock.cpp
171     ParallelJobsGeneric.cpp
172     PrintStream.cpp
173     RandomNumber.cpp
174     RefCountedLeakCounter.cpp
175     SHA1.cpp
176     SixCharacterHash.cpp
177     StackBounds.cpp
178     StringPrintStream.cpp
179     TCSystemAlloc.cpp
180     Threading.cpp
181     WTFThreadData.cpp
182     dtoa.cpp
183
184     dtoa/bignum-dtoa.cc
185     dtoa/bignum.cc
186     dtoa/cached-powers.cc
187     dtoa/diy-fp.cc
188     dtoa/double-conversion.cc
189     dtoa/fast-dtoa.cc
190     dtoa/fixed-dtoa.cc
191     dtoa/strtod.cc
192
193     text/AtomicString.cpp
194     text/AtomicStringTable.cpp
195     text/Base64.cpp
196     text/CString.cpp
197     text/StringBuilder.cpp
198     text/StringImpl.cpp
199     text/StringStatics.cpp
200     text/WTFString.cpp
201
202     threads/BinarySemaphore.cpp
203
204     unicode/UTF8.cpp
205 )
206
207 set(WTF_INCLUDE_DIRECTORIES
208     "${WTF_DIR}"
209     "${WTF_DIR}/wtf"
210     "${WTF_DIR}/wtf/dtoa"
211     "${WTF_DIR}/wtf/threads"
212     "${WTF_DIR}/wtf/unicode"
213     "${THIRDPARTY_DIR}"
214     "${CMAKE_BINARY_DIR}"
215 )
216
217 set(WTF_LIBRARIES
218     ${CMAKE_DL_LIBS}
219 )
220
221 if (WTF_USE_ICU_UNICODE)
222     list(APPEND WTF_HEADERS
223         unicode/icu/UnicodeIcu.h
224     )
225     list(APPEND WTF_SOURCES
226         unicode/icu/CollatorICU.cpp
227     )
228     list(APPEND WTF_INCLUDE_DIRECTORIES
229         ${ICU_INCLUDE_DIRS}
230     )
231     list(APPEND WTF_LIBRARIES
232         ${ICU_I18N_LIBRARIES}
233         ${ICU_LIBRARIES}
234     )
235 elseif (WTF_USE_WCHAR_UNICODE)
236     list(APPEND WTF_HEADERS
237         unicode/wchar/UnicodeWchar.h
238     )
239     list(APPEND WTF_SOURCES
240         unicode/CollatorDefault.cpp
241         unicode/wchar/UnicodeWchar.cpp
242     )
243 endif ()
244
245 if (WIN32)
246     list(APPEND WTF_SOURCES
247         OSAllocatorWin.cpp
248         ThreadSpecificWin.cpp
249         ThreadingWin.cpp
250     )
251 else ()
252     list(APPEND WTF_HEADERS
253         ThreadIdentifierDataPthreads.h
254     )
255     list(APPEND WTF_SOURCES
256         OSAllocatorPosix.cpp
257         ThreadIdentifierDataPthreads.cpp
258         ThreadingPthreads.cpp
259     )
260 endif ()
261
262 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
263
264 WEBKIT_WRAP_SOURCELIST(${WTF_SOURCES})
265 include_directories(${WTF_INCLUDE_DIRECTORIES})
266 add_definitions(-DBUILDING_WTF)
267 add_library(WTF STATIC ${WTF_HEADERS} ${WTF_SOURCES})
268 target_link_libraries(WTF ${WTF_LIBRARIES})
269 set_target_properties(WTF PROPERTIES FOLDER "JavaScriptCore")
270
271 if (WTF_OUTPUT_NAME)
272     set_target_properties(WTF PROPERTIES OUTPUT_NAME ${WTF_OUTPUT_NAME})
273 endif ()