2010-05-15 Leandro Pereira <leandro@profusion.mobi>
[WebKit-https.git] / cmake / OptionsCommon.cmake
1 ADD_DEFINITIONS(-DBUILDING_WITH_CMAKE=1)
2
3 SET(WTF_INCLUDE_DIRECTORIES
4     "${JAVASCRIPTCORE_DIR}"
5     "${JAVASCRIPTCORE_DIR}/wtf"
6     "${JAVASCRIPTCORE_DIR}/wtf/unicode"
7     "${DERIVED_SOURCES_DIR}"
8 )
9
10 SET(WEBKIT_LIBRARY_TYPE STATIC)
11
12 IF (ICU_FOUND)
13     SET(WTF_USE_ICU_UNICODE 1)
14     ADD_DEFINITIONS(-DWTF_USE_ICU_UNICODE=1)
15     LIST(APPEND WTF_INCLUDE_DIRECTORIES ${ICU_INCLUDE_DIRS})
16 ENDIF ()
17
18 IF (CMAKE_HAVE_PTHREAD_H AND NOT WTF_PLATFORM_QT)
19     SET(WTF_USE_PTHREADS 1)
20     ADD_DEFINITIONS(-DWTF_USE_PTHREADS=1)
21 ELSE ()
22     ADD_DEFINITIONS(-DENABLE_JSC_MULTIPLE_THREADS=0)
23 ENDIF ()
24
25 IF (WTF_OS_UNIX)
26     ADD_DEFINITIONS(-DXP_UNIX)
27 ENDIF (WTF_OS_UNIX)
28
29 ADD_DEFINITIONS(-DHAVE_CONFIG_H=1)
30
31 FILE(MAKE_DIRECTORY ${DERIVED_SOURCES_DIR})