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