summaryrefslogtreecommitdiff
path: root/pn54x
diff options
context:
space:
mode:
authorArian <arian.kulmer@web.de>2019-09-21 13:06:40 +0200
committerArian <arian.kulmer@web.de>2019-10-25 22:17:13 +0200
commit124e7bffe87cda4d869dd94ca114737368256df7 (patch)
tree19fefb8488559f1de2be248565391a7bcb2d7edc /pn54x
parent38202bd756d42e94ff72f1bc0c2d984e45f92065 (diff)
shinano-common: Build nfc_nci.msm8974
Change-Id: I3d5ace9ad0661e89b00741e92190a88dd04272b4
Diffstat (limited to 'pn54x')
-rw-r--r--pn54x/Android.bp0
-rw-r--r--pn54x/Android.mk95
2 files changed, 29 insertions, 66 deletions
diff --git a/pn54x/Android.bp b/pn54x/Android.bp
deleted file mode 100644
index e69de29..0000000
--- a/pn54x/Android.bp
+++ /dev/null
diff --git a/pn54x/Android.mk b/pn54x/Android.mk
index 21d4f19..dea7fc1 100644
--- a/pn54x/Android.mk
+++ b/pn54x/Android.mk
@@ -1,4 +1,6 @@
+#
# Copyright (C) 2011 The Android Open Source Project
+# 2019 The LineageOS Project
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
@@ -11,63 +13,13 @@
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.
-
-#variables for NFC_NXP_CHIP_TYPE
-PN547C2 := 1
-PN548C2 := 2
-PN551 := 3
-PN553 := 4
-NQ110 := $PN547C2
-NQ120 := $PN547C2
-NQ210 := $PN548C2
-NQ220 := $PN548C2
-#NXP PN547 Enable
-ifeq ($(PN547C2),1)
-D_CFLAGS += -DPN547C2=1
-endif
-ifeq ($(PN548C2),2)
-D_CFLAGS += -DPN548C2=2
-endif
-ifeq ($(PN551),3)
-D_CFLAGS += -DPN551=3
-endif
-ifeq ($(PN553),4)
-D_CFLAGS += -DPN553=4
-endif
-
-#### Select the CHIP ####
-ifneq ($(filter pn547 nq110 nq120,$(BOARD_NFC_CHIPSET)),)
-NXP_CHIP_TYPE := $(PN547C2)
-else ifneq ($(filter pn548 nq210 nq220,$(BOARD_NFC_CHIPSET)),)
-NXP_CHIP_TYPE := $(PN548C2)
-else ifeq ($(BOARD_NFC_CHIPSET),pn551)
-NXP_CHIP_TYPE := $(PN551)
-else ifeq ($(BOARD_NFC_CHIPSET),pn553)
-NXP_CHIP_TYPE := $(PN553)
-endif
-
-ifeq ($(NXP_CHIP_TYPE),$(PN547C2))
-D_CFLAGS += -DNFC_NXP_CHIP_TYPE=PN547C2
-else ifeq ($(NXP_CHIP_TYPE),$(PN548C2))
-D_CFLAGS += -DNFC_NXP_CHIP_TYPE=PN548C2
-else ifeq ($(NXP_CHIP_TYPE),$(PN551))
-D_CFLAGS += -DNFC_NXP_CHIP_TYPE=PN551
-else ifeq ($(NXP_CHIP_TYPE),$(PN553))
-D_CFLAGS += -DNFC_NXP_CHIP_TYPE=PN553
-else
-D_CFLAGS += -DNFC_NXP_CHIP_TYPE=PN553
-endif
-
-ifneq ($(BOARD_NFC_HAL_SUFFIX),)
- HAL_SUFFIX := $(BOARD_NFC_HAL_SUFFIX)
-else
- HAL_SUFFIX := $(TARGET_DEVICE)
-endif
+#
LOCAL_PATH := $(call my-dir)
+
include $(CLEAR_VARS)
-LOCAL_MODULE := nfc_nci.$(HAL_SUFFIX)
-LOCAL_PROPRIETARY_MODULE := true
+LOCAL_MODULE := nfc_nci.msm8974
+LOCAL_VENDOR_MODULE := true
LOCAL_MODULE_RELATIVE_PATH := hw
LOCAL_SRC_FILES := \
$(call all-c-files-under, common) \
@@ -82,24 +34,35 @@ LOCAL_SRC_FILES := \
LOCAL_SHARED_LIBRARIES := liblog libcutils libdl libhardware
-LOCAL_CFLAGS := $(D_CFLAGS)
LOCAL_C_INCLUDES += \
- $(LOCAL_PATH)/utils \
- $(LOCAL_PATH)/inc \
$(LOCAL_PATH)/common \
$(LOCAL_PATH)/dnld \
$(LOCAL_PATH)/hal \
+ $(LOCAL_PATH)/inc \
$(LOCAL_PATH)/log \
- $(LOCAL_PATH)/tml \
$(LOCAL_PATH)/self-test \
+ $(LOCAL_PATH)/tml \
+ $(LOCAL_PATH)/utils
-LOCAL_CFLAGS += -DANDROID \
- -DNXP_UICC_ENABLE -DNXP_HW_SELF_TEST
-LOCAL_CFLAGS += -DNFC_NXP_HFO_SETTINGS=FALSE
-#LOCAL_CFLAGS += -DFELICA_CLT_ENABLE
-
+LOCAL_CFLAGS := \
+ -DNFC_NXP_CHIP_TYPE=PN547C2 \
+ -DNFC_NXP_HFO_SETTINGS=FALSE \
+ -DNXP_HW_SELF_TEST
-#
-# nfc_nci.$(HAL_SUFFIX)
-#
include $(BUILD_SHARED_LIBRARY)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libnfc-nci.conf
+LOCAL_MODULE_TAGS := optional
+LOCAL_MODULE_CLASS := ETC
+LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)
+LOCAL_SRC_FILES := $(LOCAL_MODULE)
+include $(BUILD_PREBUILT)
+
+include $(CLEAR_VARS)
+LOCAL_MODULE := libnfc-nxp.conf
+LOCAL_MODULE_TAGS := optional
+LOCAL_MODULE_CLASS := ETC
+LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_ETC)
+LOCAL_SRC_FILES := $(LOCAL_MODULE)
+include $(BUILD_PREBUILT)