1 # Copyright (C) 2016 The Android Open Source Project
2 #
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
6 #
7 # http://www.apache.org/licenses/LICENSE-2.0
8 #
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.
14 LOCAL_PATH := $(call my-dir)
16 ###
17 ### android.hardware.wifi static library
18 ###
19 include $(CLEAR_VARS)
20 LOCAL_MODULE := android.hardware.wifi@1.0-service-lib
21 LOCAL_MODULE_RELATIVE_PATH := hw
22 LOCAL_PROPRIETARY_MODULE := true
23 LOCAL_CPPFLAGS := -Wall -Werror -Wextra
24 ifdef WIFI_HIDL_FEATURE_AWARE
25 LOCAL_CPPFLAGS += -DWIFI_HIDL_FEATURE_AWARE
26 endif
27 ifdef WIFI_HIDL_FEATURE_DUAL_INTERFACE
28 LOCAL_CPPFLAGS += -DWIFI_HIDL_FEATURE_DUAL_INTERFACE
29 endif
30 LOCAL_SRC_FILES := \
31 hidl_struct_util.cpp \
32 hidl_sync_util.cpp \
33 ringbuffer.cpp \
34 wifi.cpp \
35 wifi_ap_iface.cpp \
36 wifi_chip.cpp \
37 wifi_feature_flags.cpp \
38 wifi_legacy_hal.cpp \
39 wifi_legacy_hal_stubs.cpp \
40 wifi_mode_controller.cpp \
41 wifi_nan_iface.cpp \
42 wifi_p2p_iface.cpp \
43 wifi_rtt_controller.cpp \
44 wifi_sta_iface.cpp \
45 wifi_status_util.cpp
46 LOCAL_SHARED_LIBRARIES := \
47 libbase \
48 libcutils \
49 libhidlbase \
50 libhidltransport \
51 liblog \
52 libnl \
53 libutils \
54 libwifi-hal \
55 libwifi-system-iface \
56 android.hardware.wifi@1.0 \
57 android.hardware.wifi@1.1 \
58 android.hardware.wifi@1.2
59 LOCAL_EXPORT_C_INCLUDE_DIRS := $(LOCAL_PATH)
60 include $(BUILD_STATIC_LIBRARY)
62 ###
63 ### android.hardware.wifi daemon
64 ###
65 include $(CLEAR_VARS)
66 LOCAL_MODULE := android.hardware.wifi@1.0-service
67 LOCAL_MODULE_RELATIVE_PATH := hw
68 LOCAL_PROPRIETARY_MODULE := true
69 LOCAL_CPPFLAGS := -Wall -Werror -Wextra
70 LOCAL_SRC_FILES := \
71 service.cpp
72 LOCAL_SHARED_LIBRARIES := \
73 libbase \
74 libcutils \
75 libhidlbase \
76 libhidltransport \
77 liblog \
78 libnl \
79 libutils \
80 libwifi-hal \
81 libwifi-system-iface \
82 android.hardware.wifi@1.0 \
83 android.hardware.wifi@1.1 \
84 android.hardware.wifi@1.2
85 LOCAL_STATIC_LIBRARIES := \
86 android.hardware.wifi@1.0-service-lib
87 LOCAL_INIT_RC := android.hardware.wifi@1.0-service.rc
88 include $(BUILD_EXECUTABLE)
90 ###
91 ### android.hardware.wifi unit tests.
92 ###
93 include $(CLEAR_VARS)
94 LOCAL_MODULE := android.hardware.wifi@1.0-service-tests
95 LOCAL_PROPRIETARY_MODULE := true
96 LOCAL_SRC_FILES := \
97 tests/hidl_struct_util_unit_tests.cpp \
98 tests/main.cpp \
99 tests/mock_wifi_feature_flags.cpp \
100 tests/mock_wifi_legacy_hal.cpp \
101 tests/mock_wifi_mode_controller.cpp \
102 tests/ringbuffer_unit_tests.cpp \
103 tests/wifi_chip_unit_tests.cpp
104 LOCAL_STATIC_LIBRARIES := \
105 libgmock \
106 libgtest \
107 android.hardware.wifi@1.0-service-lib
108 LOCAL_SHARED_LIBRARIES := \
109 libbase \
110 libcutils \
111 libhidlbase \
112 libhidltransport \
113 liblog \
114 libnl \
115 libutils \
116 libwifi-hal \
117 libwifi-system-iface \
118 android.hardware.wifi@1.0 \
119 android.hardware.wifi@1.1 \
120 android.hardware.wifi@1.2
121 include $(BUILD_NATIVE_TEST)