blob: e081b5127df9222edf2a9b833ab1db88930eee0a [file] [log] [blame]
Jaewoong Jungbd2ec352019-02-04 15:25:27 -08001// Copyright (c) 2016, Intel Corporation
2// All rights reserved.
3//
4// Redistribution and use in source and binary forms, with or without modification,
5// are permitted provided that the following conditions are met:
6//
7// 1. Redistributions of source code must retain the above copyright notice, this
8// list of conditions and the following disclaimer.
9//
10// 2. Redistributions in binary form must reproduce the above copyright notice,
11// this list of conditions and the following disclaimer in the documentation and/or
12// other materials provided with the distribution.
13//
14// 3. Neither the name of the copyright holder nor the names of its contributors
15// may be used to endorse or promote products derived from this software without
16// specific prior written permission.
17//
18// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND
19// ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
20// WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
21// DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR
22// ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
23// (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
24// LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
25// ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
26// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
27// SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
28
Bob Badoura0cf6b82021-02-12 19:44:01 -080029package {
30 default_applicable_licenses: ["external_parameter-framework_license"],
31}
32
33// Added automatically by a large-scale-change that took the approach of
34// 'apply every license found to every target'. While this makes sure we respect
35// every license restriction, it may not be entirely correct.
36//
37// e.g. GPL in an MIT project might only apply to the contrib/ directory.
38//
39// Please consider splitting the single license below into multiple licenses,
40// taking care not to lose any license_kind information, and overriding the
41// default license using the 'licenses: [...]' property on targets as needed.
42//
43// For unused files, consider creating a 'fileGroup' with "//visibility:private"
44// to attach the license to, and including a comment whether the files may be
45// used in the current project.
46//
47// large-scale-change included anything that looked like it might be a license
48// text as a license_text. e.g. LICENSE, NOTICE, COPYING etc.
49//
50// Please consider removing redundant or irrelevant files from 'license_text:'.
51// See: http://go/android-license-faq
52license {
53 name: "external_parameter-framework_license",
54 visibility: [":__subpackages__"],
55 license_kinds: [
56 "SPDX-license-identifier-BSD",
57 "SPDX-license-identifier-BSL-1.0",
58 "SPDX-license-identifier-MIT",
59 ],
60 license_text: [
61 "COPYING.txt",
62 "NOTICE",
63 ],
64}
65
Dan Willemsenb802d2f2018-10-25 01:57:47 -070066cc_defaults {
67 name: "pfw_defaults",
68 host_supported: true,
Francois Gaffiea20e7082018-12-20 09:08:23 +010069 vendor_available: true,
Dan Willemsenb802d2f2018-10-25 01:57:47 -070070
71 cflags: [
72 "-frtti",
73 "-fexceptions",
74 "-Wall",
75 "-Werror",
Francois Gaffie2cc1b412018-12-20 09:05:14 +010076 "-Wextra",
Dan Willemsenb802d2f2018-10-25 01:57:47 -070077 ],
78 rtti: true,
79}
80
81cc_library_static {
82 name: "libpfw_utility",
83 defaults: ["pfw_defaults"],
84 host_supported: true,
Francois Gaffiea20e7082018-12-20 09:08:23 +010085 vendor_available: true,
Dan Willemsenb802d2f2018-10-25 01:57:47 -070086
87 export_include_dirs: ["upstream/utility"],
88
89 srcs: [
90 "upstream/utility/DynamicLibrary.cpp",
91 "upstream/utility/posix/DynamicLibrary.cpp",
92 "upstream/utility/Tokenizer.cpp",
93 "upstream/utility/Utility.cpp",
94 ],
95}
96
François Gaffie48e934f2019-10-15 10:52:37 +020097cc_library {
François Gaffie8f68e742019-04-18 07:47:00 +020098 name: "libremote-processor",
Dan Willemsenb802d2f2018-10-25 01:57:47 -070099 defaults: ["pfw_defaults"],
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700100 export_include_dirs: [
101 "upstream/remote-processor",
102 "support/android/remote-processor",
103 ],
François Gaffie8f68e742019-04-18 07:47:00 +0200104 local_include_dirs: [
105 "asio/include",
106 "support/android/asio",
107 ],
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700108 srcs: [
109 "upstream/remote-processor/RequestMessage.cpp",
110 "upstream/remote-processor/Message.cpp",
111 "upstream/remote-processor/AnswerMessage.cpp",
112 "upstream/remote-processor/RemoteProcessorServer.cpp",
113 "upstream/remote-processor/BackgroundRemoteProcessorServer.cpp",
114 ],
François Gaffie8f68e742019-04-18 07:47:00 +0200115 cflags: [
116 "-Wno-unused-local-typedef",
117 "-Wno-implicit-fallthrough"
118 ],
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700119 static_libs: ["libpfw_utility"],
120}
121
François Gaffie48e934f2019-10-15 10:52:37 +0200122cc_library {
François Gaffie8f68e742019-04-18 07:47:00 +0200123 name: "libparameter",
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700124 defaults: ["pfw_defaults"],
Francois Gaffiea20e7082018-12-20 09:08:23 +0100125 vendor_available: true,
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700126
127 cppflags: [
128 "-Wno-instantiation-after-specialization",
129 "-Wno-implicit-fallthrough",
130 ],
131 export_include_dirs: [
132 "upstream/parameter",
133 "upstream/parameter/log/include",
134 "upstream/parameter/include",
135 "upstream/xmlserializer",
136 "upstream/remote-processor",
137 "support/android/parameter",
138 ],
139 shared_libs: [
Kevin Rocarde658c532019-04-29 11:20:33 -0700140 "libxml2",
François Gaffie8f68e742019-04-18 07:47:00 +0200141 "libremote-processor",
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700142 ],
143 static_libs: [
144 "libpfw_utility",
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700145 ],
146
147 srcs: [
148 "upstream/parameter/ParameterMgrPlatformConnector.cpp",
149 "upstream/parameter/LoggingElementBuilderTemplate.cpp",
150 "upstream/parameter/StringParameterType.cpp",
151 "upstream/parameter/SyncerSet.cpp",
152 "upstream/parameter/BitParameter.cpp",
153 "upstream/parameter/BaseParameter.cpp",
154 "upstream/parameter/ParameterBlockType.cpp",
155 "upstream/parameter/FloatingPointParameterType.cpp",
156 "upstream/parameter/SelectionCriteriaDefinition.cpp",
157 "upstream/parameter/EnumValuePair.cpp",
158 "upstream/parameter/SelectionCriteria.cpp",
159 "upstream/parameter/SelectionCriterionRule.cpp",
160 "upstream/parameter/AreaConfiguration.cpp",
161 "upstream/parameter/BitParameterBlockType.cpp",
162 "upstream/parameter/ConfigurationAccessContext.cpp",
163 "upstream/parameter/BitwiseAreaConfiguration.cpp",
164 "upstream/parameter/ArrayParameter.cpp",
165 "upstream/parameter/ParameterBlackboard.cpp",
166 "upstream/parameter/InstanceConfigurableElement.cpp",
167 "upstream/parameter/LogarithmicParameterAdaptation.cpp",
168 "upstream/parameter/ConfigurableDomain.cpp",
169 "upstream/parameter/FormattedSubsystemObject.cpp",
170 "upstream/parameter/MappingData.cpp",
171 "upstream/parameter/SubsystemElementBuilder.cpp",
172 "upstream/parameter/BooleanParameterType.cpp",
173 "upstream/parameter/FixedPointParameterType.cpp",
174 "upstream/parameter/ComponentType.cpp",
175 "upstream/parameter/EnumParameterType.cpp",
176 "upstream/parameter/RuleParser.cpp",
177 "upstream/parameter/VirtualSubsystem.cpp",
178 "upstream/parameter/Element.cpp",
179 "upstream/parameter/ParameterFrameworkConfiguration.cpp",
180 "upstream/parameter/SelectionCriterionLibrary.cpp",
181 "upstream/parameter/StringParameter.cpp",
182 "upstream/parameter/CompoundRule.cpp",
183 "upstream/parameter/ConfigurableDomains.cpp",
184 "upstream/parameter/VirtualSyncer.cpp",
185 "upstream/parameter/MappingContext.cpp",
186 "upstream/parameter/LinearParameterAdaptation.cpp",
187 "upstream/parameter/ComponentLibrary.cpp",
188 "upstream/parameter/BitParameterBlock.cpp",
189 "upstream/parameter/ParameterMgrFullConnector.cpp",
190 "upstream/parameter/ConfigurableElement.cpp",
191 "upstream/parameter/ConfigurableElementAggregator.cpp",
192 "upstream/parameter/SubsystemObject.cpp",
193 "upstream/parameter/TypeElement.cpp",
194 "upstream/parameter/PathNavigator.cpp",
195 "upstream/parameter/ElementLocator.cpp",
196 "upstream/parameter/SimulatedBackSynchronizer.cpp",
197 "upstream/parameter/Parameter.cpp",
198 "upstream/parameter/ComponentInstance.cpp",
199 "upstream/parameter/InstanceDefinition.cpp",
200 "upstream/parameter/SubsystemObjectCreator.cpp",
201 "upstream/parameter/ParameterType.cpp",
202 "upstream/parameter/DomainConfiguration.cpp",
203 "upstream/parameter/PluginLocation.cpp",
204 "upstream/parameter/HardwareBackSynchronizer.cpp",
205 "upstream/parameter/SystemClass.cpp",
206 "upstream/parameter/ElementLibrary.cpp",
207 "upstream/parameter/ParameterAccessContext.cpp",
208 "upstream/parameter/XmlParameterSerializingContext.cpp",
209 "upstream/parameter/ElementHandle.cpp",
210 "upstream/parameter/ParameterMgr.cpp",
211 "upstream/parameter/SelectionCriterionType.cpp",
212 "upstream/parameter/Subsystem.cpp",
Sebastien Guiriecd5cdd5f2017-05-02 14:19:28 +0200213 "upstream/parameter/BaseIntegerParameterType.cpp",
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700214 "upstream/parameter/BitParameterType.cpp",
215 "upstream/parameter/SelectionCriterion.cpp",
216 "upstream/parameter/XmlElementSerializingContext.cpp",
217 "upstream/parameter/ElementLibrarySet.cpp",
218 "upstream/parameter/FrameworkConfigurationLocation.cpp",
219 "upstream/parameter/ParameterAdaptation.cpp",
220 "upstream/parameter/XmlFileIncluderElement.cpp",
221 "upstream/xmlserializer/XmlElement.cpp",
222 "upstream/xmlserializer/XmlSerializingContext.cpp",
223 "upstream/xmlserializer/XmlMemoryDocSource.cpp",
224 "upstream/xmlserializer/XmlDocSource.cpp",
225 "upstream/xmlserializer/XmlMemoryDocSink.cpp",
226 "upstream/xmlserializer/XmlStreamDocSink.cpp",
227 "upstream/parameter/CommandHandlerWrapper.cpp",
228 ],
229}
230
Francois Gaffie9cb33852019-02-06 08:10:16 +0100231// Userdebug only, should not be used in a user build device image.
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700232cc_binary {
233 name: "test-platform",
234 defaults: ["pfw_defaults"],
235
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700236 local_include_dirs: [
237 "upstream/test/test-platform",
Francois Gaffie9cb33852019-02-06 08:10:16 +0100238 "support/android/asio",
239 "asio/include",
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700240 ],
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700241 srcs: [
242 "upstream/test/test-platform/main.cpp",
243 "upstream/test/test-platform/TestPlatform.cpp",
244 ],
Francois Gaffie9cb33852019-02-06 08:10:16 +0100245 cflags: [
246 "-Wno-unused-local-typedef",
247 "-Wno-implicit-fallthrough"
248 ],
Dan Willemsenb802d2f2018-10-25 01:57:47 -0700249 static_libs: ["libpfw_utility"],
250 shared_libs: [
251 "libparameter",
252 "libremote-processor",
253 ],
254}
255
256cc_binary_host {
257 name: "domainGeneratorConnector",
258 defaults: ["pfw_defaults"],
259
260 owner: "intel",
261 static_libs: ["libpfw_utility"],
262 shared_libs: ["libparameter"],
263 srcs: ["upstream/tools/xmlGenerator/domainGeneratorConnector.cpp"],
264}
Jaewoong Jungbd2ec352019-02-04 15:25:27 -0800265
266// Resources are not compiled so the prebuild mechanism is used to export them.
Jaewoong Jungbd2ec352019-02-04 15:25:27 -0800267//////////////////////////////////////////////////
268
François Gaffie48e934f2019-10-15 10:52:37 +0200269filegroup {
270 name: "parameter_frameworks_configuration_schemas",
271 srcs: [
272 "upstream/schemas/ParameterFrameworkConfiguration.xsd",
273 "upstream/schemas/ConfigurableDomain.xsd",
274 "upstream/schemas/ConfigurableDomains.xsd",
275 "upstream/schemas/SystemClass.xsd",
276 "upstream/schemas/ParameterSettings.xsd",
277 "upstream/schemas/FileIncluder.xsd",
278 "upstream/schemas/Subsystem.xsd",
279 "upstream/schemas/ComponentLibrary.xsd",
280 "upstream/schemas/ComponentTypeSet.xsd",
281 "upstream/schemas/W3cXmlAttributes.xsd",
282 "upstream/schemas/Parameter.xsd",
283 ],
284 path: "upstream/",
285}
286
Jaewoong Jungbd2ec352019-02-04 15:25:27 -0800287prebuilt_etc_host {
288 name: "ParameterFrameworkConfiguration.xsd",
289 owner: "intel",
290 src: "upstream/schemas/ParameterFrameworkConfiguration.xsd",
291 sub_dir: "parameter-framework/Schemas",
292}
293
294prebuilt_etc_host {
295 name: "ConfigurableDomain.xsd",
296 owner: "intel",
297 src: "upstream/schemas/ConfigurableDomain.xsd",
298 sub_dir: "parameter-framework/Schemas",
299 required: ["ParameterSettings.xsd"],
300}
301
302prebuilt_etc_host {
303 name: "ConfigurableDomains.xsd",
304 owner: "intel",
305 src: "upstream/schemas/ConfigurableDomains.xsd",
306 sub_dir: "parameter-framework/Schemas",
307 required: ["ConfigurableDomain.xsd"],
308}
309
310prebuilt_etc_host {
311 name: "SystemClass.xsd",
312 owner: "intel",
313 src: "upstream/schemas/SystemClass.xsd",
314 sub_dir: "parameter-framework/Schemas",
315 required: [
316 "FileIncluder.xsd",
317 "Subsystem.xsd",
318 ],
319}
320
321prebuilt_etc_host {
322 name: "ParameterSettings.xsd",
323 owner: "intel",
324 src: "upstream/schemas/ParameterSettings.xsd",
325 sub_dir: "parameter-framework/Schemas",
326}
327
328prebuilt_etc_host {
329 name: "FileIncluder.xsd",
330 owner: "intel",
331 src: "upstream/schemas/FileIncluder.xsd",
332 sub_dir: "parameter-framework/Schemas",
333}
334
335prebuilt_etc_host {
336 name: "Subsystem.xsd",
337 owner: "intel",
338 src: "upstream/schemas/Subsystem.xsd",
339 sub_dir: "parameter-framework/Schemas",
340 required: ["ComponentLibrary.xsd"],
341}
342
343prebuilt_etc_host {
344 name: "ComponentLibrary.xsd",
345 owner: "intel",
346 src: "upstream/schemas/ComponentLibrary.xsd",
347 sub_dir: "parameter-framework/Schemas",
348 required: [
349 "ComponentTypeSet.xsd",
350 "W3cXmlAttributes.xsd",
351 ],
352}
353
354prebuilt_etc_host {
355 name: "ComponentTypeSet.xsd",
356 owner: "intel",
357 src: "upstream/schemas/ComponentTypeSet.xsd",
358 sub_dir: "parameter-framework/Schemas",
359 required: [
360 "Parameter.xsd",
361 "W3cXmlAttributes.xsd",
362 ],
363}
364
365prebuilt_etc_host {
366 name: "W3cXmlAttributes.xsd",
367 owner: "intel",
368 src: "upstream/schemas/W3cXmlAttributes.xsd",
369 sub_dir: "parameter-framework/Schemas",
370}
371
372prebuilt_etc_host {
373 name: "Parameter.xsd",
374 owner: "intel",
375 src: "upstream/schemas/Parameter.xsd",
376 sub_dir: "parameter-framework/Schemas",
377}
378
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100379filegroup {
380 name: "EddParser.py-srcs",
381 srcs: ["upstream/tools/xmlGenerator/EddParser.py"],
382 path: "upstream/tools/xmlGenerator/",
383}
384
385python_library_host {
386 name: "EddParser.py",
387 defaults: ["pfw_defaults"],
388 owner: "intel",
389
390 srcs: [":EddParser.py-srcs"],
391 version: {
392 py2: {
François Gaffie06f9d142019-07-30 14:27:02 +0200393 enabled: false,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100394 },
395 py3: {
François Gaffie06f9d142019-07-30 14:27:02 +0200396 enabled: true,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100397 },
398 },
399}
400
401filegroup {
402 name: "PfwBaseTranslator.py-srcs",
403 srcs: ["upstream/tools/xmlGenerator/PfwBaseTranslator.py"],
404 path: "upstream/tools/xmlGenerator/",
405}
406
407python_library_host {
408 name: "PfwBaseTranslator.py",
409 defaults: ["pfw_defaults"],
410 owner: "intel",
411
412 srcs: [":PfwBaseTranslator.py-srcs"],
413 version: {
414 py2: {
François Gaffie06f9d142019-07-30 14:27:02 +0200415 enabled: false,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100416 },
417 py3: {
François Gaffie06f9d142019-07-30 14:27:02 +0200418 enabled: true,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100419 },
420 },
421}
422
423filegroup {
424 name: "PFWScriptGenerator.py-srcs",
425 srcs: ["upstream/tools/xmlGenerator/PFWScriptGenerator.py"],
426 path: "upstream/tools/xmlGenerator/",
427}
428
429python_library_host {
430 name: "PFWScriptGenerator.py",
431 defaults: ["pfw_defaults"],
432 owner: "intel",
433
434 srcs: [":PFWScriptGenerator.py-srcs"],
435 libs: [
436 "PfwBaseTranslator.py",
437 "EddParser.py",
438 ],
439 version: {
440 py2: {
François Gaffie06f9d142019-07-30 14:27:02 +0200441 enabled: false,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100442 },
443 py3: {
François Gaffie06f9d142019-07-30 14:27:02 +0200444 enabled: true,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100445 },
446 },
447}
448
Steven Morelandd2d4d172019-09-05 10:20:34 -0700449sh_binary {
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100450 name: "updateRoutageDomains.sh",
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100451 owner: "intel",
452
453 host_supported: true,
Steven Morelandd2d4d172019-09-05 10:20:34 -0700454 src: "upstream/tools/xmlGenerator/updateRoutageDomains.sh",
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100455}
456
457filegroup {
458 name: "hostConfig.py-srcs",
459 srcs: ["upstream/tools/xmlGenerator/hostConfig.py"],
460 path: "upstream/tools/xmlGenerator/",
461}
462
463python_library_host {
464 name: "hostConfig.py",
465 defaults: ["pfw_defaults"],
466 owner: "intel",
467
468 srcs: [":hostConfig.py-srcs"],
469 version: {
470 py2: {
François Gaffie06f9d142019-07-30 14:27:02 +0200471 enabled: false,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100472 },
473 py3: {
François Gaffie06f9d142019-07-30 14:27:02 +0200474 enabled: true,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100475 },
476 },
477}
478
479python_binary_host {
480 name: "domainGenerator.py",
481 defaults: ["pfw_defaults"],
482 owner: "intel",
483
484 main: "upstream/tools/xmlGenerator/domainGenerator.py",
485 srcs: ["upstream/tools/xmlGenerator/domainGenerator.py"],
486 libs: [
487 "EddParser.py",
488 "hostConfig.py",
489 "PFWScriptGenerator.py",
490 ],
491 version: {
492 py2: {
François Gaffie06f9d142019-07-30 14:27:02 +0200493 enabled: false,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100494 },
495 py3: {
François Gaffie06f9d142019-07-30 14:27:02 +0200496 enabled: true,
Francois Gaffie2cc1b412018-12-20 09:05:14 +0100497 },
498 },
499 required: [
500 "domainGeneratorConnector",
501 ],
502}
503
504cc_prebuilt_binary {
505 name: "domainGenerator.sh",
506 defaults: ["pfw_defaults"],
507 owner: "intel",
508
509 host_supported: true,
510 srcs: ["upstream/tools/xmlGenerator/domainGenerator.sh"],
511}
512
513cc_prebuilt_binary {
514 name: "lightRoutingUpdate.sh",
515 defaults: ["pfw_defaults"],
516 owner: "intel",
517
518 host_supported: true,
519 srcs: ["upstream/tools/xmlGenerator/lightRoutingUpdate.sh"],
520}
521
Jaewoong Jungbd2ec352019-02-04 15:25:27 -0800522//////////////////////////////////////////////////
Francois Gaffie9cb33852019-02-06 08:10:16 +0100523
524cc_binary {
525 name: "remote-process",
526 defaults: ["pfw_defaults"],
527
528 srcs: ["upstream/remote-process/main.cpp"],
529 local_include_dirs: [
530 "upstream/utility",
531 "support/android/asio",
532 "asio/include",
533 ],
534 cflags: ["-Wno-unused-local-typedef"],
535 shared_libs: ["libremote-processor"],
536}