Rename the source files for the WTF persistent coders.
[WebKit.git] / Source / WTF / wtf / CMakeLists.txt
1 set(WTF_HEADERS
2     ASCIICType.h
3     Assertions.h
4     Atomics.h
5     AutomaticThread.h
6     BackwardsGraph.h
7     Bag.h
8     BagToHashMap.h
9     BitVector.h
10     Bitmap.h
11     Brigand.h
12     BubbleSort.h
13     BumpPointerAllocator.h
14     ByteOrder.h
15     CPUTime.h
16     CagedPtr.h
17     ClockType.h
18     CompilationThread.h
19     Compiler.h
20     Condition.h
21     CrossThreadCopier.h
22     CrossThreadTask.h
23     CryptographicUtilities.h
24     CryptographicallyRandomNumber.h
25     CurrentTime.h
26     DataLog.h
27     DateMath.h
28     Dominators.h
29     DecimalNumber.h
30     DeferrableRefCounted.h
31     Deque.h
32     DisallowCType.h
33     DoublyLinkedList.h
34     FastMalloc.h
35     FastTLS.h
36     FeatureDefines.h
37     FilePrintStream.h
38     FlipBytes.h
39     Forward.h
40     FunctionDispatcher.h
41     GetPtr.h
42     Gigacage.h
43     GlobalVersion.h
44     GraphNodeWorklist.h
45     GregorianDateTime.h
46     HashCountedSet.h
47     Hasher.h
48     HashFunctions.h
49     HashIterators.h
50     HashMap.h
51     HashMethod.h
52     HashSet.h
53     HashTable.h
54     HashTraits.h
55     HexNumber.h
56     IndexMap.h
57     IndexSet.h
58     IndexSparseSet.h
59     IndexedContainerIterator.h
60     IteratorAdaptors.h
61     IteratorRange.h
62     ListHashSet.h
63     Liveness.h
64     Lock.h
65     LockAlgorithmInlines.h
66     LockAlgorithm.h
67     LockedPrintStream.h
68     Locker.h
69     LocklessBag.h
70     LoggingHashID.h
71     LoggingHashMap.h
72     LoggingHashSet.h
73     LoggingHashTraits.h
74     MD5.h
75     MainThread.h
76     MallocPtr.h
77     MathExtras.h
78     MediaTime.h
79     MemoryFootprint.h
80     MemoryPressureHandler.h
81     MessageQueue.h
82     MetaAllocator.h
83     MetaAllocatorHandle.h
84     NaturalLoops.h
85     MonotonicTime.h
86     Noncopyable.h
87     NumberOfCores.h
88     OSAllocator.h
89     OSRandomSource.h
90     OptionSet.h
91     OrderMaker.h
92     PageAllocation.h
93     PageBlock.h
94     PageReservation.h
95     ParallelHelperPool.h
96     ParallelJobs.h
97     ParallelJobsGeneric.h
98     ParallelJobsLibdispatch.h
99     ParallelJobsOpenMP.h
100     ParallelVectorIterator.h
101     ParkingLot.h
102     Platform.h
103     PlatformRegisters.h
104     PrintStream.h
105     ProcessID.h
106     RAMSize.h
107     RandomDevice.h
108     RandomNumber.h
109     RandomNumberSeed.h
110     Range.h
111     RangeSet.h
112     RawPointer.h
113     ReadWriteLock.h
114     RecursiveLockAdapter.h
115     RedBlackTree.h
116     Ref.h
117     RefCounted.h
118     RefCountedLeakCounter.h
119     RefCounter.h
120     RefPtr.h
121     RetainPtr.h
122     RunLoop.h
123     SHA1.h
124     SharedTask.h
125     SaturatedArithmetic.h
126     ScopedLambda.h
127     Seconds.h
128     SegmentedVector.h
129     SmallPtrSet.h
130     StackBounds.h
131     StackStats.h
132     StackTrace.h
133     StaticConstructors.h
134     StdLibExtras.h
135     Stopwatch.h
136     StringExtras.h
137     StringPrintStream.h
138     SystemFree.h
139     SystemTracing.h
140     ThreadGroup.h
141     ThreadMessage.h
142     ThreadSafeRefCounted.h
143     ThreadSpecific.h
144     Threading.h
145     ThreadingPrimitives.h
146     TimeWithDynamicClockType.h
147     TinyPtrSet.h
148     UUID.h
149     UniqueRef.h
150     VMTags.h
151     ValueCheck.h
152     Variant.h
153     Vector.h
154     VectorTraits.h
155     WallTime.h
156     WeakPtr.h
157     WordLock.h
158     WorkQueue.h
159     dtoa.h
160
161     dtoa/bignum-dtoa.h
162     dtoa/bignum.h
163     dtoa/cached-powers.h
164     dtoa/diy-fp.h
165     dtoa/double-conversion.h
166     dtoa/double.h
167     dtoa/fast-dtoa.h
168     dtoa/fixed-dtoa.h
169     dtoa/strtod.h
170     dtoa/utils.h
171
172     text/AtomicString.h
173     text/AtomicStringImpl.h
174     text/AtomicStringTable.h
175     text/Base64.h
176     text/CString.h
177     text/IntegerToStringConversion.h
178     text/LChar.h
179     text/LineBreakIteratorPoolICU.h
180     text/StringBuffer.h
181     text/StringCommon.h
182     text/StringHash.h
183     text/StringImpl.h
184     text/StringView.h
185     text/SymbolImpl.h
186     text/SymbolRegistry.h
187     text/TextBreakIterator.h
188     text/TextBreakIteratorInternalICU.h
189     text/TextStream.h
190     text/UniquedStringImpl.h
191     text/WTFString.h
192
193     text/icu/UTextProvider.h
194     text/icu/UTextProviderLatin1.h
195     text/icu/UTextProviderUTF16.h
196
197     threads/BinarySemaphore.h
198     threads/Signals.h
199
200     unicode/CharacterNames.h
201     unicode/Collator.h
202     unicode/UTF8.h
203 )
204
205 set(WTF_SOURCES
206     Assertions.cpp
207     Atomics.cpp
208     AutomaticThread.cpp
209     BitVector.cpp
210     CPUTime.cpp
211     ClockType.cpp
212     CompilationThread.cpp
213     CrossThreadCopier.cpp
214     CryptographicUtilities.cpp
215     CryptographicallyRandomNumber.cpp
216     CurrentTime.cpp
217     DataLog.cpp
218     DateMath.cpp
219     DecimalNumber.cpp
220     FastBitVector.cpp
221     FastMalloc.cpp
222     FilePrintStream.cpp
223     FunctionDispatcher.cpp
224     Gigacage.cpp
225     GlobalVersion.cpp
226     GregorianDateTime.cpp
227     HashTable.cpp
228     Lock.cpp
229     LockedPrintStream.cpp
230     MD5.cpp
231     MainThread.cpp
232     MediaTime.cpp
233     MemoryPressureHandler.cpp
234     MetaAllocator.cpp
235     MonotonicTime.cpp
236     NumberOfCores.cpp
237     OSRandomSource.cpp
238     PageBlock.cpp
239     ParallelHelperPool.cpp
240     ParallelJobsGeneric.cpp
241     ParkingLot.cpp
242     PrintStream.cpp
243     RAMSize.cpp
244     RandomDevice.cpp
245     RandomNumber.cpp
246     ReadWriteLock.cpp
247     RefCountedLeakCounter.cpp
248     RunLoop.cpp
249     SHA1.cpp
250     Seconds.cpp
251     SixCharacterHash.cpp
252     StackBounds.cpp
253     StackStats.cpp
254     StackTrace.cpp
255     StringPrintStream.cpp
256     ThreadGroup.cpp
257     ThreadMessage.cpp
258     Threading.cpp
259     TimeWithDynamicClockType.cpp
260     UUID.cpp
261     WallTime.cpp
262     WordLock.cpp
263     WorkQueue.cpp
264     dtoa.cpp
265
266     dtoa/bignum-dtoa.cc
267     dtoa/bignum.cc
268     dtoa/cached-powers.cc
269     dtoa/diy-fp.cc
270     dtoa/double-conversion.cc
271     dtoa/fast-dtoa.cc
272     dtoa/fixed-dtoa.cc
273     dtoa/strtod.cc
274
275     persistence/PersistentCoders.cpp
276     persistence/PersistentDecoder.cpp
277     persistence/PersistentEncoder.cpp
278
279     text/AtomicString.cpp
280     text/AtomicStringImpl.cpp
281     text/AtomicStringTable.cpp
282     text/Base64.cpp
283     text/CString.cpp
284     text/StringBuilder.cpp
285     text/StringImpl.cpp
286     text/StringView.cpp
287     text/SymbolImpl.cpp
288     text/SymbolRegistry.cpp
289     text/TextBreakIterator.cpp
290     text/TextStream.cpp
291     text/WTFString.cpp
292
293     text/icu/UTextProvider.cpp
294     text/icu/UTextProviderLatin1.cpp
295     text/icu/UTextProviderUTF16.cpp
296
297     threads/BinarySemaphore.cpp
298     threads/Signals.cpp
299
300     unicode/UTF8.cpp
301 )
302
303 set(WTF_INCLUDE_DIRECTORIES
304     "${BMALLOC_DIR}"
305     "${WTF_DIR}"
306     "${CMAKE_BINARY_DIR}"
307     "${DERIVED_SOURCES_DIR}"
308     "${THIRDPARTY_DIR}"
309 )
310
311 set(WTF_PRIVATE_INCLUDE_DIRECTORIES
312     "${WTF_DIR}/wtf"
313     "${WTF_DIR}/wtf/dtoa"
314     "${WTF_DIR}/wtf/persistence"
315     "${WTF_DIR}/wtf/text"
316     "${WTF_DIR}/wtf/text/icu"
317     "${WTF_DIR}/wtf/threads"
318     "${WTF_DIR}/wtf/unicode"
319 )
320
321 set(WTF_LIBRARIES
322     ${CMAKE_DL_LIBS}
323 )
324
325 if (CMAKE_SYSTEM_NAME MATCHES "Darwin")
326     list(APPEND WTF_HEADERS
327         spi/darwin/CommonCryptoSPI.h
328     )
329     list(APPEND WTF_INCLUDE_DIRECTORIES
330         "${WTF_DIR}/wtf/spi/darwin"
331     )
332 endif ()
333
334 if (NOT USE_SYSTEM_MALLOC)
335     list(APPEND WTF_LIBRARIES bmalloc)
336 endif ()
337
338 list(APPEND WTF_SOURCES
339     unicode/icu/CollatorICU.cpp
340 )
341 set(WTF_SYSTEM_INCLUDE_DIRECTORIES
342     ${ICU_INCLUDE_DIRS}
343 )
344 list(APPEND WTF_LIBRARIES
345     ${ICU_DATA_LIBRARIES}
346     ${ICU_I18N_LIBRARIES}
347     ${ICU_LIBRARIES}
348 )
349
350 if (WIN32)
351     list(APPEND WTF_SOURCES
352         OSAllocatorWin.cpp
353         ThreadSpecificWin.cpp
354         ThreadingWin.cpp
355     )
356     list(APPEND WTF_LIBRARIES
357         winmm
358     )
359 else ()
360     list(APPEND WTF_SOURCES
361         OSAllocatorPosix.cpp
362         ThreadingPthreads.cpp
363     )
364 endif ()
365
366 WEBKIT_FRAMEWORK_DECLARE(WTF)
367 WEBKIT_INCLUDE_CONFIG_FILES_IF_EXISTS()
368
369 WEBKIT_WRAP_SOURCELIST(${WTF_SOURCES})
370 WEBKIT_FRAMEWORK(WTF)
371
372 if (MSVC)
373     set(CMAKE_SHARED_LINKER_FLAGS "${CMAKE_SHARED_LINKER_FLAGS} /SUBSYSTEM:WINDOWS")
374     set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} /SUBSYSTEM:WINDOWS")
375
376     add_custom_command(
377         TARGET WTF
378         PRE_BUILD
379         COMMAND ${PERL_EXECUTABLE} ${WEBKIT_LIBRARIES_DIR}/tools/scripts/auto-version.pl ${DERIVED_SOURCES_DIR}
380         VERBATIM)
381
382     add_custom_command(
383         TARGET WTF
384         POST_BUILD
385         COMMAND ${PERL_EXECUTABLE} ${WEBKIT_LIBRARIES_DIR}/tools/scripts/version-stamp.pl ${DERIVED_SOURCES_DIR} $<TARGET_FILE:WTF>
386         VERBATIM)
387 endif ()