forked from rdkcentral/ThunderNanoServices
-
Notifications
You must be signed in to change notification settings - Fork 0
/
CMakeLists.txt
306 lines (242 loc) · 8.06 KB
/
CMakeLists.txt
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
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
# If not stated otherwise in this file or this component's LICENSE file the
# following copyright and licenses apply:
#
# Copyright 2020 RDK Management
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
cmake_minimum_required(VERSION 3.3)
find_package(WPEFramework)
# All packages that did not deliver a CMake Find script (and some deprecated scripts that need to be removed)
# are located in the cmake directory. Include it in the search.
list(APPEND CMAKE_MODULE_PATH "${CMAKE_SOURCE_DIR}/cmake/")
option(PLUGIN_BLUETOOTH "Include Bluetooth plugin" OFF)
option(PLUGIN_BLUETOOTHREMOTECONTROL "Include Bluetooth Remote Control plugin" OFF)
option(PLUGIN_COBALT "Include Cobalt plugin" OFF)
option(PLUGIN_COMMANDER "Include Commander plugin" OFF)
option(PLUGIN_COMPOSITOR "Include Compsitor plugin" OFF)
option(PLUGIN_PROCESSCONTAINERS "Include ProcessContainers plugin" OFF)
option(PLUGIN_DEVICEIDENTIFICATION "Include DeviceIdentification plugin" OFF)
option(PLUGIN_DEVICEINFO "Include DeviceInfo plugin" OFF)
option(PLUGIN_DISPLAYINFO "Include DisplayInfo plugin" OFF)
option(PLUGIN_DSRESOLUTION "Include DSResolution plugin" OFF)
option(PLUGIN_DHCPSERVER "Include DHCPServer plugin" OFF)
option(PLUGIN_DIALSERVER " Include DIALServer plugin" OFF)
option(PLUGIN_DICTIONARY "Include Dictionary plugin" OFF)
option(PLUGIN_DSGCCCLIENT "Include DSGCClient plugin" OFF)
option(PLUGIN_IOCONNECTOR "Include IOConnector plugin" OFF)
option(PLUGIN_INPUTSWITCH "Include InputSwitch plugin" OFF)
option(PLUGIN_FIRMWARECONTROL "Include FirmwareControl Plugin" OFF)
option(PLUGIN_FRONTPANEL "Include FrontPanel plugin" OFF)
option(PLUGIN_LOCATIONSYNC "Include LocationSync plugin" OFF)
option(PLUGIN_MESSENGER "Include Messenger plugin" OFF)
option(PLUGIN_MONITOR "Include Monitor plugin" OFF)
option(PLUGIN_PROCESSMONITOR "Include Process Monitor plugin" OFF)
option(PLUGIN_NETWORKCONTROL "Include NetworkControlplugin" OFF)
option(PLUGIN_OPENCDMI "Include OpenCDMi plugin" OFF)
option(PLUGIN_PACKAGER "Include Packager plugin" OFF)
option(PLUGIN_PLAYERINFO "Include PlayerInfo plugin" OFF)
option(PLUGIN_POWER "Include Power plugin" OFF)
option(PLUGIN_REMOTECONTROL "Include RemoteControl plugin" OFF)
option(PLUGIN_RESOURCEMONITOR "Include ResourceMonitor plugin" OFF)
option(PLUGIN_RTSPCLIENT "Include RtspClient plugin" OFF)
option(PLUGIN_SECURESHELLSERVER "Include SecureShellServer plugin" OFF)
option(PLUGIN_SECURITYAGENT "Include SecurityAgent plugin" OFF)
option(PLUGIN_STREAMER "Include Streamer plugin" OFF)
option(PLUGIN_SNAPSHOT "Include Snapshot plugin" OFF)
option(PLUGIN_SPARK "Include SparkEngine plugin" OFF)
option(PLUGIN_SYSTEMCOMMANDS "Include SystemCommands plugin" OFF)
option(PLUGIN_TIMESYNC "Include TimeSync plugin" OFF)
option(PLUGIN_TRACECONTROL "Include TraceControl plugin" OFF)
option(PLUGIN_VOLUMECONTROL "Include VolumeControl plugin" OFF)
option(PLUGIN_WEBKITBROWSER "Include WebKitBrowser plugin" OFF)
option(PLUGIN_WEBPA "Include WebPA plugin" OFF)
option(PLUGIN_WEBPROXY "Include WebProxy plugin" OFF)
option(PLUGIN_WEBSERVER "Include WebServer plugin" OFF)
option(PLUGIN_WEBSHELL "Include WebShell plugin" OFF)
option(PLUGIN_WIFICONTROL "Include WifiControl plugin" OFF)
option(PLUGIN_FILETRANSFER "Include FileTransfer plugin" OFF)
option(PLUGIN_DTV "Include DTV plugin" OFF)
option(WPEFRAMEWORK_CREATE_IPKG_TARGETS "Generate the CPack configuration for package generation" OFF)
# Library installation section
string(TOLOWER ${NAMESPACE} STORAGE_DIRECTORY)
#include(CompileSettings)
# for writing pc and config files
include(CmakeHelperFunctions)
if(BUILD_REFERENCE)
add_definitions(-DBUILD_REFERENCE=${BUILD_REFERENCE})
endif()
if(PLUGIN_BLUETOOTH)
add_subdirectory(BluetoothControl)
endif()
if(PLUGIN_BLUETOOTHREMOTECONTROL)
add_subdirectory(BluetoothRemoteControl)
endif()
if(PLUGIN_COBALT)
add_subdirectory(Cobalt)
endif()
if(PLUGIN_COMMANDER)
add_subdirectory(Commander)
endif()
if(PLUGIN_COMPOSITOR)
add_subdirectory(Compositor)
endif()
if (PLUGIN_PROCESSCONTAINERS)
add_subdirectory(ProcessContainers)
endif()
if(PLUGIN_DEVICEIDENTIFICATION)
add_subdirectory(DeviceIdentification)
endif()
if(PLUGIN_DEVICEINFO)
add_subdirectory(DeviceInfo)
endif()
if(PLUGIN_DISPLAYINFO)
add_subdirectory(DisplayInfo)
endif()
if(PLUGIN_DSRESOLUTION)
add_subdirectory(DSResolution)
endif()
if(PLUGIN_DHCPSERVER)
add_subdirectory(DHCPServer)
endif()
if(PLUGIN_DIALSERVER)
add_subdirectory(DIALServer)
endif()
if(PLUGIN_DICTIONARY)
add_subdirectory(Dictionary)
endif()
if(PLUGIN_DSRESOLUTION)
add_subdirectory(DSResolution)
endif()
if(PLUGIN_FIRMWARECONTROL)
add_subdirectory(FirmwareControl)
endif()
if(PLUGIN_FRONTPANEL)
add_subdirectory(FrontPanel)
endif()
if(PLUGIN_IOCONNECTOR)
add_subdirectory(IOConnector)
endif()
if(PLUGIN_INPUTSWITCH)
add_subdirectory(InputSwitch)
endif()
if(PLUGIN_SICONTROL)
add_subdirectory (SIControl)
endif(PLUGIN_SICONTROL)
if(PLUGIN_LOCATIONSYNC)
add_subdirectory(LocationSync)
endif()
if(PLUGIN_MESSENGER)
add_subdirectory(Messenger)
endif()
if(PLUGIN_MONITOR)
add_subdirectory(Monitor)
endif()
if(PLUGIN_PROCESSMONITOR)
add_subdirectory(ProcessMonitor)
endif()
if(PLUGIN_NETWORKCONTROL)
add_subdirectory(NetworkControl)
endif()
if(PLUGIN_OPENCDMI)
add_subdirectory(OpenCDMi)
endif()
if(PLUGIN_POWER)
add_subdirectory(Power)
endif()
if(PLUGIN_PACKAGER)
add_subdirectory(Packager)
endif()
if(PLUGIN_PLAYERINFO)
add_subdirectory(PlayerInfo)
endif()
if(PLUGIN_REMOTECONTROL)
add_subdirectory(RemoteControl)
endif()
if(PLUGIN_RESOURCEMONITOR)
add_subdirectory(ResourceMonitor)
endif()
if(PLUGIN_RTSPCLIENT)
add_subdirectory(RtspClient)
endif()
if(PLUGIN_SECURESHELLSERVER)
add_subdirectory(SecureShellServer)
endif()
if (PLUGIN_SECURITYAGENT)
add_subdirectory(SecurityAgent)
endif()
if(PLUGIN_SNAPSHOT)
add_subdirectory(Snapshot)
endif()
if(PLUGIN_SPARK)
add_subdirectory(Spark)
endif()
if(PLUGIN_STREAMER)
add_subdirectory(Streamer)
endif()
if(PLUGIN_SYSTEMCOMMANDS)
add_subdirectory(SystemCommands)
endif()
if(PLUGIN_SYSTEMDCONNECTOR)
add_subdirectory(SystemdConnector)
endif()
if(PLUGIN_TIMESYNC)
add_subdirectory(TimeSync)
endif()
if(PLUGIN_TRACECONTROL)
add_subdirectory(TraceControl)
endif()
if(PLUGIN_VOLUMECONTROL)
add_subdirectory(VolumeControl)
endif()
if(PLUGIN_WEBKITBROWSER)
add_subdirectory(WebKitBrowser)
endif()
if(PLUGIN_WEBPA)
add_subdirectory(WebPA)
endif()
if(PLUGIN_WEBPROXY)
add_subdirectory(WebProxy)
endif()
if(PLUGIN_WEBSERVER)
add_subdirectory(WebServer)
endif()
if(PLUGIN_WEBSHELL)
add_subdirectory(WebShell)
endif()
if(PLUGIN_WIFICONTROL)
add_subdirectory(WifiControl)
endif()
if(PLUGIN_FILETRANSFER)
add_subdirectory(FileTransfer)
endif()
if(PLUGIN_DTV)
add_subdirectory(DTV)
endif()
add_subdirectory(examples)
if(WPEFRAMEWORK_CREATE_IPKG_TARGETS)
set(CPACK_GENERATOR "DEB")
set(CPACK_DEB_COMPONENT_INSTALL ON)
set(CPACK_COMPONENTS_GROUPING IGNORE)
set(CPACK_DEBIAN_PACKAGE_NAME "${WPEFRAMEWORK_PLUGINS_OPKG_NAME}")
set(CPACK_DEBIAN_PACKAGE_VERSION "${WPEFRAMEWORK_PLUGINS_OPKG_VERSION}")
set(CPACK_DEBIAN_PACKAGE_ARCHITECTURE "${WPEFRAMEWORK_PLUGINS_OPKG_ARCHITECTURE}")
set(CPACK_DEBIAN_PACKAGE_MAINTAINER "${WPEFRAMEWORK_PLUGINS_OPKG_MAINTAINER}")
set(CPACK_DEBIAN_PACKAGE_DESCRIPTION "${WPEFRAMEWORK_PLUGINS_OPKG_DESCRIPTION}")
set(CPACK_PACKAGE_FILE_NAME "${WPEFRAMEWORK_PLUGINS_OPKG_FILE_NAME}")
# list of components from which packages will be generated
set(CPACK_COMPONENTS_ALL
${NAMESPACE}WebKitBrowser
WPEInjectedBundle
)
include(CPack)
endif()