[CMake] Make WTF headers copies
[WebKit-https.git] / Source / WTF / wtf / PlatformJSCOnly.cmake
1 list(APPEND WTF_SOURCES
2     generic/MainThreadGeneric.cpp
3     generic/WorkQueueGeneric.cpp
4 )
5
6 if (WIN32)
7     list(APPEND WTF_SOURCES
8         text/win/TextBreakIteratorInternalICUWin.cpp
9
10         win/CPUTimeWin.cpp
11         win/LanguageWin.cpp
12     )
13 else ()
14     list(APPEND WTF_SOURCES
15         text/unix/TextBreakIteratorInternalICUUnix.cpp
16
17         unix/CPUTimeUnix.cpp
18         unix/LanguageUnix.cpp
19         unix/UniStdExtras.cpp
20     )
21 endif ()
22
23 if (WIN32)
24     list(APPEND WTF_SOURCES
25         win/MemoryFootprintWin.cpp
26     )
27 elseif (APPLE)
28     file(COPY mac/MachExceptions.defs DESTINATION ${DERIVED_SOURCES_WTF_DIR})
29     add_custom_command(
30         OUTPUT
31             ${DERIVED_SOURCES_WTF_DIR}/MachExceptionsServer.h
32             ${DERIVED_SOURCES_WTF_DIR}/mach_exc.h
33             ${DERIVED_SOURCES_WTF_DIR}/mach_excServer.c
34             ${DERIVED_SOURCES_WTF_DIR}/mach_excUser.c
35         MAIN_DEPENDENCY mac/MachExceptions.defs
36         WORKING_DIRECTORY ${DERIVED_SOURCES_WTF_DIR}
37         COMMAND mig -sheader MachExceptionsServer.h MachExceptions.defs
38         VERBATIM)
39     list(APPEND WTF_SOURCES
40         cocoa/MemoryFootprintCocoa.cpp
41         ${DERIVED_SOURCES_WTF_DIR}/mach_excServer.c
42         ${DERIVED_SOURCES_WTF_DIR}/mach_excUser.c
43     )
44     list(APPEND WTF_INCLUDE_DIRECTORIES
45         ${DERIVED_SOURCES_WTF_DIR}
46     )
47 else ()
48     list(APPEND WTF_SOURCES
49         linux/MemoryFootprintLinux.cpp
50     )
51 endif ()
52
53 if (LOWERCASE_EVENT_LOOP_TYPE STREQUAL "glib")
54     list(APPEND WTF_SOURCES
55         glib/GRefPtr.cpp
56         glib/RunLoopGLib.cpp
57     )
58     list(APPEND WTF_SYSTEM_INCLUDE_DIRECTORIES
59         ${GLIB_INCLUDE_DIRS}
60     )
61     list(APPEND WTF_LIBRARIES
62         ${GLIB_GIO_LIBRARIES}
63         ${GLIB_GOBJECT_LIBRARIES}
64         ${GLIB_LIBRARIES}
65     )
66 else ()
67     list(APPEND WTF_SOURCES
68         generic/RunLoopGeneric.cpp
69     )
70 endif ()
71
72 list(APPEND WTF_LIBRARIES
73     ${CMAKE_THREAD_LIBS_INIT}
74 )
75
76 if (APPLE)
77     list(APPEND WTF_INCLUDE_DIRECTORIES
78         "${WTF_DIR}/icu"
79     )
80 endif ()