LOCAL_PATH := $(call my-dir)

include $(CLEAR_VARS)

LOCAL_MODULE_PATH := $(TARGET_OUT_SHARED_LIBRARIES)

LOCAL_SRC_FILES := \
        Socket.cpp \
        ListeningSocket.cpp \
        ConnectionSocket.cpp \
        Message.cpp \
        RequestMessage.cpp \
        AnswerMessage.cpp \
        RemoteProcessorServer.cpp \
        RemoteProcessorServerBuilder.cpp

LOCAL_MODULE := libremote-processor

LOCAL_MODULE_TAGS := optional

TARGET_ERROR_FLAGS += -Wno-non-virtual-dtor

LOCAL_C_INCLUDES +=

LOCAL_C_INCLUDES += \
        external/stlport/stlport/ \
        bionic/libstdc++ \
        bionic/

LOCAL_C_INCLUDES +=

LOCAL_SHARED_LIBRARIES := libstlport libicuuc
LOCAL_STATIC_LIBRARIES :=

LOCAL_LDLIBS +=


include $(BUILD_SHARED_LIBRARY)


LOCAL_PATH := $(call my-dir)

####################
# Common definitions

COMMON_SRC_FILES := \
        Socket.cpp \
        ListeningSocket.cpp \
        ConnectionSocket.cpp \
        Message.cpp \
        RequestMessage.cpp \
        AnswerMessage.cpp \
        RemoteProcessorServer.cpp \
        RemoteProcessorServerBuilder.cpp

COMMON_MODULE := libremote-processor
COMMON_MODULE_TAGS := optional

COMMON_ERROR_FLAGS := -Wno-non-virtual-dtor

COMMON_LDLIBS := -lpthread

#############################
# Target build

include $(CLEAR_VARS)

LOCAL_SRC_FILES := $(COMMON_SRC_FILES)

LOCAL_MODULE := $(COMMON_MODULE)
LOCAL_MODULE_TAGS := $(COMMON_MODULE_TAGS)

TARGET_ERROR_FLAGS += $(COMMON_ERROR_FLAGS)

LOCAL_C_INCLUDES += \
    external/stlport/stlport/ \
    bionic/libstdc++ \
    bionic/

LOCAL_SHARED_LIBRARIES := libstlport

LOCAL_LDLIBS += $(COMMON_LDLIBS)

include $(BUILD_SHARED_LIBRARY)

##############################
# Host build

include $(CLEAR_VARS)

LOCAL_SRC_FILES := $(COMMON_SRC_FILES)

LOCAL_MODULE := $(COMMON_MODULE)
LOCAL_MODULE_TAGS := $(COMMON_MODULE_TAGS)

TARGET_ERROR_FLAGS += $(COMMON_ERROR_FLAGS)

LOCAL_LDLIBS += $(COMMON_LDLIBS)

include $(BUILD_HOST_SHARED_LIBRARY)

Add support for host build
[remote-processor] Add support for host build

BZ: 107991

In order to generate setting xml at build time,
one need to build and run PFW environement on host.

Add an host compilation target.

Change-Id: I50b4ed0d33597db2e485c45cf2229d62b63c805e
Signed-off-by: Kevin Rocard <bd9a896220d78c7807307c046053ff427b594938@intel.com>
Reviewed-on: http://android.intel.com:8080/107269
Reviewed-by: cactus <c3ee75fbaae48de2b78e493a0872d74c3ea268c4@intel.com>
Reviewed-by: Gonzalve, Sebastien <eb080873e0961eb0e27ae23642f9b887ff089d6f@intel.com>
Tested-by: Dixon, CharlesX <decadd3ae66edc7b9ef0249fba0947d796242d6f@intel.com>
Reviewed-by: buildbot <4f01036b9437d59848e062e621b13556bac09299@intel.com>
Tested-by: buildbot <4f01036b9437d59848e062e621b13556bac09299@intel.com>
