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