1 # 2 # Copyright 2012 The Android Open Source Project 3 # 4 # Licensed under the Apache License, Version 2.0 (the "License"); 5 # you may not use this file except in compliance with the License. 6 # You may obtain a copy of the License at 7 # 8 # http://www.apache.org/licenses/LICENSE-2.0 9 # 10 # Unless required by applicable law or agreed to in writing, software 11 # distributed under the License is distributed on an "AS IS" BASIS, 12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 # See the License for the specific language governing permissions and 14 # limitations under the License. 15 # 16 17 LOCAL_PATH := $(call my-dir) 18 19 ifeq ($(BOARD_HAVE_BLUETOOTH_QCOM),true) 20 21 include $(CLEAR_VARS) 22 23 24 LOCAL_SRC_FILES := \ 25 src/bt_vendor_qcom.c \ 26 src/hardware.c \ 27 src/hci_uart.c \ 28 src/hci_smd.c \ 29 src/hw_rome.c \ 30 src/hw_ar3k.c \ 31 src/bt_vendor_persist.cpp 32 33 ifeq ($(QCOM_BT_USE_SIBS),true) 34 LOCAL_CFLAGS += -DQCOM_BT_SIBS_ENABLE 35 endif 36 37 ifeq ($(BOARD_HAS_QCA_BT_ROME),true) 38 LOCAL_CFLAGS += -DBT_SOC_TYPE_ROME 39 endif 40 41 ifneq (,$(filter userdebug eng,$(TARGET_BUILD_VARIANT))) 42 LOCAL_CFLAGS += -DPANIC_ON_SOC_CRASH 43 endif 44 45 LOCAL_C_INCLUDES += \ 46 $(LOCAL_PATH)/include \ 47 external/bluetooth/bluedroid/hci/include \ 48 system/bt/hci/include \ 49 $(TARGET_OUT_HEADERS)/bt/hci_qcomm_init 50 51 ifeq ($(BOARD_HAS_QCA_BT_AR3002), true) 52 LOCAL_C_FLAGS := \ 53 -DBT_WAKE_VIA_PROC 54 endif #BOARD_HAS_QCA_BT_AR3002 55 56 ifeq ($(WIFI_BT_STATUS_SYNC), true) 57 LOCAL_CFLAGS += -DWIFI_BT_STATUS_SYNC 58 endif #WIFI_BT_STATUS_SYNC 59 60 LOCAL_SHARED_LIBRARIES := \ 61 libcutils \ 62 liblog \ 63 libbtnv 64 65 LOCAL_MODULE := libbt-vendor 66 LOCAL_CLANG := false 67 LOCAL_MODULE_TAGS := optional 68 LOCAL_MODULE_CLASS := SHARED_LIBRARIES 69 LOCAL_MODULE_OWNER := qcom 70 71 ifdef TARGET_2ND_ARCH 72 LOCAL_MODULE_PATH_32 := $(TARGET_OUT_VENDOR)/lib 73 LOCAL_MODULE_PATH_64 := $(TARGET_OUT_VENDOR)/lib64 74 else 75 LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_SHARED_LIBRARIES) 76 endif 77 78 LOCAL_CFLAGS += -DBT_NV_SUPPORT 79 80 ifneq ($(BOARD_ANT_WIRELESS_DEVICE),) 81 LOCAL_CFLAGS += -DENABLE_ANT 82 endif 83 #LOCAL_CFLAGS += -DREAD_BT_ADDR_FROM_PROP 84 85 #include $(LOCAL_PATH)/vnd_buildcfg.mk 86 87 include $(BUILD_SHARED_LIBRARY) 88 89 endif # BOARD_HAVE_BLUETOOTH_QCOM 90