1# 2# Copyright (C) 2008 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# 16LOCAL_PATH := $(call my-dir) 17 18ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_8_X) 19 20ifneq ($(BOARD_WPA_SUPPLICANT_DRIVER),) 21 CONFIG_DRIVER_$(BOARD_WPA_SUPPLICANT_DRIVER) := y 22endif 23 24# Use a custom libnl on releases before N 25ifeq (0, $(shell test $(PLATFORM_SDK_VERSION) -lt 24; echo $$?)) 26EXTERNAL_GCE_LIBNL_INCLUDE := external/gce/libnl/include 27else 28EXTERNAL_GCE_LIBNL_INCLUDE := 29endif 30 31 32WPA_SUPPL_DIR = external/wpa_supplicant_8 33WPA_SRC_FILE := 34 35include $(WPA_SUPPL_DIR)/wpa_supplicant/android.config 36 37WPA_SUPPL_DIR_INCLUDE = $(WPA_SUPPL_DIR)/src \ 38 $(WPA_SUPPL_DIR)/src/common \ 39 $(WPA_SUPPL_DIR)/src/drivers \ 40 $(WPA_SUPPL_DIR)/src/l2_packet \ 41 $(WPA_SUPPL_DIR)/src/utils \ 42 $(WPA_SUPPL_DIR)/src/wps \ 43 $(WPA_SUPPL_DIR)/wpa_supplicant \ 44 $(EXTERNAL_GCE_LIBNL_INCLUDE) 45 46WPA_SUPPL_DIR_INCLUDE += external/libnl/include 47 48ifdef CONFIG_DRIVER_NL80211 49WPA_SRC_FILE += driver_cmd_nl80211.c 50endif 51 52ifeq ($(TARGET_ARCH),arm) 53# To force sizeof(enum) = 4 54L_CFLAGS += -mabi=aapcs-linux 55endif 56 57ifdef CONFIG_ANDROID_LOG 58L_CFLAGS += -DCONFIG_ANDROID_LOG 59endif 60 61L_CFLAGS += -Wno-unused-parameter 62 63######################## 64 65include $(CLEAR_VARS) 66LOCAL_MODULE := lib_driver_cmd_simulated 67LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD 68LOCAL_LICENSE_CONDITIONS := notice 69LOCAL_VENDOR_MODULE := true 70LOCAL_SHARED_LIBRARIES := libc libcutils liblog 71LOCAL_HEADER_LIBRARIES := libcutils_headers 72 73LOCAL_CFLAGS := $(L_CFLAGS) \ 74 $(GCE_VERSION_CFLAGS) 75 76LOCAL_SRC_FILES := $(WPA_SRC_FILE) 77 78LOCAL_C_INCLUDES := \ 79 $(WPA_SUPPL_DIR_INCLUDE)\ 80 81include $(BUILD_STATIC_LIBRARY) 82 83######################## 84 85endif 86