1e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# Copyright (C) 2014 The Android Open Source Project 2e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# 3e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# Licensed under the Apache License, Version 2.0 (the "License"); 4e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# you may not use this file except in compliance with the License. 5e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# You may obtain a copy of the License at 6e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# 7e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# http://www.apache.org/licenses/LICENSE-2.0 8e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# 9e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# Unless required by applicable law or agreed to in writing, software 10e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# distributed under the License is distributed on an "AS IS" BASIS, 11e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 12e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# See the License for the specific language governing permissions and 13e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# limitations under the License. 14e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 15e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiifeq (,$(TARGET_BUILD_APPS)) 16e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 17e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_PATH := $(call my-dir) 18e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 19e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi###################################### 20e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(CLEAR_VARS) 21e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 22e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_CORE_PATH := $(LOCAL_PATH)/../jni 23e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 24e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_DICT_TOOLKIT_SRC_DIR := src 25e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_CORE_SRC_DIR := ../jni/src 26e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_DICT_TOOLKIT_TEST_SRC_DIR := tests 27e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 28e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(LOCAL_PATH)/NativeFileList.mk 29e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(LATIN_IME_CORE_PATH)/NativeFileList.mk 30e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 31e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# TODO: Remove -std=c++11 once it is set by default on host build. 32e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_SRC_DIR := src 33e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_ADDRESS_SANITIZER := true 34e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CFLAGS += -std=c++11 -Wno-unused-parameter -Wno-unused-function 35e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CLANG := true 36e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CXX_STL := libc++ 37e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_C_INCLUDES += $(LOCAL_PATH)/$(LATIN_IME_DICT_TOOLKIT_SRC_DIR) \ 38e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi $(LATIN_IME_CORE_PATH)/$(LATIN_IME_CORE_SRC_DIR) 39e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_MODULE := liblatinime_dicttoolkit_host_static_for_unittests 40e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_MODULE_TAGS := optional 41e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_SRC_FILES := \ 42e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi $(addprefix $(LATIN_IME_DICT_TOOLKIT_SRC_DIR)/, $(LATIN_IME_DICT_TOOLKIT_SRC_FILES)) \ 43e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi $(addprefix $(LATIN_IME_CORE_SRC_DIR)/, $(LATIN_IME_CORE_SRC_FILES)) 44e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(BUILD_HOST_STATIC_LIBRARY) 45e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 46e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(CLEAR_VARS) 47e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 48e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi# TODO: Remove -std=c++11 once it is set by default on host build. 494bfa3b273ea9d23fa642b5b87b1113429f5f539bKeisuke KuroyanagiLOCAL_ADDRESS_SANITIZER := true 50e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CFLAGS += -std=c++11 -Wno-unused-parameter -Wno-unused-function 51e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CLANG := true 52e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_CXX_STL := libc++ 53e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_C_INCLUDES += $(LOCAL_PATH)/$(LATIN_IME_DICT_TOOLKIT_SRC_DIR) \ 54e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi $(LATIN_IME_CORE_PATH)/$(LATIN_IME_CORE_SRC_DIR) 55e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_MODULE := dicttoolkit_unittests 56e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_MODULE_TAGS := tests 57e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_SRC_FILES := \ 58e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi $(addprefix $(LATIN_DICT_TOOLKIT_TEST_SRC_DIR)/, $(LATIN_IME_DICT_TOOLKIT_TEST_FILES)) 59e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLOCAL_STATIC_LIBRARIES += liblatinime_dicttoolkit_host_static_for_unittests 60e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(BUILD_HOST_NATIVE_TEST) 61e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 62e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiinclude $(LOCAL_PATH)/CleanupNativeFileList.mk 63e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 64e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi#################### Clean up the tmp vars 65e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATINIME_HOST_OSNAME := 66e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_SRC_DIR := 67e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke KuroyanagiLATIN_IME_TEST_SRC_DIR := 68e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagi 69e101a53ffc517a9249d0442bbf435ce214374e9bKeisuke Kuroyanagiendif # TARGET_BUILD_APPS 70