4 SET(WEBKIT_FEATURES "")
9 MACRO(WEBKIT_SEPARATE_FEATURES _name _value)
11 LIST(APPEND ${f}_FEATURES "${_name}=${_value}")
13 ENDMACRO(WEBKIT_SEPARATE_FEATURES)
15 MACRO(WEBKIT_FEATURE_CHECK_DEPS _deps _deps_ok)
18 LIST(LENGTH ${_deps} ${_deps_ok}_LIST_SIZE)
19 IF (${${_deps_ok}_LIST_SIZE} GREATER 1)
20 FOREACH(_dep ${${_deps}})
22 SET(${_deps_ok} FALSE)
28 SET(${_deps_ok} FALSE)
33 MACRO(WEBKIT_FEATURE _feature _description _type _args)
34 IF (${_type} EQUAL ${DEPENDS})
35 WEBKIT_FEATURE_CHECK_DEPS(${_args} DEPS_OK_${_feature})
36 OPTION(${_feature} "${_description}" DEPS_OK_${_feature})
37 ELSEIF (${_type} EQUAL ${DEFAULT})
38 OPTION(${_feature} "${_description}" ${_args})
41 LIST(APPEND WEBKIT_FEATURES ${_feature})
44 SET(${_feature}_VALUE 1)
45 WEBKIT_SEPARATE_FEATURES(${_feature} 1 ${ARGN})
46 LIST(APPEND FEATURE_DEFINES ${_feature})
48 SET(${_feature}_VALUE 0)
49 WEBKIT_SEPARATE_FEATURES(${_feature} 0 ${ARGN})
53 MACRO(WEBKIT_PRINT_FEATURES)
54 MESSAGE(STATUS "Enabled features:")
56 SET(MAX_FEATURE_LENGTH 0)
57 FOREACH (_feature ${WEBKIT_FEATURES})
58 STRING(LENGTH ${_feature} FEATURE_LENGTH)
59 IF (FEATURE_LENGTH GREATER MAX_FEATURE_LENGTH)
60 SET(MAX_FEATURE_LENGTH ${FEATURE_LENGTH})
65 FOREACH (_feature ${WEBKIT_FEATURES})
66 STRING(LENGTH ${_feature} FEATURE_LENGTH)
70 FOREACH (IGNORE RANGE ${FEATURE_LENGTH} ${MAX_FEATURE_LENGTH})
71 SET(SPACES "${SPACES} ")
75 FOREACH (IGNORE RANGE ${FEATURE_LENGTH} ${MAX_FEATURE_LENGTH})
76 SET(SPACES "${SPACES}.")
82 MESSAGE(STATUS " ${_feature} ${SPACES} ON")
84 MESSAGE(STATUS " ${_feature} ${SPACES} OFF")
89 UNSET(MAX_FEATURE_LENGTH)