• Home
  • History
  • Annotate
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// 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
29cc_defaults {
30    name: "pfw_defaults",
31    host_supported: true,
32    vendor_available: true,
33
34    cflags: [
35        "-frtti",
36        "-fexceptions",
37        "-Wall",
38        "-Werror",
39        "-Wextra",
40    ],
41    rtti: true,
42}
43
44cc_library_static {
45    name: "libpfw_utility",
46    defaults: ["pfw_defaults"],
47    host_supported: true,
48    vendor_available: true,
49
50    export_include_dirs: ["upstream/utility"],
51
52    srcs: [
53        "upstream/utility/DynamicLibrary.cpp",
54        "upstream/utility/posix/DynamicLibrary.cpp",
55        "upstream/utility/Tokenizer.cpp",
56        "upstream/utility/Utility.cpp",
57    ],
58}
59
60cc_defaults {
61    name: "libremote-processor-defaults",
62    defaults: ["pfw_defaults"],
63
64    cflags: ["-Wno-implicit-fallthrough"],
65    export_include_dirs: [
66        "upstream/remote-processor",
67        "support/android/remote-processor",
68    ],
69
70    srcs: [
71        "upstream/remote-processor/RequestMessage.cpp",
72        "upstream/remote-processor/Message.cpp",
73        "upstream/remote-processor/AnswerMessage.cpp",
74        "upstream/remote-processor/RemoteProcessorServer.cpp",
75        "upstream/remote-processor/BackgroundRemoteProcessorServer.cpp",
76    ],
77    static_libs: ["libpfw_utility"],
78}
79
80cc_library_shared {
81    name: "libremote-processor",
82    defaults: ["libremote-processor-defaults"],
83
84    local_include_dirs: [
85        "asio/include",
86        "support/android/asio",
87    ],
88    cflags: ["-Wno-unused-local-typedef"],
89}
90
91cc_defaults {
92    name: "libparameter-defaults",
93    defaults: ["pfw_defaults"],
94    vendor_available: true,
95
96    cppflags: [
97        "-Wno-instantiation-after-specialization",
98        "-Wno-implicit-fallthrough",
99    ],
100    export_include_dirs: [
101        "upstream/parameter",
102        "upstream/parameter/log/include",
103        "upstream/parameter/include",
104        "upstream/xmlserializer",
105        "upstream/remote-processor",
106        "support/android/parameter",
107    ],
108    shared_libs: [
109        "libxml2",
110    ],
111    static_libs: [
112        "libpfw_utility",
113    ],
114
115    srcs: [
116        "upstream/parameter/ParameterMgrPlatformConnector.cpp",
117        "upstream/parameter/LoggingElementBuilderTemplate.cpp",
118        "upstream/parameter/StringParameterType.cpp",
119        "upstream/parameter/SyncerSet.cpp",
120        "upstream/parameter/BitParameter.cpp",
121        "upstream/parameter/BaseParameter.cpp",
122        "upstream/parameter/ParameterBlockType.cpp",
123        "upstream/parameter/FloatingPointParameterType.cpp",
124        "upstream/parameter/SelectionCriteriaDefinition.cpp",
125        "upstream/parameter/EnumValuePair.cpp",
126        "upstream/parameter/SelectionCriteria.cpp",
127        "upstream/parameter/SelectionCriterionRule.cpp",
128        "upstream/parameter/AreaConfiguration.cpp",
129        "upstream/parameter/BitParameterBlockType.cpp",
130        "upstream/parameter/ConfigurationAccessContext.cpp",
131        "upstream/parameter/BitwiseAreaConfiguration.cpp",
132        "upstream/parameter/ArrayParameter.cpp",
133        "upstream/parameter/ParameterBlackboard.cpp",
134        "upstream/parameter/InstanceConfigurableElement.cpp",
135        "upstream/parameter/LogarithmicParameterAdaptation.cpp",
136        "upstream/parameter/ConfigurableDomain.cpp",
137        "upstream/parameter/FormattedSubsystemObject.cpp",
138        "upstream/parameter/MappingData.cpp",
139        "upstream/parameter/SubsystemElementBuilder.cpp",
140        "upstream/parameter/BooleanParameterType.cpp",
141        "upstream/parameter/FixedPointParameterType.cpp",
142        "upstream/parameter/ComponentType.cpp",
143        "upstream/parameter/EnumParameterType.cpp",
144        "upstream/parameter/RuleParser.cpp",
145        "upstream/parameter/VirtualSubsystem.cpp",
146        "upstream/parameter/Element.cpp",
147        "upstream/parameter/ParameterFrameworkConfiguration.cpp",
148        "upstream/parameter/SelectionCriterionLibrary.cpp",
149        "upstream/parameter/StringParameter.cpp",
150        "upstream/parameter/CompoundRule.cpp",
151        "upstream/parameter/ConfigurableDomains.cpp",
152        "upstream/parameter/VirtualSyncer.cpp",
153        "upstream/parameter/MappingContext.cpp",
154        "upstream/parameter/LinearParameterAdaptation.cpp",
155        "upstream/parameter/ComponentLibrary.cpp",
156        "upstream/parameter/BitParameterBlock.cpp",
157        "upstream/parameter/ParameterMgrFullConnector.cpp",
158        "upstream/parameter/ConfigurableElement.cpp",
159        "upstream/parameter/ConfigurableElementAggregator.cpp",
160        "upstream/parameter/SubsystemObject.cpp",
161        "upstream/parameter/TypeElement.cpp",
162        "upstream/parameter/PathNavigator.cpp",
163        "upstream/parameter/ElementLocator.cpp",
164        "upstream/parameter/SimulatedBackSynchronizer.cpp",
165        "upstream/parameter/Parameter.cpp",
166        "upstream/parameter/ComponentInstance.cpp",
167        "upstream/parameter/InstanceDefinition.cpp",
168        "upstream/parameter/SubsystemObjectCreator.cpp",
169        "upstream/parameter/ParameterType.cpp",
170        "upstream/parameter/DomainConfiguration.cpp",
171        "upstream/parameter/PluginLocation.cpp",
172        "upstream/parameter/HardwareBackSynchronizer.cpp",
173        "upstream/parameter/SystemClass.cpp",
174        "upstream/parameter/ElementLibrary.cpp",
175        "upstream/parameter/ParameterAccessContext.cpp",
176        "upstream/parameter/XmlParameterSerializingContext.cpp",
177        "upstream/parameter/ElementHandle.cpp",
178        "upstream/parameter/ParameterMgr.cpp",
179        "upstream/parameter/SelectionCriterionType.cpp",
180        "upstream/parameter/Subsystem.cpp",
181        "upstream/parameter/BaseIntegerParameterType.cpp",
182        "upstream/parameter/BitParameterType.cpp",
183        "upstream/parameter/SelectionCriterion.cpp",
184        "upstream/parameter/XmlElementSerializingContext.cpp",
185        "upstream/parameter/ElementLibrarySet.cpp",
186        "upstream/parameter/FrameworkConfigurationLocation.cpp",
187        "upstream/parameter/ParameterAdaptation.cpp",
188        "upstream/parameter/XmlFileIncluderElement.cpp",
189        "upstream/xmlserializer/XmlElement.cpp",
190        "upstream/xmlserializer/XmlSerializingContext.cpp",
191        "upstream/xmlserializer/XmlMemoryDocSource.cpp",
192        "upstream/xmlserializer/XmlDocSource.cpp",
193        "upstream/xmlserializer/XmlMemoryDocSink.cpp",
194        "upstream/xmlserializer/XmlStreamDocSink.cpp",
195        "upstream/parameter/CommandHandlerWrapper.cpp",
196    ],
197}
198
199cc_library_shared {
200    name: "libparameter",
201    defaults: ["libparameter-defaults"],
202    shared_libs: [
203        "libremote-processor",
204    ],
205}
206
207// Userdebug only, should not be used in a user build device image.
208cc_binary {
209    name: "test-platform",
210    defaults: ["pfw_defaults"],
211
212    local_include_dirs: [
213        "upstream/test/test-platform",
214        "support/android/asio",
215        "asio/include",
216    ],
217    srcs: [
218        "upstream/test/test-platform/main.cpp",
219        "upstream/test/test-platform/TestPlatform.cpp",
220    ],
221    cflags: [
222        "-Wno-unused-local-typedef",
223        "-Wno-implicit-fallthrough"
224    ],
225    static_libs: ["libpfw_utility"],
226    shared_libs: [
227        "libparameter",
228        "libremote-processor",
229    ],
230}
231
232cc_binary_host {
233    name: "domainGeneratorConnector",
234    defaults: ["pfw_defaults"],
235
236    owner: "intel",
237    static_libs: ["libpfw_utility"],
238    shared_libs: ["libparameter"],
239    srcs: ["upstream/tools/xmlGenerator/domainGeneratorConnector.cpp"],
240}
241
242// Resources are not compiled so the prebuild mechanism is used to export them.
243// Schemas are only used by host, in order to validate xml files
244//////////////////////////////////////////////////
245
246prebuilt_etc_host {
247    name: "ParameterFrameworkConfiguration.xsd",
248    owner: "intel",
249    src: "upstream/schemas/ParameterFrameworkConfiguration.xsd",
250    sub_dir: "parameter-framework/Schemas",
251}
252
253prebuilt_etc_host {
254    name: "ConfigurableDomain.xsd",
255    owner: "intel",
256    src: "upstream/schemas/ConfigurableDomain.xsd",
257    sub_dir: "parameter-framework/Schemas",
258    required: ["ParameterSettings.xsd"],
259}
260
261prebuilt_etc_host {
262    name: "ConfigurableDomains.xsd",
263    owner: "intel",
264    src: "upstream/schemas/ConfigurableDomains.xsd",
265    sub_dir: "parameter-framework/Schemas",
266    required: ["ConfigurableDomain.xsd"],
267}
268
269prebuilt_etc_host {
270    name: "SystemClass.xsd",
271    owner: "intel",
272    src: "upstream/schemas/SystemClass.xsd",
273    sub_dir: "parameter-framework/Schemas",
274    required: [
275        "FileIncluder.xsd",
276        "Subsystem.xsd",
277    ],
278}
279
280prebuilt_etc_host {
281    name: "ParameterSettings.xsd",
282    owner: "intel",
283    src: "upstream/schemas/ParameterSettings.xsd",
284    sub_dir: "parameter-framework/Schemas",
285}
286
287prebuilt_etc_host {
288    name: "FileIncluder.xsd",
289    owner: "intel",
290    src: "upstream/schemas/FileIncluder.xsd",
291    sub_dir: "parameter-framework/Schemas",
292}
293
294prebuilt_etc_host {
295    name: "Subsystem.xsd",
296    owner: "intel",
297    src: "upstream/schemas/Subsystem.xsd",
298    sub_dir: "parameter-framework/Schemas",
299    required: ["ComponentLibrary.xsd"],
300}
301
302prebuilt_etc_host {
303    name: "ComponentLibrary.xsd",
304    owner: "intel",
305    src: "upstream/schemas/ComponentLibrary.xsd",
306    sub_dir: "parameter-framework/Schemas",
307    required: [
308        "ComponentTypeSet.xsd",
309        "W3cXmlAttributes.xsd",
310    ],
311}
312
313prebuilt_etc_host {
314    name: "ComponentTypeSet.xsd",
315    owner: "intel",
316    src: "upstream/schemas/ComponentTypeSet.xsd",
317    sub_dir: "parameter-framework/Schemas",
318    required: [
319        "Parameter.xsd",
320        "W3cXmlAttributes.xsd",
321    ],
322}
323
324prebuilt_etc_host {
325    name: "W3cXmlAttributes.xsd",
326    owner: "intel",
327    src: "upstream/schemas/W3cXmlAttributes.xsd",
328    sub_dir: "parameter-framework/Schemas",
329}
330
331prebuilt_etc_host {
332    name: "Parameter.xsd",
333    owner: "intel",
334    src: "upstream/schemas/Parameter.xsd",
335    sub_dir: "parameter-framework/Schemas",
336}
337
338filegroup {
339    name: "EddParser.py-srcs",
340    srcs: ["upstream/tools/xmlGenerator/EddParser.py"],
341    path: "upstream/tools/xmlGenerator/",
342}
343
344python_library_host {
345    name: "EddParser.py",
346    defaults: ["pfw_defaults"],
347    owner: "intel",
348
349    srcs: [":EddParser.py-srcs"],
350    version: {
351        py2: {
352            enabled: true,
353        },
354        py3: {
355            enabled: false,
356        },
357    },
358}
359
360filegroup {
361    name: "PfwBaseTranslator.py-srcs",
362    srcs: ["upstream/tools/xmlGenerator/PfwBaseTranslator.py"],
363    path: "upstream/tools/xmlGenerator/",
364}
365
366python_library_host {
367    name: "PfwBaseTranslator.py",
368    defaults: ["pfw_defaults"],
369    owner: "intel",
370
371    srcs: [":PfwBaseTranslator.py-srcs"],
372    version: {
373        py2: {
374            enabled: true,
375        },
376        py3: {
377            enabled: false,
378        },
379    },
380}
381
382filegroup {
383    name: "PFWScriptGenerator.py-srcs",
384    srcs: ["upstream/tools/xmlGenerator/PFWScriptGenerator.py"],
385    path: "upstream/tools/xmlGenerator/",
386}
387
388python_library_host {
389    name: "PFWScriptGenerator.py",
390    defaults: ["pfw_defaults"],
391    owner: "intel",
392
393    srcs: [":PFWScriptGenerator.py-srcs"],
394    libs: [
395        "PfwBaseTranslator.py",
396        "EddParser.py",
397    ],
398    version: {
399        py2: {
400            enabled: true,
401        },
402        py3: {
403            enabled: false,
404        },
405    },
406}
407
408cc_prebuilt_binary {
409    name: "updateRoutageDomains.sh",
410    defaults: ["pfw_defaults"],
411    owner: "intel",
412
413    host_supported: true,
414    srcs: ["upstream/tools/xmlGenerator/updateRoutageDomains.sh"],
415}
416
417filegroup {
418    name: "hostConfig.py-srcs",
419    srcs: ["upstream/tools/xmlGenerator/hostConfig.py"],
420    path: "upstream/tools/xmlGenerator/",
421}
422
423python_library_host {
424    name: "hostConfig.py",
425    defaults: ["pfw_defaults"],
426    owner: "intel",
427
428    srcs: [":hostConfig.py-srcs"],
429    version: {
430        py2: {
431            enabled: true,
432        },
433        py3: {
434            enabled: false,
435        },
436    },
437}
438
439python_binary_host {
440    name: "domainGenerator.py",
441    defaults: ["pfw_defaults"],
442    owner: "intel",
443
444    main: "upstream/tools/xmlGenerator/domainGenerator.py",
445    srcs: ["upstream/tools/xmlGenerator/domainGenerator.py"],
446    libs: [
447        "EddParser.py",
448        "hostConfig.py",
449        "PFWScriptGenerator.py",
450    ],
451    version: {
452        py2: {
453            enabled: true,
454        },
455        py3: {
456            enabled: false,
457        },
458    },
459    required: [
460        "domainGeneratorConnector",
461    ],
462}
463
464cc_prebuilt_binary {
465    name: "domainGenerator.sh",
466    defaults: ["pfw_defaults"],
467    owner: "intel",
468
469    host_supported: true,
470    srcs: ["upstream/tools/xmlGenerator/domainGenerator.sh"],
471}
472
473cc_prebuilt_binary {
474    name: "lightRoutingUpdate.sh",
475    defaults: ["pfw_defaults"],
476    owner: "intel",
477
478    host_supported: true,
479    srcs: ["upstream/tools/xmlGenerator/lightRoutingUpdate.sh"],
480}
481
482//////////////////////////////////////////////////
483
484cc_binary {
485    name: "remote-process",
486    defaults: ["pfw_defaults"],
487
488    srcs: ["upstream/remote-process/main.cpp"],
489    local_include_dirs: [
490        "upstream/utility",
491        "support/android/asio",
492        "asio/include",
493    ],
494    cflags: ["-Wno-unused-local-typedef"],
495    shared_libs: ["libremote-processor"],
496}
497