1LOCAL_PATH := $(call my-dir)
2
3include $(CLEAR_VARS)
4LOCAL_MODULE := android.hardware.gnss@2.0-impl-qti
5LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD legacy_not_a_contribution
6LOCAL_LICENSE_CONDITIONS := by_exception_only not_allowed notice
7# activate the following line for debug purposes only, comment out for production
8#LOCAL_SANITIZE_DIAG += $(GNSS_SANITIZE_DIAG)
9LOCAL_VENDOR_MODULE := true
10LOCAL_MODULE_RELATIVE_PATH := hw
11LOCAL_SRC_FILES := \
12    AGnss.cpp \
13    Gnss.cpp \
14    AGnssRil.cpp \
15    GnssMeasurement.cpp \
16    GnssConfiguration.cpp \
17    GnssBatching.cpp \
18    GnssGeofencing.cpp \
19    GnssNi.cpp \
20    GnssDebug.cpp \
21    MeasurementCorrections.cpp \
22    GnssVisibilityControl.cpp
23
24LOCAL_SRC_FILES += \
25    location_api/GnssAPIClient.cpp \
26    location_api/MeasurementAPIClient.cpp \
27    location_api/GeofenceAPIClient.cpp \
28    location_api/BatchingAPIClient.cpp \
29    location_api/LocationUtil.cpp \
30
31ifeq ($(GNSS_HIDL_LEGACY_MEASURMENTS),true)
32LOCAL_CFLAGS += \
33     -DGNSS_HIDL_LEGACY_MEASURMENTS
34endif
35
36LOCAL_C_INCLUDES:= \
37    $(LOCAL_PATH)/location_api
38
39LOCAL_HEADER_LIBRARIES := \
40    libgps.utils_headers \
41    libloc_core_headers \
42    libloc_pla_headers \
43    liblocation_api_headers \
44    liblocbatterylistener_headers
45
46LOCAL_SHARED_LIBRARIES := \
47    liblog \
48    libhidlbase \
49    libcutils \
50    libutils \
51    android.hardware.gnss@1.0 \
52    android.hardware.gnss@1.1 \
53    android.hardware.gnss@2.0 \
54    android.hardware.gnss.measurement_corrections@1.0 \
55    android.hardware.gnss.visibility_control@1.0 \
56    android.hardware.health@1.0 \
57    android.hardware.health@2.0 \
58    android.hardware.health@2.1 \
59    android.hardware.power@1.2 \
60    libbase
61
62LOCAL_SHARED_LIBRARIES += \
63    libloc_core \
64    libgps.utils \
65    libdl \
66    liblocation_api \
67
68LOCAL_CFLAGS += $(GNSS_CFLAGS)
69LOCAL_STATIC_LIBRARIES := liblocbatterylistener
70LOCAL_STATIC_LIBRARIES += libhealthhalutils
71include $(BUILD_SHARED_LIBRARY)
72
73include $(CLEAR_VARS)
74LOCAL_MODULE := android.hardware.gnss@2.0-service-qti
75LOCAL_LICENSE_KINDS := SPDX-license-identifier-Apache-2.0 SPDX-license-identifier-BSD legacy_not_a_contribution
76LOCAL_LICENSE_CONDITIONS := by_exception_only not_allowed notice
77# activate the following line for debug purposes only, comment out for production
78#LOCAL_SANITIZE_DIAG += $(GNSS_SANITIZE_DIAG)
79LOCAL_VINTF_FRAGMENTS := android.hardware.gnss@2.0-service-qti.xml
80LOCAL_VENDOR_MODULE := true
81LOCAL_MODULE_RELATIVE_PATH := hw
82LOCAL_INIT_RC := android.hardware.gnss@2.0-service-qti.rc
83LOCAL_SRC_FILES := \
84    service.cpp \
85
86LOCAL_HEADER_LIBRARIES := \
87    libgps.utils_headers \
88    libloc_core_headers \
89    libloc_pla_headers \
90    liblocation_api_headers
91
92
93LOCAL_SHARED_LIBRARIES := \
94    liblog \
95    libcutils \
96    libdl \
97    libbase \
98    libutils \
99    libgps.utils \
100    libqti_vndfwk_detect \
101
102LOCAL_SHARED_LIBRARIES += \
103    libhidlbase \
104    android.hardware.gnss@1.0 \
105    android.hardware.gnss@1.1 \
106    android.hardware.gnss@2.0 \
107
108LOCAL_CFLAGS += $(GNSS_CFLAGS)
109
110ifneq ($(LOC_HIDL_VERSION),)
111LOCAL_CFLAGS += -DLOC_HIDL_VERSION='"$(LOC_HIDL_VERSION)"'
112endif
113
114include $(BUILD_EXECUTABLE)
115