blob: 8592c523ee8e6b154246d9ce12e9b3b09d0e42b2 [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 := \
David Wagnerd7007822015-01-06 18:27:08 +010037 include/ParameterMgrLoggerForward.h \
Kevin Rocarda4c39f12013-05-24 17:23:09 +020038 include/ParameterMgrPlatformConnector.h \
David Wagner36f40a02015-01-06 18:33:36 +010039 include/ParameterMgrFullConnector.h \
Kevin Rocarda4c39f12013-05-24 17:23:09 +020040 include/SelectionCriterionTypeInterface.h \
41 include/SelectionCriterionInterface.h \
42 include/ParameterHandle.h
Patrick Benavoli68a91282011-08-31 11:23:23 +020043
Kevin Rocard310c4992013-06-24 18:12:18 +020044common_src_files := \
Patrick Benavoli68a91282011-08-31 11:23:23 +020045 AreaConfiguration.cpp \
David Wagnera53f6502015-01-06 18:30:49 +010046 ArrayParameter.cpp \
Patrick Benavoli68a91282011-08-31 11:23:23 +020047 AutoLog.cpp \
Patrick Benavoli1387bda2011-08-31 11:23:24 +020048 BaseParameter.cpp \
David Wagnera53f6502015-01-06 18:30:49 +010049 BinarySerializableElement.cpp \
50 BinaryStream.cpp \
51 BitParameterBlock.cpp \
52 BitParameterBlockType.cpp \
53 BitParameter.cpp \
54 BitParameterType.cpp \
55 BitwiseAreaConfiguration.cpp \
56 BooleanParameterType.cpp \
57 ComponentInstance.cpp \
58 ComponentLibrary.cpp \
59 ComponentType.cpp \
60 CompoundRule.cpp \
61 ConfigurableDomain.cpp \
62 ConfigurableDomains.cpp \
63 ConfigurableElementAggregator.cpp \
64 ConfigurableElement.cpp \
65 ConfigurationAccessContext.cpp \
66 DomainConfiguration.cpp \
67 Element.cpp \
68 ElementLibrary.cpp \
69 ElementLibrarySet.cpp \
70 ElementLocator.cpp \
Patrick Benavoli6ccab9d2011-11-10 23:21:01 +010071 EnumParameterType.cpp \
David Wagnera53f6502015-01-06 18:30:49 +010072 EnumValuePair.cpp \
73 ErrorContext.cpp \
74 FixedPointParameterType.cpp \
75 FormattedSubsystemObject.cpp \
76 FrameworkConfigurationLocation.cpp \
77 HardwareBackSynchronizer.cpp \
78 InstanceConfigurableElement.cpp \
79 InstanceDefinition.cpp \
80 IntegerParameterType.cpp \
81 LinearParameterAdaptation.cpp \
82 MappingContext.cpp \
83 MappingData.cpp \
84 ParameterAccessContext.cpp \
85 ParameterAdaptation.cpp \
86 ParameterBlackboard.cpp \
87 ParameterBlockType.cpp \
88 Parameter.cpp \
89 ParameterFrameworkConfiguration.cpp \
90 ParameterHandle.cpp \
91 ParameterMgr.cpp \
David Wagner36f40a02015-01-06 18:33:36 +010092 ParameterMgrFullConnector.cpp \
David Wagnera53f6502015-01-06 18:30:49 +010093 ParameterMgrPlatformConnector.cpp \
94 ParameterType.cpp \
95 PathNavigator.cpp \
96 PluginLocation.cpp \
97 RuleParser.cpp \
98 SelectionCriteria.cpp \
99 SelectionCriteriaDefinition.cpp \
100 SelectionCriterion.cpp \
101 SelectionCriterionLibrary.cpp \
102 SelectionCriterionRule.cpp \
103 SelectionCriterionType.cpp \
104 SimulatedBackSynchronizer.cpp \
105 StringParameter.cpp \
106 StringParameterType.cpp \
107 Subsystem.cpp \
108 SubsystemElementBuilder.cpp \
109 SubsystemObject.cpp \
110 SubsystemObjectCreator.cpp \
111 SyncerSet.cpp \
112 SystemClass.cpp \
113 TypeElement.cpp \
Patrick Benavoli6ccab9d2011-11-10 23:21:01 +0100114 VirtualSubsystem.cpp \
Patrick Benavoli065264a2011-11-20 15:46:41 +0100115 VirtualSyncer.cpp \
David Wagnera53f6502015-01-06 18:30:49 +0100116 XmlElementSerializingContext.cpp \
117 XmlFileIncluderElement.cpp \
118 XmlParameterSerializingContext.cpp
Patrick Benavoli68a91282011-08-31 11:23:23 +0200119
Kevin Rocard310c4992013-06-24 18:12:18 +0200120common_module := libparameter
121common_module_tags := optional
Patrick Benavoli68a91282011-08-31 11:23:23 +0200122
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200123common_cflags := \
124 -Wall \
125 -Werror \
126 -Wextra \
127 -Wno-unused-parameter
128
Kevin Rocard310c4992013-06-24 18:12:18 +0200129common_c_includes := \
Kevin Rocarda4c39f12013-05-24 17:23:09 +0200130 $(LOCAL_PATH)/include/ \
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200131 $(LOCAL_PATH)/../utility/ \
132 $(LOCAL_PATH)/../xmlserializer/ \
133 $(LOCAL_PATH)/../remote-processor/
Patrick Benavoli68a91282011-08-31 11:23:23 +0200134
Kevin Rocard310c4992013-06-24 18:12:18 +0200135common_shared_libraries := libicuuc
Guillaume Denneulin1080f662013-12-05 16:24:32 +0100136
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200137#############################
138# Target build
139
140include $(CLEAR_VARS)
141
Kevin Rocard310c4992013-06-24 18:12:18 +0200142LOCAL_COPY_HEADERS_TO := $(common_copy_headers_to)
143LOCAL_COPY_HEADERS := $(common_copy_headers)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200144
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200145LOCAL_CFLAGS := $(common_cflags)
146
Kevin Rocard310c4992013-06-24 18:12:18 +0200147LOCAL_SRC_FILES := $(common_src_files)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200148
Kevin Rocard310c4992013-06-24 18:12:18 +0200149LOCAL_MODULE := $(common_module)
David Wagnerc943ea62014-08-26 17:41:53 +0200150LOCAL_MODULE_OWNER := intel
Kevin Rocard310c4992013-06-24 18:12:18 +0200151LOCAL_MODULE_TAGS := $(common_module_tags)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200152
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200153LOCAL_C_INCLUDES := $(common_c_includes)
Patrick Benavoli68a91282011-08-31 11:23:23 +0200154
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200155LOCAL_SHARED_LIBRARIES := $(common_shared_libraries) libdl
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200156LOCAL_STATIC_LIBRARIES := libxmlserializer libpfw_utility libxml2
Patrick Benavoli68a91282011-08-31 11:23:23 +0200157
David Wagner0c872ff2014-10-24 16:39:06 +0200158LOCAL_CLANG := false
Mattijs Korpershoek23124b72014-06-27 09:58:03 +0200159include external/stlport/libstlport.mk
Patrick Benavoli68a91282011-08-31 11:23:23 +0200160include $(BUILD_SHARED_LIBRARY)
161
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200162##############################
163# Host build
164
165include $(CLEAR_VARS)
166
Kevin Rocard310c4992013-06-24 18:12:18 +0200167LOCAL_COPY_HEADERS_TO := $(common_copy_headers_to)
168LOCAL_COPY_HEADERS := $(common_copy_headers)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200169
Renaud de Chivred55f5862013-09-11 14:33:48 +0200170LOCAL_CFLAGS := $(common_cflags) -O0 -ggdb
Frédéric Boisnard11e31ae2013-08-06 19:23:46 +0200171
Kevin Rocard310c4992013-06-24 18:12:18 +0200172LOCAL_SRC_FILES := $(common_src_files)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200173
Kevin Rocard310c4992013-06-24 18:12:18 +0200174LOCAL_MODULE := $(common_module)_host
David Wagnerc943ea62014-08-26 17:41:53 +0200175LOCAL_MODULE_OWNER := intel
Kevin Rocard310c4992013-06-24 18:12:18 +0200176LOCAL_MODULE_TAGS := $(common_module_tags)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200177
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200178LOCAL_C_INCLUDES += \
Kevin Rocard310c4992013-06-24 18:12:18 +0200179 $(common_c_includes)
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200180
Jin Weibf76f6b2013-10-22 12:16:27 +0800181LOCAL_SHARED_LIBRARIES := $(common_shared_libraries)-host
pafonsoXcef5bbc2014-09-01 18:26:22 +0200182LOCAL_STATIC_LIBRARIES := libxmlserializer_host libpfw_utility_host libxml2
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200183
184LOCAL_LDLIBS += -ldl
185
David Wagner0c872ff2014-10-24 16:39:06 +0200186LOCAL_CLANG := false
Kevin Rocard7d7de5f2013-05-07 17:29:53 +0200187include $(BUILD_HOST_SHARED_LIBRARY)
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200188
189################################
190# Export includes for plugins (Target build)
191
192include $(CLEAR_VARS)
193
194LOCAL_MODULE := $(common_module)_includes
David Wagnerc943ea62014-08-26 17:41:53 +0200195LOCAL_MODULE_OWNER := intel
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200196
197LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
198
199LOCAL_STATIC_LIBRARIES := \
200 libxmlserializer \
201 libpfw_utility \
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200202 libxml2
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200203
204include $(BUILD_STATIC_LIBRARY)
205
206################################
207# Export includes for plugins (Host build)
208
209include $(CLEAR_VARS)
210
211LOCAL_MODULE := $(common_module)_includes_host
David Wagnerc943ea62014-08-26 17:41:53 +0200212LOCAL_MODULE_OWNER := intel
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200213
214LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
215
216LOCAL_STATIC_LIBRARIES := \
217 libxmlserializer_host \
218 libpfw_utility_host \
Mattijs Korpershoekcce85f62014-04-08 14:10:03 +0200219 libxml2
Mattijs Korpershoek93f402c2014-06-23 18:07:52 +0200220
221include $(BUILD_HOST_STATIC_LIBRARY)