blob: 653ddd07cd2478c20a905c46cf66edba62442208 [file] [log] [blame]
David Wagnerb76c9d62014-02-05 18:30:24 +01001# Copyright (c) 2011-2014, Intel Corporation
2# All rights reserved.
Guillaume Denneulin1080f662013-12-05 16:24:32 +01003#
David Wagnerb76c9d62014-02-05 18:30:24 +01004# Redistribution and use in source and binary forms, with or without modification,
5# are permitted provided that the following conditions are met:
Guillaume Denneulin1080f662013-12-05 16:24:32 +01006#
David Wagnerb76c9d62014-02-05 18:30:24 +01007# 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.
Guillaume Denneulin1080f662013-12-05 16:24:32 +010028
Kevin Rocard6ac99e52013-05-07 17:29:53 +020029LOCAL_PATH := $(call my-dir)
Patrick Benavoli68a91282011-08-31 11:23:23 +020030
Kevin Rocard7d7de5f2013-05-07 17:29:53 +020031####################
32# Common definitions
Patrick Benavoli68a91282011-08-31 11:23:23 +020033
Kevin Rocard310c4992013-06-24 18:12:18 +020034common_copy_headers_to := parameter
Patrick Benavoli68a91282011-08-31 11:23:23 +020035
Kevin Rocard310c4992013-06-24 18:12:18 +020036common_copy_headers := \
Kevin Rocarda4c39f12013-05-24 17:23:09 +020037 include/ParameterMgrPlatformConnector.h \
38 include/SelectionCriterionTypeInterface.h \
39 include/SelectionCriterionInterface.h \
40 include/ParameterHandle.h
Patrick Benavoli68a91282011-08-31 11:23:23 +020041
Kevin Rocard310c4992013-06-24 18:12:18 +020042common_src_files := \
Patrick Benavoli68a91282011-08-31 11:23:23 +020043 Subsystem.cpp \
44 PathNavigator.cpp \
45 Element.cpp \
46 SystemClass.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020047 ParameterMgr.cpp \
48 SelectionCriteria.cpp \
49 SelectionCriterionLibrary.cpp \
50 SelectionCriteriaDefinition.cpp \
51 SelectionCriterionType.cpp \
52 ElementLibrary.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020053 SubsystemElementBuilder.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020054 SelectionCriterion.cpp \
55 ComponentLibrary.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020056 ConfigurableElement.cpp \
57 MappingData.cpp \
58 ParameterBlackboard.cpp \
59 ComponentType.cpp \
60 TypeElement.cpp \
61 InstanceConfigurableElement.cpp \
62 ComponentInstance.cpp \
63 ParameterBlockType.cpp \
64 ParameterType.cpp \
65 Parameter.cpp \
66 BooleanParameterType.cpp \
67 IntegerParameterType.cpp \
68 ArrayParameter.cpp \
69 InstanceDefinition.cpp \
70 ParameterMgrPlatformConnector.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020071 FixedPointParameterType.cpp \
72 ParameterAccessContext.cpp \
73 XmlFileIncluderElement.cpp \
74 ParameterFrameworkConfiguration.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020075 FrameworkConfigurationLocation.cpp \
Guillaume Denneulina4ec15d2012-02-17 14:38:14 +010076 PluginLocation.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020077 ElementLibrarySet.cpp \
78 ErrorContext.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020079 AreaConfiguration.cpp \
80 DomainConfiguration.cpp \
81 ConfigurableDomain.cpp \
82 SyncerSet.cpp \
83 ConfigurableDomains.cpp \
84 BinaryStream.cpp \
85 ConfigurationAccessContext.cpp \
86 XmlElementSerializingContext.cpp \
87 XmlParameterSerializingContext.cpp \
88 XmlDomainSerializingContext.cpp \
89 BinarySerializableElement.cpp \
Frédéric Boisnard9620e442012-05-30 16:15:02 +020090 BitwiseAreaConfiguration.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020091 BitParameterBlockType.cpp \
92 BitParameterBlock.cpp \
93 BitParameterType.cpp \
94 BitParameter.cpp \
95 ElementLocator.cpp \
96 ParameterMgrLogger.cpp \
97 AutoLog.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020098 CompoundRule.cpp \
99 SelectionCriterionRule.cpp \
100 ConfigurableElementAggregator.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +0200101 HardwareBackSynchronizer.cpp \
102 SimulatedBackSynchronizer.cpp \
103 MappingContext.cpp \
104 SubsystemObject.cpp \
Frederic Boisnard6cae0ec2013-05-23 18:48:58 +0200105 FormattedSubsystemObject.cpp \
Patrick Benavoli2ecf9002011-08-31 11:23:24 +0200106 SubsystemObjectCreator.cpp \
Patrick Benavoli1387bda2011-08-31 11:23:24 +0200107 BaseParameter.cpp \
Patrick Benavoli1352ae52011-10-21 16:48:04 +0200108 StringParameterType.cpp \
Patrick Benavoli9fc3c0d2011-10-27 14:27:27 +0200109 StringParameter.cpp \
Patrick Benavoli6ccab9d2011-11-10 23:21:01 +0100110 EnumParameterType.cpp \
111 VirtualSubsystem.cpp \
Patrick Benavoli065264a2011-11-20 15:46:41 +0100112 VirtualSyncer.cpp \
Patrick Benavoliee65e6d2011-11-20 18:52:24 +0100113 ParameterHandle.cpp \
114 ParameterAdaptation.cpp \
Patrick Benavoli0bd50542011-11-29 11:10:27 +0100115 LinearParameterAdaptation.cpp \
Patrick Benavoli68808c62012-02-02 17:12:41 +0100116 RuleParser.cpp \
117 EnumValuePair.cpp
Patrick Benavoli68a91282011-08-31 11:23:23 +0200118
Kevin Rocard310c4992013-06-24 18:12:18 +0200119common_module := libparameter
120common_module_tags := optional
Patrick Benavoli68a91282011-08-31 11:23:23 +0200121
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200122common_cflags := \
123 -Wall \
124 -Werror \
125 -Wextra \
126 -Wno-unused-parameter
127
Kevin Rocard310c4992013-06-24 18:12:18 +0200128common_c_includes := \
Kevin Rocarda4c39f12013-05-24 17:23:09 +0200129 $(LOCAL_PATH)/include/ \
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200130 $(LOCAL_PATH)/../utility/ \
131 $(LOCAL_PATH)/../xmlserializer/ \
132 $(LOCAL_PATH)/../remote-processor/
Patrick Benavoli68a91282011-08-31 11:23:23 +0200133
Kevin Rocard310c4992013-06-24 18:12:18 +0200134common_shared_libraries := libicuuc
Guillaume Denneulin1080f662013-12-05 16:24:32 +0100135
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200136#############################
137# Target build
138
139include $(CLEAR_VARS)
140
Kevin Rocard310c4992013-06-24 18:12:18 +0200141LOCAL_COPY_HEADERS_TO := $(common_copy_headers_to)
142LOCAL_COPY_HEADERS := $(common_copy_headers)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200143
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200144LOCAL_CFLAGS := $(common_cflags)
145
Kevin Rocard310c4992013-06-24 18:12:18 +0200146LOCAL_SRC_FILES := $(common_src_files)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200147
Kevin Rocard310c4992013-06-24 18:12:18 +0200148LOCAL_MODULE := $(common_module)
David Wagnerc943ea62014-08-26 17:41:53 +0200149LOCAL_MODULE_OWNER := intel
Kevin Rocard310c4992013-06-24 18:12:18 +0200150LOCAL_MODULE_TAGS := $(common_module_tags)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200151
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200152LOCAL_C_INCLUDES := $(common_c_includes)
Patrick Benavoli68a91282011-08-31 11:23:23 +0200153
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200154LOCAL_SHARED_LIBRARIES := $(common_shared_libraries) libdl
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200155LOCAL_STATIC_LIBRARIES := libxmlserializer libpfw_utility libxml2
Patrick Benavoli68a91282011-08-31 11:23:23 +0200156
David Wagner0c872ff2014-10-24 16:39:06 +0200157LOCAL_CLANG := false
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200158include external/stlport/libstlport.mk
Patrick Benavoli68a91282011-08-31 11:23:23 +0200159include $(BUILD_SHARED_LIBRARY)
160
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200161##############################
162# Host build
163
164include $(CLEAR_VARS)
165
Kevin Rocard310c4992013-06-24 18:12:18 +0200166LOCAL_COPY_HEADERS_TO := $(common_copy_headers_to)
167LOCAL_COPY_HEADERS := $(common_copy_headers)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200168
Renaud de Chivred55f5862013-09-11 14:33:48 +0200169LOCAL_CFLAGS := $(common_cflags) -O0 -ggdb
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200170
Kevin Rocard310c4992013-06-24 18:12:18 +0200171LOCAL_SRC_FILES := $(common_src_files)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200172
Kevin Rocard310c4992013-06-24 18:12:18 +0200173LOCAL_MODULE := $(common_module)_host
David Wagnerc943ea62014-08-26 17:41:53 +0200174LOCAL_MODULE_OWNER := intel
Kevin Rocard310c4992013-06-24 18:12:18 +0200175LOCAL_MODULE_TAGS := $(common_module_tags)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200176
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200177LOCAL_C_INCLUDES += \
Kevin Rocard310c4992013-06-24 18:12:18 +0200178 $(common_c_includes)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200179
Jin Weibf76f6b2013-10-22 12:16:27 +0800180LOCAL_SHARED_LIBRARIES := $(common_shared_libraries)-host
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200181LOCAL_STATIC_LIBRARIES := libxmlserializer_host libpfw_utility_host libxml2-schemas
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200182
183LOCAL_LDLIBS += -ldl
184
David Wagner0c872ff2014-10-24 16:39:06 +0200185LOCAL_CLANG := false
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200186include $(BUILD_HOST_SHARED_LIBRARY)
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200187
188################################
189# Export includes for plugins (Target build)
190
191include $(CLEAR_VARS)
192
193LOCAL_MODULE := $(common_module)_includes
David Wagnerc943ea62014-08-26 17:41:53 +0200194LOCAL_MODULE_OWNER := intel
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200195
196LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
197
198LOCAL_STATIC_LIBRARIES := \
199 libxmlserializer \
200 libpfw_utility \
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200201 libxml2
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200202
203include $(BUILD_STATIC_LIBRARY)
204
205################################
206# Export includes for plugins (Host build)
207
208include $(CLEAR_VARS)
209
210LOCAL_MODULE := $(common_module)_includes_host
David Wagnerc943ea62014-08-26 17:41:53 +0200211LOCAL_MODULE_OWNER := intel
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200212
213LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
214
215LOCAL_STATIC_LIBRARIES := \
216 libxmlserializer_host \
217 libpfw_utility_host \
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200218 libxml2
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200219
220include $(BUILD_HOST_STATIC_LIBRARY)