summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSteve Kondik <shade@chemlab.org>2014-05-04 00:39:25 -0700
committerSteve Kondik <steve@cyngn.com>2015-10-16 21:31:01 -0700
commit8d8a31deace708ae06db6a58ea65ac7fcb74e43e (patch)
tree723b3b8b6ae1d33d924f127d1640817300bf0013
parentef0b8c7bbd444d1140e8606db1a8d38369f012fd (diff)
downloadandroid_hardware_qcom_bt-8d8a31deace708ae06db6a58ea65ac7fcb74e43e.tar.gz
android_hardware_qcom_bt-8d8a31deace708ae06db6a58ea65ac7fcb74e43e.tar.bz2
android_hardware_qcom_bt-8d8a31deace708ae06db6a58ea65ac7fcb74e43e.zip
libbt-qcom: Allow building without proprietary bits
Change-Id: I1a123e84064e441e7b4d3bf3437fa655f38f38c2
-rw-r--r--libbt-vendor/Android.mk6
-rw-r--r--libbt-vendor/src/bt_vendor_qcom.c2
2 files changed, 6 insertions, 2 deletions
diff --git a/libbt-vendor/Android.mk b/libbt-vendor/Android.mk
index f275ba6..696f5cc 100644
--- a/libbt-vendor/Android.mk
+++ b/libbt-vendor/Android.mk
@@ -59,8 +59,7 @@ endif #WIFI_BT_STATUS_SYNC
LOCAL_SHARED_LIBRARIES := \
libcutils \
- liblog \
- libbtnv
+ liblog
LOCAL_MODULE := libbt-vendor
LOCAL_CLANG := false
@@ -75,7 +74,10 @@ else
LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_SHARED_LIBRARIES)
endif
+ifneq ($(QCPATH),)
LOCAL_CFLAGS += -DBT_NV_SUPPORT
+LOCAL_SHARED_LIBRARIES += libbtnv
+endif
ifneq ($(BOARD_ANT_WIRELESS_DEVICE),)
LOCAL_CFLAGS += -DENABLE_ANT
diff --git a/libbt-vendor/src/bt_vendor_qcom.c b/libbt-vendor/src/bt_vendor_qcom.c
index e898112..51b59ca 100644
--- a/libbt-vendor/src/bt_vendor_qcom.c
+++ b/libbt-vendor/src/bt_vendor_qcom.c
@@ -817,12 +817,14 @@ static int op(bt_vendor_opcode_t opcode, void *param)
ignore_boot_prop = TRUE;
}
#endif //READ_BT_ADDR_FROM_PROP
+#ifdef BT_NV_SUPPORT
/* Always read BD address from NV file */
if(ignore_boot_prop && !bt_vendor_nv_read(1, vnd_local_bd_addr))
{
/* Since the BD address is configured in boot time We should not be here */
ALOGI("Failed to read BD address. Use the one from bluedroid stack/ftm");
}
+#endif
if(rome_soc_init(fd,vnd_local_bd_addr)<0) {
retval = -1;
userial_clock_operation(fd, USERIAL_OP_CLK_OFF);