1 # Copyright (c) 2015 Intel Corporation
3 # Licensed under the Apache License, Version 2.0 (the "License");
4 # you may not use this file except in compliance with the License.
5 # You may obtain a copy of the License at
7 # http://www.apache.org/licenses/LICENSE-2.0
9 # Unless required by applicable law or agreed to in writing, software
10 # distributed under the License is distributed on an "AS IS" BASIS,
11 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12 # See the License for the specific language governing permissions and
13 # limitations under the License.
15 # IIO sensors HAL module implementation, compiled as hw/iio-sensors-hal.so
17 LOCAL_PATH := $(call my-dir)
22 src_files := $(src_path)/entry.c \
23 $(src_path)/enumeration.c \
24 $(src_path)/control.c \
25 $(src_path)/description.c \
27 $(src_path)/transform.c \
28 $(src_path)/compass-calibration.c \
29 $(src_path)/matrix-ops.c \
30 $(src_path)/gyro-calibration.c \
31 $(src_path)/filtering.c \
32 $(src_path)/discovery.c \
33 $(src_path)/accel-calibration.c \
35 ifeq ($(HAL_AUTODETECT),true)
36 LOCAL_MODULE := iio-sensors-hal
38 LOCAL_MODULE := sensors.iio
40 LOCAL_MODULE_OWNER := intel
41 LOCAL_MODULE_RELATIVE_PATH := hw
42 LOCAL_MODULE_TAGS := optional
43 LOCAL_CFLAGS := -DLOG_TAG=\"Sensors\" -fvisibility=hidden -Wno-missing-field-initializers
44 ifeq ($(NO_IIO_EVENTS),true)
45 LOCAL_CFLAGS += -D__NO_EVENTS__
47 LOCAL_LDFLAGS := -Wl,--gc-sections
48 LOCAL_SHARED_LIBRARIES := liblog libcutils libdl
49 LOCAL_PRELINK_MODULE := false
50 LOCAL_SRC_FILES := $(src_files)
51 LOCAL_PROPRIETARY_MODULE := true
52 include $(BUILD_SHARED_LIBRARY)
56 LOCAL_CFLAGS := -DLOG_TAG=\"Sensors\" -fvisibility=hidden
57 LOCAL_SHARED_LIBRARIES := liblog libcutils libdl
58 LOCAL_SRC_FILES := sens.c
59 LOCAL_MODULE_TAGS := optional
60 LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_EXECUTABLES)
61 include $(BUILD_EXECUTABLE)
64 # Activity HAL module implementation
69 activity_src_files := $(src_path)/activity_event_entry.c \
70 $(src_path)/discovery.c \
73 LOCAL_MODULE := activity_recognition.iio
74 LOCAL_MODULE_OWNER := intel
75 LOCAL_MODULE_RELATIVE_PATH := hw
76 LOCAL_MODULE_TAGS := optional
77 LOCAL_CFLAGS := -DLOG_TAG=\"Activity\" -fvisibility=hidden
78 LOCAL_LDFLAGS := -Wl,--gc-sections
79 LOCAL_SHARED_LIBRARIES := liblog libcutils
80 LOCAL_PRELINK_MODULE := false
81 LOCAL_SRC_FILES := $(activity_src_files)
82 LOCAL_PROPRIETARY_MODULE := true
83 include $(BUILD_SHARED_LIBRARY)
86 LOCAL_MODULE := activity
87 LOCAL_CFLAGS := -DLOG_TAG=\"Activity\" -fvisibility=hidden
88 LOCAL_SHARED_LIBRARIES := liblog libcutils libdl
89 LOCAL_SRC_FILES := activity.c
90 LOCAL_MODULE_TAGS := optional
91 LOCAL_MODULE_PATH := $(TARGET_OUT_VENDOR_EXECUTABLES)
92 include $(BUILD_EXECUTABLE)