| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 1 | # Copyright (C) 2011 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 | |
| 15 | LOCAL_PATH := $(call my-dir) |
| 16 | |
| Colin Cross | 432674a | 2014-03-18 12:39:15 -0700 | [diff] [blame] | 17 | ifneq ($(TARGET_BUILD_PDK), true) |
| 18 | |
| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 19 | # Make the JNI part |
| 20 | # ============================================================ |
| 21 | include $(CLEAR_VARS) |
| 22 | |
| Mitchell Wills | 208f92c | 2016-02-25 13:43:25 -0800 | [diff] [blame] | 23 | LOCAL_CFLAGS += -Wall -Werror -Wextra -Wno-unused-parameter -Wno-unused-function \ |
| 24 | -Wunused-variable -Winit-self -Wwrite-strings -Wshadow |
| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 25 | |
| 26 | LOCAL_C_INCLUDES += \ |
| 27 | $(JNI_H_INCLUDE) \ |
| Vinit Deshapnde | 13cf25e | 2014-05-07 20:30:06 -0700 | [diff] [blame] | 28 | libcore/include |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 29 | |
| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 30 | LOCAL_SHARED_LIBRARIES += \ |
| Dimitry Ivanov | d1ee51c | 2016-02-12 17:06:26 -0800 | [diff] [blame] | 31 | liblog \ |
| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 32 | libnativehelper \ |
| 33 | libcutils \ |
| 34 | libutils \ |
| Christopher Wiley | 94a1844 | 2016-06-15 13:04:47 -0700 | [diff] [blame] | 35 | libdl \ |
| Christopher Wiley | 189a1ef | 2016-06-15 12:54:12 -0700 | [diff] [blame] | 36 | libwifi-hal \ |
| Christopher Wiley | 94a1844 | 2016-06-15 13:04:47 -0700 | [diff] [blame] | 37 | libwifi-system |
| Vinit Deshapnde | 7ef73dd | 2014-02-28 08:42:14 -0800 | [diff] [blame] | 38 | |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 39 | LOCAL_SRC_FILES := \ |
| 40 | jni/com_android_server_wifi_WifiNative.cpp \ |
| 41 | jni/jni_helper.cpp |
| 42 | |
| Etan Cohen | 47c56b1 | 2016-03-04 18:00:29 -0800 | [diff] [blame] | 43 | ifeq ($(BOARD_HAS_NAN), true) |
| Etan Cohen | 956f54b | 2015-09-29 13:49:16 -0700 | [diff] [blame] | 44 | LOCAL_SRC_FILES += \ |
| 45 | jni/com_android_server_wifi_nan_WifiNanNative.cpp |
| 46 | endif |
| 47 | |
| Vinit Deshpande | 155b9d0 | 2014-01-08 23:46:46 +0000 | [diff] [blame] | 48 | LOCAL_MODULE := libwifi-service |
| 49 | |
| 50 | include $(BUILD_SHARED_LIBRARY) |
| Colin Cross | 432674a | 2014-03-18 12:39:15 -0700 | [diff] [blame] | 51 | |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 52 | # Build the java code |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 53 | # ============================================================ |
| 54 | |
| Christopher Wiley | ed63ba7 | 2016-06-24 11:16:54 -0700 | [diff] [blame] | 55 | wificond_aidl_path := system/connectivity/wificond/aidl |
| 56 | wificond_aidl_rel_path := ../../../../../$(wificond_aidl_path) |
| 57 | |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 58 | include $(CLEAR_VARS) |
| 59 | |
| Christopher Wiley | ed63ba7 | 2016-06-24 11:16:54 -0700 | [diff] [blame] | 60 | LOCAL_AIDL_INCLUDES := $(LOCAL_PATH)/java $(wificond_aidl_path) |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 61 | LOCAL_SRC_FILES := $(call all-java-files-under, java) \ |
| 62 | $(call all-Iaidl-files-under, java) \ |
| Christopher Wiley | ed63ba7 | 2016-06-24 11:16:54 -0700 | [diff] [blame] | 63 | $(call all-Iaidl-files-under, $(wificond_aidl_rel_path)) \ |
| Glen Kuhne | 1b06783 | 2016-01-04 13:50:09 -0800 | [diff] [blame] | 64 | $(call all-logtags-files-under, java) \ |
| 65 | $(call all-proto-files-under, proto) |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 66 | |
| Etan Cohen | 47c56b1 | 2016-03-04 18:00:29 -0800 | [diff] [blame] | 67 | ifneq ($(BOARD_HAS_NAN), true) |
| Etan Cohen | 956f54b | 2015-09-29 13:49:16 -0700 | [diff] [blame] | 68 | LOCAL_SRC_FILES := $(filter-out $(call all-java-files-under, \ |
| 69 | java/com/android/server/wifi/nan),$(LOCAL_SRC_FILES)) |
| 70 | endif |
| 71 | |
| mukesh agrawal | e4c87d4 | 2016-08-05 14:42:42 -0700 | [diff] [blame] | 72 | LOCAL_JAVA_LIBRARIES := bouncycastle conscrypt jsr305 services |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 73 | LOCAL_REQUIRED_MODULES := services |
| 74 | LOCAL_MODULE_TAGS := |
| 75 | LOCAL_MODULE := wifi-service |
| Glen Kuhne | 1b06783 | 2016-01-04 13:50:09 -0800 | [diff] [blame] | 76 | LOCAL_PROTOC_OPTIMIZE_TYPE := nano |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 77 | |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 78 | include $(BUILD_JAVA_LIBRARY) |
| Vinit Deshapnde | 7f9a15d | 2014-05-07 16:29:44 -0700 | [diff] [blame] | 79 | |
| Vinit Deshapnde | 766cb4b | 2014-05-07 18:00:44 -0700 | [diff] [blame] | 80 | endif |