summaryrefslogtreecommitdiffstats
path: root/src/uscxml/CMakeLists.txt
blob: e98aed6a1d1ff57b287be1339ddb7d48118f95e4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
############################################################
# Actual files of core library
############################################################

file(GLOB_RECURSE USCXML_SERVER
	server/*.cpp
	server/*.h
)
source_group("Interpreter" FILES ${USCXML_SERVER})
list (APPEND USCXML_FILES ${USCXML_SERVER})

file(GLOB_RECURSE USCXML_UTIL
  util/*.cpp
  util/*.hpp
  util/*.c
	util/*.h
)
source_group("Interpreter" FILES ${USCXML_UTIL})
list (APPEND USCXML_FILES ${USCXML_UTIL})

file(GLOB_RECURSE USCXML_DOM
  dom/*.cpp
  dom/*.hpp
  dom/*.c
	dom/*.h
)
source_group("Interpreter" FILES ${USCXML_DOM})
list (APPEND USCXML_FILES ${USCXML_DOM})

file(GLOB_RECURSE USCXML_CONCURRENCY
	concurrency/*.cpp
	concurrency/*.h
)
source_group("Interpreter" FILES ${USCXML_CONCURRENCY})
list (APPEND USCXML_FILES ${USCXML_CONCURRENCY})

file(GLOB_RECURSE USCXML_MESSAGES
	messages/*.cpp
	messages/*.h
)
source_group("Interpreter" FILES ${USCXML_MESSAGES})
list (APPEND USCXML_FILES ${USCXML_MESSAGES})

if (NOT BUILD_MINIMAL)
	file(GLOB_RECURSE USCXML_DEBUG
		debug/*.cpp
		debug/*.h
	)
	source_group("Interpreter" FILES ${USCXML_DEBUG})
	list (APPEND USCXML_FILES ${USCXML_DEBUG})

	file(GLOB_RECURSE USCXML_TRANSFORM
		transform/*.cpp
		transform/*.h
	)
	source_group("Interpreter" FILES ${USCXML_TRANSFORM})
	list (APPEND USCXML_TRANSFORM_FILES ${USCXML_TRANSFORM})
endif()

file(GLOB_RECURSE USCXML_INTERPRETERS
	interpreter/*.cpp
	interpreter/*.h
)
source_group("Interpreter" FILES ${USCXML_INTERPRETERS})
list (APPEND USCXML_FILES ${USCXML_INTERPRETERS})

if(APPLE OR IOS)
	file(GLOB USCXML_APPLE
		*.mm
	)
	source_group("Interpreter" FILES ${USCXML_APPLE})
	list (APPEND USCXML_FILES ${USCXML_APPLE})
endif()

file(GLOB USCXML_CORE
  ${CMAKE_SOURCE_DIR}/contrib/src/jsmn/jsmn.c
  ${CMAKE_SOURCE_DIR}/contrib/src/evws/evws.c
	*.cpp
	*.h
)

source_group("Interpreter" FILES ${USCXML_CORE})
list (APPEND USCXML_FILES ${USCXML_CORE})

file(GLOB USCXML_PLUGINS
	plugins/DataModel.h
	plugins/EventHandler.h
	plugins/ExecutableContent.h
	plugins/Invoker.h
	plugins/IOProcessor.h
)
source_group("Interpreter" FILES ${USCXML_PLUGINS})
list (APPEND USCXML_FILES ${USCXML_PLUGINS})

if (BUILD_AS_PLUGINS)
	list (APPEND USCXML_INCLUDE_DIRS ${PROJECT_SOURCE_DIR}/plugins)
	file(GLOB PLUMA
		plugins/Pluma/*.cpp
		plugins/Pluma/*.h
		plugins/*.cpp 
		plugins/*.h
	)
	source_group("Interpreter" FILES ${PLUMA})
	list (APPEND USCXML_FILES ${PLUMA})
	add_definitions("-DBUILD_AS_PLUGINS")
endif()

add_subdirectory(plugins/datamodel)
add_subdirectory(plugins/element)
add_subdirectory(plugins/ioprocessor)
add_subdirectory(plugins/invoker)

SET(USCXML_INVOKERS ${USCXML_INVOKERS} PARENT_SCOPE)
SET(USCXML_IOPROCESSORS ${USCXML_IOPROCESSORS} PARENT_SCOPE)
SET(USCXML_ELEMENTS ${USCXML_ELEMENTS} PARENT_SCOPE)
SET(USCXML_DATAMODELS ${USCXML_DATAMODELS} PARENT_SCOPE)
SET(USCXML_LANGUAGE_BINDINGS ${USCXML_LANGUAGE_BINDINGS} PARENT_SCOPE)

set(USCXML_INCLUDE_DIRS ${USCXML_INCLUDE_DIRS} PARENT_SCOPE)
set(USCXML_OPT_LIBS ${USCXML_OPT_LIBS} PARENT_SCOPE)
set(USCXML_FILES ${USCXML_FILES} PARENT_SCOPE)
set(USCXML_TRANSFORM_FILES ${USCXML_TRANSFORM_FILES} PARENT_SCOPE)
SET(PLUMA ${PLUMA} PARENT_SCOPE)