1// 2// Copyright (C) 2020 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 16package { 17 default_applicable_licenses: ["Android-Apache-2.0"], 18} 19 20cc_library { 21 name: "android.hardware.sensors@2.1-Google-IIO-Subhal", 22 vendor: true, 23 srcs: [ 24 "iio_utils.cpp", 25 "MultiPoll.cpp", 26 "Sensor.cpp", 27 "SensorsSubHal.cpp", 28 "SensorThread.cpp", 29 ], 30 header_libs: [ 31 "android.hardware.sensors@2.1-multihal.header", 32 ], 33 shared_libs: [ 34 "android.hardware.sensors@1.0", 35 "android.hardware.sensors@2.0", 36 "android.hardware.sensors@2.1", 37 "android.hardware.sensors@2.0-ScopedWakelock", 38 "libcutils", 39 "libfmq", 40 "libhardware", 41 "libhidlbase", 42 "liblog", 43 "libbase", 44 "libpower", 45 "libutils", 46 ], 47 static_libs: [ 48 "android.hardware.sensors@2.X-multihal", 49 "libxml2", 50 ], 51 cflags: [ 52 "-Wall", 53 "-Wextra", 54 "-Werror", 55 ], 56 generated_sources: ["sensor_hal_configuration_V1_0"], 57 generated_headers: ["sensor_hal_configuration_V1_0"], 58} 59 60cc_test_host { 61 name: "android.hardware.sensors@2.1-Google-IIO-Subhal_test", 62 srcs: [ 63 "iio_utils.cpp", 64 "tests/IioUtilsTest.cpp", 65 ], 66 static_libs: [ 67 "libgtest", 68 "android.hardware.sensors@1.0", 69 "android.hardware.sensors@2.0", 70 "android.hardware.sensors@2.1", 71 ], 72 shared_libs: [ 73 "libbase", 74 "liblog", 75 ], 76} 77 78cc_test_host { 79 name: "android.hardware.sensors@2.1-Google-IIO-Subhal_test-MultiPoll", 80 srcs: [ 81 "MultiPoll.cpp", 82 "tests/MultiPoll.cpp" 83 ], 84 static_libs: [ 85 "libgtest", 86 "android.hardware.sensors@1.0", 87 "android.hardware.sensors@2.0", 88 "android.hardware.sensors@2.1", 89 ], 90 shared_libs: [ 91 "libbase", 92 "liblog", 93 ], 94} 95