Dmitry Shmidt | c81d5b6 | 2012-05-14 13:35:02 -0700 | [diff] [blame] | 1 | # Copyright (C) 2008 The Android Open Source Project |
| 2 | # |
| 3 | # This software may be distributed under the terms of the BSD license. |
| 4 | # See README for more details. |
| 5 | # |
| 6 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 7 | LOCAL_PATH := $(call my-dir) |
| 8 | |
| 9 | WPA_BUILD_HOSTAPD := false |
Jeff Brown | bbda627 | 2011-07-11 22:12:15 -0700 | [diff] [blame] | 10 | ifneq ($(BOARD_HOSTAPD_DRIVER),) |
| 11 | WPA_BUILD_HOSTAPD := true |
| 12 | CONFIG_DRIVER_$(BOARD_HOSTAPD_DRIVER) := y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 13 | endif |
| 14 | |
Dmitry Shmidt | e61a2d6 | 2011-06-27 10:59:51 -0700 | [diff] [blame] | 15 | ifeq ($(WPA_BUILD_HOSTAPD),true) |
| 16 | |
Dmitry Shmidt | 7dd0f20 | 2012-02-21 16:49:00 -0800 | [diff] [blame] | 17 | include $(LOCAL_PATH)/android.config |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 18 | |
| 19 | # To ignore possible wrong network configurations |
| 20 | L_CFLAGS = -DWPA_IGNORE_CONFIG_ERRORS |
| 21 | |
Dmitry Shmidt | 95613e4 | 2011-10-25 10:50:42 -0700 | [diff] [blame] | 22 | L_CFLAGS += -DVERSION_STR_POSTFIX=\"-$(PLATFORM_VERSION)\" |
| 23 | |
Dmitry Shmidt | 648b749 | 2011-09-30 15:03:42 -0700 | [diff] [blame] | 24 | # Set Android log name |
| 25 | L_CFLAGS += -DANDROID_LOG_NAME=\"hostapd\" |
| 26 | |
Chih-Hung Hsieh | 0220b4c | 2017-11-07 11:08:08 -0800 | [diff] [blame] | 27 | L_CFLAGS += -Wall -Werror |
| 28 | |
Dmitry Shmidt | f9bdef9 | 2014-04-25 10:46:36 -0700 | [diff] [blame] | 29 | # Disable unused parameter warnings |
| 30 | L_CFLAGS += -Wno-unused-parameter |
| 31 | |
Chih-Hung Hsieh | 0220b4c | 2017-11-07 11:08:08 -0800 | [diff] [blame] | 32 | # Disable unused variable warnings |
| 33 | L_CFLAGS += -Wno-unused-variable |
| 34 | |
Christopher Ferris | b6c19e0 | 2017-02-23 15:50:04 -0800 | [diff] [blame] | 35 | # Disable macro redefined warnings |
| 36 | L_CFLAGS += -Wno-macro-redefined |
| 37 | |
Dmitry Shmidt | b58836e | 2014-04-29 14:35:56 -0700 | [diff] [blame] | 38 | # Set Android extended P2P functionality |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 39 | L_CFLAGS += -DANDROID_P2P |
Dmitry Shmidt | 4171258 | 2015-06-29 11:02:15 -0700 | [diff] [blame] | 40 | |
Dmitry Shmidt | b58836e | 2014-04-29 14:35:56 -0700 | [diff] [blame] | 41 | ifeq ($(BOARD_HOSTAPD_PRIVATE_LIB),) |
Dmitry Shmidt | 4171258 | 2015-06-29 11:02:15 -0700 | [diff] [blame] | 42 | L_CFLAGS += -DANDROID_LIB_STUB |
Mike J. Chen | 0cc49e8 | 2012-12-05 11:20:29 -0800 | [diff] [blame] | 43 | endif |
| 44 | |
Sunil Ravi | b3580db | 2022-01-28 12:25:46 -0800 | [diff] [blame] | 45 | ifeq ($(BOARD_HOSTAPD_CONFIG_80211W_MFP_OPTIONAL),true) |
| 46 | L_CFLAGS += -DENABLE_HOSTAPD_CONFIG_80211W_MFP_OPTIONAL |
| 47 | endif |
| 48 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 49 | ifneq ($(BOARD_HOSTAPD_PRIVATE_LIB_EVENT),) |
| 50 | L_CFLAGS += -DANDROID_LIB_EVENT |
| 51 | endif |
| 52 | |
Jeff Johnson | 205f214 | 2012-09-03 22:12:17 -0700 | [diff] [blame] | 53 | # Use Android specific directory for control interface sockets |
Huajun Tong | 527b3ba | 2018-04-20 16:29:50 +0800 | [diff] [blame] | 54 | L_CFLAGS += -DCONFIG_CTRL_IFACE_CLIENT_DIR=\"/data/vendor/wifi/hostapd/sockets\" |
| 55 | L_CFLAGS += -DCONFIG_CTRL_IFACE_DIR=\"/data/vendor/wifi/hostapd/ctrl\" |
Jeff Johnson | 205f214 | 2012-09-03 22:12:17 -0700 | [diff] [blame] | 56 | |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 57 | # Use Android specific directory for hostapd_cli command completion history |
Huajun Tong | 527b3ba | 2018-04-20 16:29:50 +0800 | [diff] [blame] | 58 | L_CFLAGS += -DCONFIG_HOSTAPD_CLI_HISTORY_DIR=\"/data/vendor/wifi/hostapd\" |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 59 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 60 | # To force sizeof(enum) = 4 |
| 61 | ifeq ($(TARGET_ARCH),arm) |
| 62 | L_CFLAGS += -mabi=aapcs-linux |
| 63 | endif |
| 64 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 65 | INCLUDES = $(LOCAL_PATH) |
| 66 | INCLUDES += $(LOCAL_PATH)/src |
| 67 | INCLUDES += $(LOCAL_PATH)/src/utils |
Stephen Smalley | f1396b4 | 2012-11-16 12:50:03 -0500 | [diff] [blame] | 68 | INCLUDES += system/security/keystore/include |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 69 | ifdef CONFIG_DRIVER_NL80211 |
Dmitry Shmidt | cd44645 | 2014-02-18 16:03:35 -0800 | [diff] [blame] | 70 | ifneq ($(wildcard external/libnl),) |
Dmitry Shmidt | d620e6d | 2014-02-18 11:07:59 -0800 | [diff] [blame] | 71 | INCLUDES += external/libnl/include |
Dmitry Shmidt | cd44645 | 2014-02-18 16:03:35 -0800 | [diff] [blame] | 72 | else |
| 73 | INCLUDES += external/libnl-headers |
| 74 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 75 | endif |
| 76 | |
Kai Shi | e75b065 | 2020-11-24 20:31:29 -0800 | [diff] [blame] | 77 | ifdef CONFIG_TESTING_OPTIONS |
| 78 | L_CFLAGS += -DCONFIG_TESTING_OPTIONS |
| 79 | CONFIG_WPS_TESTING=y |
| 80 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 81 | |
| 82 | ifndef CONFIG_OS |
| 83 | ifdef CONFIG_NATIVE_WINDOWS |
| 84 | CONFIG_OS=win32 |
| 85 | else |
| 86 | CONFIG_OS=unix |
| 87 | endif |
| 88 | endif |
| 89 | |
| 90 | ifeq ($(CONFIG_OS), internal) |
| 91 | L_CFLAGS += -DOS_NO_C_LIB_DEFINES |
| 92 | endif |
| 93 | |
| 94 | ifdef CONFIG_NATIVE_WINDOWS |
| 95 | L_CFLAGS += -DCONFIG_NATIVE_WINDOWS |
| 96 | LIBS += -lws2_32 |
| 97 | endif |
| 98 | |
| 99 | OBJS = main.c |
| 100 | OBJS += config_file.c |
| 101 | |
| 102 | OBJS += src/ap/hostapd.c |
| 103 | OBJS += src/ap/wpa_auth_glue.c |
| 104 | OBJS += src/ap/drv_callbacks.c |
| 105 | OBJS += src/ap/ap_drv_ops.c |
| 106 | OBJS += src/ap/utils.c |
| 107 | OBJS += src/ap/authsrv.c |
| 108 | OBJS += src/ap/ieee802_1x.c |
| 109 | OBJS += src/ap/ap_config.c |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 110 | OBJS += src/ap/eap_user_db.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 111 | OBJS += src/ap/ieee802_11_auth.c |
| 112 | OBJS += src/ap/sta_info.c |
| 113 | OBJS += src/ap/wpa_auth.c |
| 114 | OBJS += src/ap/tkip_countermeasures.c |
| 115 | OBJS += src/ap/ap_mlme.c |
| 116 | OBJS += src/ap/wpa_auth_ie.c |
| 117 | OBJS += src/ap/preauth_auth.c |
| 118 | OBJS += src/ap/pmksa_cache_auth.c |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 119 | OBJS += src/ap/ieee802_11_shared.c |
| 120 | OBJS += src/ap/beacon.c |
Dmitry Shmidt | fb45fd5 | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 121 | OBJS += src/ap/bss_load.c |
Dmitry Shmidt | 849734c | 2016-05-27 09:59:01 -0700 | [diff] [blame] | 122 | OBJS += src/ap/neighbor_db.c |
| 123 | OBJS += src/ap/rrm.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 124 | OBJS_d = |
| 125 | OBJS_p = |
| 126 | LIBS = |
| 127 | LIBS_c = |
| 128 | HOBJS = |
| 129 | LIBS_h = |
| 130 | |
| 131 | NEED_RC4=y |
| 132 | NEED_AES=y |
| 133 | NEED_MD5=y |
| 134 | NEED_SHA1=y |
| 135 | |
| 136 | OBJS += src/drivers/drivers.c |
| 137 | L_CFLAGS += -DHOSTAPD |
| 138 | |
| 139 | ifdef CONFIG_WPA_TRACE |
| 140 | L_CFLAGS += -DWPA_TRACE |
| 141 | OBJS += src/utils/trace.c |
| 142 | HOBJS += src/utils/trace.c |
| 143 | LDFLAGS += -rdynamic |
| 144 | L_CFLAGS += -funwind-tables |
| 145 | ifdef CONFIG_WPA_TRACE_BFD |
| 146 | L_CFLAGS += -DWPA_TRACE_BFD |
| 147 | LIBS += -lbfd |
| 148 | LIBS_c += -lbfd |
| 149 | LIBS_h += -lbfd |
| 150 | endif |
| 151 | endif |
| 152 | |
| 153 | OBJS += src/utils/eloop.c |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 154 | |
| 155 | ifdef CONFIG_ELOOP_POLL |
| 156 | L_CFLAGS += -DCONFIG_ELOOP_POLL |
| 157 | endif |
| 158 | |
| 159 | ifdef CONFIG_ELOOP_EPOLL |
| 160 | L_CFLAGS += -DCONFIG_ELOOP_EPOLL |
| 161 | endif |
| 162 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 163 | OBJS += src/utils/common.c |
| 164 | OBJS += src/utils/wpa_debug.c |
| 165 | OBJS += src/utils/wpabuf.c |
| 166 | OBJS += src/utils/os_$(CONFIG_OS).c |
| 167 | OBJS += src/utils/ip_addr.c |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 168 | OBJS += src/utils/crc32.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 169 | |
| 170 | OBJS += src/common/ieee802_11_common.c |
| 171 | OBJS += src/common/wpa_common.c |
Dmitry Shmidt | 746bde5 | 2015-01-12 13:01:47 -0800 | [diff] [blame] | 172 | OBJS += src/common/hw_features_common.c |
Sunil Ravi | 99c035e | 2024-07-12 01:42:03 +0000 | [diff] [blame^] | 173 | OBJS += src/common/ptksa_cache.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 174 | |
| 175 | OBJS += src/eapol_auth/eapol_auth_sm.c |
| 176 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 177 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 178 | ifndef CONFIG_NO_DUMP_STATE |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 179 | # define HOSTAPD_DUMP_STATE to include support for dumping internal state |
| 180 | # through control interface commands (undefine it, if you want to save in |
| 181 | # binary size) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 182 | L_CFLAGS += -DHOSTAPD_DUMP_STATE |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 183 | OBJS += src/eapol_auth/eapol_auth_dump.c |
| 184 | endif |
| 185 | |
| 186 | ifdef CONFIG_NO_RADIUS |
| 187 | L_CFLAGS += -DCONFIG_NO_RADIUS |
| 188 | CONFIG_NO_ACCOUNTING=y |
| 189 | else |
| 190 | OBJS += src/radius/radius.c |
| 191 | OBJS += src/radius/radius_client.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 192 | OBJS += src/radius/radius_das.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 193 | endif |
| 194 | |
| 195 | ifdef CONFIG_NO_ACCOUNTING |
| 196 | L_CFLAGS += -DCONFIG_NO_ACCOUNTING |
| 197 | else |
| 198 | OBJS += src/ap/accounting.c |
| 199 | endif |
| 200 | |
| 201 | ifdef CONFIG_NO_VLAN |
| 202 | L_CFLAGS += -DCONFIG_NO_VLAN |
| 203 | else |
| 204 | OBJS += src/ap/vlan_init.c |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 205 | OBJS += src/ap/vlan_ifconfig.c |
Dmitry Shmidt | 57c2d39 | 2016-02-23 13:40:19 -0800 | [diff] [blame] | 206 | OBJS += src/ap/vlan.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 207 | ifdef CONFIG_FULL_DYNAMIC_VLAN |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 208 | # Define CONFIG_FULL_DYNAMIC_VLAN to have hostapd manipulate bridges |
| 209 | # and VLAN interfaces for the VLAN feature. |
| 210 | L_CFLAGS += -DCONFIG_FULL_DYNAMIC_VLAN |
| 211 | OBJS += src/ap/vlan_full.c |
| 212 | ifdef CONFIG_VLAN_NETLINK |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 213 | OBJS += src/ap/vlan_util.c |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 214 | else |
| 215 | OBJS += src/ap/vlan_ioctl.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 216 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 217 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 218 | endif |
| 219 | |
| 220 | ifdef CONFIG_NO_CTRL_IFACE |
| 221 | L_CFLAGS += -DCONFIG_NO_CTRL_IFACE |
| 222 | else |
Dmitry Shmidt | 31a29cc | 2016-03-09 15:58:17 -0800 | [diff] [blame] | 223 | OBJS += src/common/ctrl_iface_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 224 | OBJS += ctrl_iface.c |
| 225 | OBJS += src/ap/ctrl_iface_ap.c |
| 226 | endif |
| 227 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 228 | L_CFLAGS += -DCONFIG_CTRL_IFACE -DCONFIG_CTRL_IFACE_UNIX |
| 229 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 230 | ifdef CONFIG_RSN_PREAUTH |
| 231 | L_CFLAGS += -DCONFIG_RSN_PREAUTH |
| 232 | CONFIG_L2_PACKET=y |
| 233 | endif |
| 234 | |
Dmitry Shmidt | f21452a | 2014-02-26 10:55:25 -0800 | [diff] [blame] | 235 | ifdef CONFIG_HS20 |
Dmitry Shmidt | fb45fd5 | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 236 | CONFIG_PROXYARP=y |
| 237 | endif |
| 238 | |
| 239 | ifdef CONFIG_PROXYARP |
| 240 | CONFIG_L2_PACKET=y |
| 241 | endif |
| 242 | |
| 243 | ifdef CONFIG_SUITEB |
| 244 | L_CFLAGS += -DCONFIG_SUITEB |
Dmitry Shmidt | f21452a | 2014-02-26 10:55:25 -0800 | [diff] [blame] | 245 | endif |
| 246 | |
Dmitry Shmidt | 40b0720 | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 247 | ifdef CONFIG_SUITEB192 |
| 248 | L_CFLAGS += -DCONFIG_SUITEB192 |
| 249 | NEED_SHA384=y |
| 250 | endif |
| 251 | |
Hai Shalom | 74f70d4 | 2019-02-11 14:42:39 -0800 | [diff] [blame] | 252 | ifdef CONFIG_OCV |
| 253 | L_CFLAGS += -DCONFIG_OCV |
| 254 | OBJS += src/common/ocv.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 255 | endif |
| 256 | |
Sunil Ravi | b0ac25f | 2024-07-12 01:42:03 +0000 | [diff] [blame] | 257 | NEED_AES_UNWRAP=y |
| 258 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 259 | ifdef CONFIG_IEEE80211R |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 260 | L_CFLAGS += -DCONFIG_IEEE80211R -DCONFIG_IEEE80211R_AP |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 261 | OBJS += src/ap/wpa_auth_ft.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 262 | NEED_AES_UNWRAP=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 263 | NEED_AES_SIV=y |
| 264 | NEED_ETH_P_OUI=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 265 | NEED_HMAC_SHA256_KDF=y |
| 266 | endif |
| 267 | |
| 268 | ifdef NEED_ETH_P_OUI |
| 269 | L_CFLAGS += -DCONFIG_ETH_P_OUI |
| 270 | OBJS += src/ap/eth_p_oui.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 271 | endif |
| 272 | |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 273 | ifdef CONFIG_SAE |
| 274 | L_CFLAGS += -DCONFIG_SAE |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 275 | OBJS += src/common/sae.c |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 276 | ifdef CONFIG_SAE_PK |
| 277 | L_CFLAGS += -DCONFIG_SAE_PK |
Sunil | 8cd6f4d | 2022-06-28 18:40:46 +0000 | [diff] [blame] | 278 | NEED_AES_SIV=y |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 279 | OBJS += src/common/sae_pk.c |
| 280 | endif |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 281 | NEED_ECC=y |
| 282 | NEED_DH_GROUPS=y |
Hai Shalom | b755a2a | 2020-04-23 21:49:02 -0700 | [diff] [blame] | 283 | NEED_HMAC_SHA256_KDF=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 284 | NEED_DRAGONFLY=y |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 285 | endif |
| 286 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 287 | ifdef CONFIG_OWE |
| 288 | L_CFLAGS += -DCONFIG_OWE |
| 289 | NEED_ECC=y |
| 290 | NEED_HMAC_SHA256_KDF=y |
| 291 | NEED_HMAC_SHA384_KDF=y |
| 292 | NEED_HMAC_SHA512_KDF=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 293 | NEED_SHA384=y |
| 294 | NEED_SHA512=y |
| 295 | endif |
| 296 | |
Jimmy Chen | caaac07 | 2019-09-16 16:36:06 +0800 | [diff] [blame] | 297 | ifdef CONFIG_WAPI_INTERFACE |
| 298 | L_CFLAGS += -DCONFIG_WAPI_INTERFACE |
| 299 | endif |
| 300 | |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 301 | ifdef CONFIG_FILS |
| 302 | L_CFLAGS += -DCONFIG_FILS |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 303 | OBJS += src/ap/fils_hlp.c |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 304 | NEED_SHA384=y |
| 305 | NEED_AES_SIV=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 306 | ifdef CONFIG_FILS_SK_PFS |
| 307 | L_CFLAGS += -DCONFIG_FILS_SK_PFS |
| 308 | NEED_ECC=y |
| 309 | endif |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 310 | endif |
| 311 | |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 312 | ifdef CONFIG_WNM |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 313 | L_CFLAGS += -DCONFIG_WNM -DCONFIG_WNM_AP |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 314 | OBJS += src/ap/wnm_ap.c |
| 315 | endif |
| 316 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 317 | ifdef CONFIG_IEEE80211AC |
| 318 | L_CFLAGS += -DCONFIG_IEEE80211AC |
| 319 | endif |
| 320 | |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 321 | ifdef CONFIG_IEEE80211BE |
| 322 | CONFIG_IEEE80211AX=y |
| 323 | L_CFLAGS += -DCONFIG_IEEE80211BE |
| 324 | OBJS += src/ap/ieee802_11_eht.c |
| 325 | endif |
| 326 | |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 327 | ifdef CONFIG_IEEE80211AX |
| 328 | L_CFLAGS += -DCONFIG_IEEE80211AX |
| 329 | endif |
| 330 | |
Dmitry Shmidt | 57c2d39 | 2016-02-23 13:40:19 -0800 | [diff] [blame] | 331 | ifdef CONFIG_MBO |
| 332 | L_CFLAGS += -DCONFIG_MBO |
| 333 | OBJS += src/ap/mbo_ap.c |
| 334 | endif |
| 335 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 336 | ifdef CONFIG_FST |
| 337 | L_CFLAGS += -DCONFIG_FST |
| 338 | OBJS += src/fst/fst.c |
| 339 | OBJS += src/fst/fst_group.c |
| 340 | OBJS += src/fst/fst_iface.c |
| 341 | OBJS += src/fst/fst_session.c |
| 342 | OBJS += src/fst/fst_ctrl_aux.c |
| 343 | ifdef CONFIG_FST_TEST |
| 344 | L_CFLAGS += -DCONFIG_FST_TEST |
| 345 | endif |
| 346 | ifndef CONFIG_NO_CTRL_IFACE |
| 347 | OBJS += src/fst/fst_ctrl_iface.c |
| 348 | endif |
| 349 | endif |
| 350 | |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 351 | ifdef CONFIG_WEP |
| 352 | L_CFLAGS += -DCONFIG_WEP |
| 353 | endif |
| 354 | |
Hai Shalom | b755a2a | 2020-04-23 21:49:02 -0700 | [diff] [blame] | 355 | ifdef CONFIG_NO_TKIP |
| 356 | L_CFLAGS += -DCONFIG_NO_TKIP |
| 357 | endif |
| 358 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 359 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 360 | include $(LOCAL_PATH)/src/drivers/drivers.mk |
| 361 | |
| 362 | OBJS += $(DRV_AP_OBJS) |
| 363 | L_CFLAGS += $(DRV_AP_CFLAGS) |
| 364 | LDFLAGS += $(DRV_AP_LDFLAGS) |
| 365 | LIBS += $(DRV_AP_LIBS) |
| 366 | |
| 367 | ifdef CONFIG_L2_PACKET |
| 368 | ifdef CONFIG_DNET_PCAP |
| 369 | ifdef CONFIG_L2_FREEBSD |
| 370 | LIBS += -lpcap |
| 371 | OBJS += src/l2_packet/l2_packet_freebsd.c |
| 372 | else |
| 373 | LIBS += -ldnet -lpcap |
| 374 | OBJS += src/l2_packet/l2_packet_pcap.c |
| 375 | endif |
| 376 | else |
| 377 | OBJS += src/l2_packet/l2_packet_linux.c |
| 378 | endif |
| 379 | else |
| 380 | OBJS += src/l2_packet/l2_packet_none.c |
| 381 | endif |
| 382 | |
| 383 | |
| 384 | ifdef CONFIG_EAP_MD5 |
| 385 | L_CFLAGS += -DEAP_SERVER_MD5 |
| 386 | OBJS += src/eap_server/eap_server_md5.c |
| 387 | CHAP=y |
| 388 | endif |
| 389 | |
| 390 | ifdef CONFIG_EAP_TLS |
| 391 | L_CFLAGS += -DEAP_SERVER_TLS |
| 392 | OBJS += src/eap_server/eap_server_tls.c |
| 393 | TLS_FUNCS=y |
| 394 | endif |
| 395 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 396 | ifdef CONFIG_EAP_UNAUTH_TLS |
| 397 | L_CFLAGS += -DEAP_SERVER_UNAUTH_TLS |
| 398 | ifndef CONFIG_EAP_TLS |
| 399 | OBJS += src/eap_server/eap_server_tls.c |
| 400 | TLS_FUNCS=y |
| 401 | endif |
| 402 | endif |
| 403 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 404 | ifdef CONFIG_EAP_PEAP |
| 405 | L_CFLAGS += -DEAP_SERVER_PEAP |
| 406 | OBJS += src/eap_server/eap_server_peap.c |
| 407 | OBJS += src/eap_common/eap_peap_common.c |
| 408 | TLS_FUNCS=y |
| 409 | CONFIG_EAP_MSCHAPV2=y |
| 410 | endif |
| 411 | |
| 412 | ifdef CONFIG_EAP_TTLS |
| 413 | L_CFLAGS += -DEAP_SERVER_TTLS |
| 414 | OBJS += src/eap_server/eap_server_ttls.c |
| 415 | TLS_FUNCS=y |
| 416 | CHAP=y |
| 417 | endif |
| 418 | |
| 419 | ifdef CONFIG_EAP_MSCHAPV2 |
| 420 | L_CFLAGS += -DEAP_SERVER_MSCHAPV2 |
| 421 | OBJS += src/eap_server/eap_server_mschapv2.c |
| 422 | MS_FUNCS=y |
| 423 | endif |
| 424 | |
| 425 | ifdef CONFIG_EAP_GTC |
| 426 | L_CFLAGS += -DEAP_SERVER_GTC |
| 427 | OBJS += src/eap_server/eap_server_gtc.c |
| 428 | endif |
| 429 | |
| 430 | ifdef CONFIG_EAP_SIM |
| 431 | L_CFLAGS += -DEAP_SERVER_SIM |
| 432 | OBJS += src/eap_server/eap_server_sim.c |
| 433 | CONFIG_EAP_SIM_COMMON=y |
| 434 | NEED_AES_CBC=y |
| 435 | endif |
| 436 | |
| 437 | ifdef CONFIG_EAP_AKA |
| 438 | L_CFLAGS += -DEAP_SERVER_AKA |
| 439 | OBJS += src/eap_server/eap_server_aka.c |
| 440 | CONFIG_EAP_SIM_COMMON=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 441 | NEED_AES_CBC=y |
| 442 | endif |
| 443 | |
| 444 | ifdef CONFIG_EAP_AKA_PRIME |
| 445 | L_CFLAGS += -DEAP_SERVER_AKA_PRIME |
| 446 | endif |
| 447 | |
| 448 | ifdef CONFIG_EAP_SIM_COMMON |
| 449 | OBJS += src/eap_common/eap_sim_common.c |
| 450 | # Example EAP-SIM/AKA interface for GSM/UMTS authentication. This can be |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 451 | # replaced with another file implementing the interface specified in |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 452 | # eap_sim_db.h. |
| 453 | OBJS += src/eap_server/eap_sim_db.c |
| 454 | NEED_FIPS186_2_PRF=y |
| 455 | endif |
| 456 | |
| 457 | ifdef CONFIG_EAP_PAX |
| 458 | L_CFLAGS += -DEAP_SERVER_PAX |
| 459 | OBJS += src/eap_server/eap_server_pax.c src/eap_common/eap_pax_common.c |
| 460 | endif |
| 461 | |
| 462 | ifdef CONFIG_EAP_PSK |
| 463 | L_CFLAGS += -DEAP_SERVER_PSK |
| 464 | OBJS += src/eap_server/eap_server_psk.c src/eap_common/eap_psk_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 465 | NEED_AES_ENCBLOCK=y |
| 466 | NEED_AES_EAX=y |
| 467 | endif |
| 468 | |
| 469 | ifdef CONFIG_EAP_SAKE |
| 470 | L_CFLAGS += -DEAP_SERVER_SAKE |
| 471 | OBJS += src/eap_server/eap_server_sake.c src/eap_common/eap_sake_common.c |
| 472 | endif |
| 473 | |
| 474 | ifdef CONFIG_EAP_GPSK |
| 475 | L_CFLAGS += -DEAP_SERVER_GPSK |
| 476 | OBJS += src/eap_server/eap_server_gpsk.c src/eap_common/eap_gpsk_common.c |
| 477 | ifdef CONFIG_EAP_GPSK_SHA256 |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 478 | L_CFLAGS += -DEAP_GPSK_SHA256 |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 479 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 480 | endif |
| 481 | |
| 482 | ifdef CONFIG_EAP_PWD |
| 483 | L_CFLAGS += -DEAP_SERVER_PWD |
| 484 | OBJS += src/eap_server/eap_server_pwd.c src/eap_common/eap_pwd_common.c |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 485 | NEED_ECC=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 486 | NEED_DRAGONFLY=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 487 | endif |
| 488 | |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 489 | ifdef CONFIG_EAP_EKE |
| 490 | L_CFLAGS += -DEAP_SERVER_EKE |
| 491 | OBJS += src/eap_server/eap_server_eke.c src/eap_common/eap_eke_common.c |
| 492 | NEED_DH_GROUPS=y |
| 493 | NEED_DH_GROUPS_ALL=y |
| 494 | endif |
| 495 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 496 | ifdef CONFIG_EAP_VENDOR_TEST |
| 497 | L_CFLAGS += -DEAP_SERVER_VENDOR_TEST |
| 498 | OBJS += src/eap_server/eap_server_vendor_test.c |
| 499 | endif |
| 500 | |
| 501 | ifdef CONFIG_EAP_FAST |
| 502 | L_CFLAGS += -DEAP_SERVER_FAST |
| 503 | OBJS += src/eap_server/eap_server_fast.c |
| 504 | OBJS += src/eap_common/eap_fast_common.c |
| 505 | TLS_FUNCS=y |
| 506 | NEED_T_PRF=y |
| 507 | NEED_AES_UNWRAP=y |
| 508 | endif |
| 509 | |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 510 | ifdef CONFIG_EAP_TEAP |
| 511 | L_CFLAGS += -DEAP_SERVER_TEAP |
| 512 | OBJS += src/eap_server/eap_server_teap.c |
| 513 | OBJS += src/eap_common/eap_teap_common.c |
| 514 | TLS_FUNCS=y |
| 515 | NEED_T_PRF=y |
| 516 | NEED_SHA384=y |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 517 | NEED_TLS_PRF_SHA256=y |
| 518 | NEED_TLS_PRF_SHA384=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 519 | NEED_AES_UNWRAP=y |
| 520 | endif |
| 521 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 522 | ifdef CONFIG_WPS |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 523 | L_CFLAGS += -DCONFIG_WPS -DEAP_SERVER_WSC |
| 524 | OBJS += src/utils/uuid.c |
| 525 | OBJS += src/ap/wps_hostapd.c |
| 526 | OBJS += src/eap_server/eap_server_wsc.c src/eap_common/eap_wsc_common.c |
| 527 | OBJS += src/wps/wps.c |
| 528 | OBJS += src/wps/wps_common.c |
| 529 | OBJS += src/wps/wps_attr_parse.c |
| 530 | OBJS += src/wps/wps_attr_build.c |
| 531 | OBJS += src/wps/wps_attr_process.c |
| 532 | OBJS += src/wps/wps_dev_attr.c |
| 533 | OBJS += src/wps/wps_enrollee.c |
| 534 | OBJS += src/wps/wps_registrar.c |
| 535 | NEED_DH_GROUPS=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 536 | NEED_BASE64=y |
| 537 | NEED_AES_CBC=y |
| 538 | NEED_MODEXP=y |
| 539 | CONFIG_EAP=y |
| 540 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 541 | ifdef CONFIG_WPS_NFC |
| 542 | L_CFLAGS += -DCONFIG_WPS_NFC |
| 543 | OBJS += src/wps/ndef.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 544 | NEED_WPS_OOB=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 545 | endif |
| 546 | |
| 547 | ifdef NEED_WPS_OOB |
| 548 | L_CFLAGS += -DCONFIG_WPS_OOB |
| 549 | endif |
| 550 | |
| 551 | ifdef CONFIG_WPS_UPNP |
| 552 | L_CFLAGS += -DCONFIG_WPS_UPNP |
| 553 | OBJS += src/wps/wps_upnp.c |
| 554 | OBJS += src/wps/wps_upnp_ssdp.c |
| 555 | OBJS += src/wps/wps_upnp_web.c |
| 556 | OBJS += src/wps/wps_upnp_event.c |
| 557 | OBJS += src/wps/wps_upnp_ap.c |
| 558 | OBJS += src/wps/upnp_xml.c |
| 559 | OBJS += src/wps/httpread.c |
| 560 | OBJS += src/wps/http_client.c |
| 561 | OBJS += src/wps/http_server.c |
| 562 | endif |
| 563 | |
| 564 | ifdef CONFIG_WPS_STRICT |
| 565 | L_CFLAGS += -DCONFIG_WPS_STRICT |
| 566 | OBJS += src/wps/wps_validate.c |
| 567 | endif |
| 568 | |
| 569 | ifdef CONFIG_WPS_TESTING |
| 570 | L_CFLAGS += -DCONFIG_WPS_TESTING |
| 571 | endif |
| 572 | |
| 573 | endif |
| 574 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 575 | ifdef CONFIG_DPP |
| 576 | L_CFLAGS += -DCONFIG_DPP |
| 577 | OBJS += src/common/dpp.c |
Hai Shalom | 4fbc08f | 2020-05-18 12:37:00 -0700 | [diff] [blame] | 578 | OBJS += src/common/dpp_auth.c |
| 579 | OBJS += src/common/dpp_backup.c |
| 580 | OBJS += src/common/dpp_crypto.c |
| 581 | OBJS += src/common/dpp_pkex.c |
| 582 | OBJS += src/common/dpp_reconfig.c |
| 583 | OBJS += src/common/dpp_tcp.c |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 584 | OBJS += src/ap/dpp_hostapd.c |
| 585 | OBJS += src/ap/gas_query_ap.c |
| 586 | NEED_AES_SIV=y |
| 587 | NEED_HMAC_SHA256_KDF=y |
| 588 | NEED_HMAC_SHA384_KDF=y |
| 589 | NEED_HMAC_SHA512_KDF=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 590 | NEED_SHA384=y |
| 591 | NEED_SHA512=y |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 592 | NEED_ECC=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 593 | NEED_JSON=y |
| 594 | NEED_GAS=y |
| 595 | NEED_BASE64=y |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 596 | NEED_ASN1=y |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 597 | ifdef CONFIG_DPP2 |
| 598 | L_CFLAGS += -DCONFIG_DPP2 |
| 599 | endif |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 600 | ifdef CONFIG_DPP3 |
| 601 | L_CFLAGS += -DCONFIG_DPP3 |
| 602 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 603 | endif |
| 604 | |
Sunil Ravi | b0ac25f | 2024-07-12 01:42:03 +0000 | [diff] [blame] | 605 | ifdef CONFIG_NAN_USD |
| 606 | OBJS += src/common/nan_de.c |
| 607 | OBJS += src/ap/nan_usd_ap.c |
| 608 | L_CFLAGS += -DCONFIG_NAN_USD |
| 609 | endif |
| 610 | |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 611 | ifdef CONFIG_PASN |
| 612 | L_CFLAGS += -DCONFIG_PASN |
| 613 | L_CFLAGS += -DCONFIG_PTKSA_CACHE |
| 614 | NEED_HMAC_SHA256_KDF=y |
| 615 | NEED_HMAC_SHA384_KDF=y |
| 616 | NEED_SHA256=y |
| 617 | NEED_SHA384=y |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 618 | endif |
| 619 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 620 | ifdef CONFIG_EAP_IKEV2 |
| 621 | L_CFLAGS += -DEAP_SERVER_IKEV2 |
| 622 | OBJS += src/eap_server/eap_server_ikev2.c src/eap_server/ikev2.c |
| 623 | OBJS += src/eap_common/eap_ikev2_common.c src/eap_common/ikev2_common.c |
| 624 | NEED_DH_GROUPS=y |
| 625 | NEED_DH_GROUPS_ALL=y |
| 626 | NEED_MODEXP=y |
| 627 | NEED_CIPHER=y |
| 628 | endif |
| 629 | |
| 630 | ifdef CONFIG_EAP_TNC |
| 631 | L_CFLAGS += -DEAP_SERVER_TNC |
| 632 | OBJS += src/eap_server/eap_server_tnc.c |
| 633 | OBJS += src/eap_server/tncs.c |
| 634 | NEED_BASE64=y |
| 635 | ifndef CONFIG_DRIVER_BSD |
| 636 | LIBS += -ldl |
| 637 | endif |
| 638 | endif |
| 639 | |
| 640 | # Basic EAP functionality is needed for EAPOL |
| 641 | OBJS += eap_register.c |
| 642 | OBJS += src/eap_server/eap_server.c |
| 643 | OBJS += src/eap_common/eap_common.c |
| 644 | OBJS += src/eap_server/eap_server_methods.c |
| 645 | OBJS += src/eap_server/eap_server_identity.c |
| 646 | L_CFLAGS += -DEAP_SERVER_IDENTITY |
| 647 | |
| 648 | ifdef CONFIG_EAP |
| 649 | L_CFLAGS += -DEAP_SERVER |
| 650 | endif |
| 651 | |
| 652 | ifdef CONFIG_PKCS12 |
| 653 | L_CFLAGS += -DPKCS12_FUNCS |
| 654 | endif |
| 655 | |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 656 | ifdef NEED_DRAGONFLY |
| 657 | OBJS += src/common/dragonfly.c |
| 658 | endif |
| 659 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 660 | ifdef MS_FUNCS |
| 661 | OBJS += src/crypto/ms_funcs.c |
| 662 | NEED_DES=y |
| 663 | NEED_MD4=y |
| 664 | endif |
| 665 | |
| 666 | ifdef CHAP |
| 667 | OBJS += src/eap_common/chap.c |
| 668 | endif |
| 669 | |
Sunil Ravi | 99c035e | 2024-07-12 01:42:03 +0000 | [diff] [blame^] | 670 | ifdef CONFIG_RADIUS_TLS |
| 671 | TLS_FUNCS=y |
| 672 | L_CFLAGS += -DCONFIG_RADIUS_TLS |
| 673 | endif |
| 674 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 675 | ifdef TLS_FUNCS |
| 676 | NEED_DES=y |
| 677 | # Shared TLS functions (needed for EAP_TLS, EAP_PEAP, and EAP_TTLS) |
| 678 | L_CFLAGS += -DEAP_TLS_FUNCS |
| 679 | OBJS += src/eap_server/eap_server_tls_common.c |
| 680 | NEED_TLS_PRF=y |
| 681 | endif |
| 682 | |
| 683 | ifndef CONFIG_TLS |
| 684 | CONFIG_TLS=openssl |
| 685 | endif |
| 686 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 687 | ifdef CONFIG_TLSV11 |
| 688 | L_CFLAGS += -DCONFIG_TLSV11 |
| 689 | endif |
| 690 | |
| 691 | ifdef CONFIG_TLSV12 |
| 692 | L_CFLAGS += -DCONFIG_TLSV12 |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 693 | endif |
| 694 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 695 | ifeq ($(CONFIG_TLS), openssl) |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 696 | L_CFLAGS += -DCRYPTO_RSA_OAEP_SHA256 |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 697 | ifdef TLS_FUNCS |
| 698 | OBJS += src/crypto/tls_openssl.c |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 699 | OBJS += src/crypto/tls_openssl_ocsp.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 700 | LIBS += -lssl |
| 701 | endif |
| 702 | OBJS += src/crypto/crypto_openssl.c |
| 703 | HOBJS += src/crypto/crypto_openssl.c |
| 704 | ifdef NEED_FIPS186_2_PRF |
| 705 | OBJS += src/crypto/fips_prf_openssl.c |
| 706 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 707 | NEED_TLS_PRF_SHA256=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 708 | LIBS += -lcrypto |
| 709 | LIBS_h += -lcrypto |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 710 | ifndef CONFIG_TLS_DEFAULT_CIPHERS |
| 711 | CONFIG_TLS_DEFAULT_CIPHERS = "DEFAULT:!EXP:!LOW" |
| 712 | endif |
| 713 | L_CFLAGS += -DTLS_DEFAULT_CIPHERS=\"$(CONFIG_TLS_DEFAULT_CIPHERS)\" |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 714 | endif |
| 715 | |
| 716 | ifeq ($(CONFIG_TLS), gnutls) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 717 | ifndef CONFIG_CRYPTO |
| 718 | # default to libgcrypt |
| 719 | CONFIG_CRYPTO=gnutls |
| 720 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 721 | ifdef TLS_FUNCS |
| 722 | OBJS += src/crypto/tls_gnutls.c |
| 723 | LIBS += -lgnutls -lgpg-error |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 724 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 725 | OBJS += src/crypto/crypto_$(CONFIG_CRYPTO).c |
| 726 | HOBJS += src/crypto/crypto_$(CONFIG_CRYPTO).c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 727 | ifdef NEED_FIPS186_2_PRF |
Dmitry Shmidt | 9866086 | 2014-03-11 17:26:21 -0700 | [diff] [blame] | 728 | OBJS += src/crypto/fips_prf_internal.c |
| 729 | OBJS += src/crypto/sha1-internal.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 730 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 731 | ifeq ($(CONFIG_CRYPTO), gnutls) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 732 | LIBS += -lgcrypt |
| 733 | LIBS_h += -lgcrypt |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 734 | CONFIG_INTERNAL_RC4=y |
| 735 | CONFIG_INTERNAL_DH_GROUP5=y |
| 736 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 737 | ifeq ($(CONFIG_CRYPTO), nettle) |
| 738 | LIBS += -lnettle -lgmp |
| 739 | LIBS_p += -lnettle -lgmp |
| 740 | CONFIG_INTERNAL_RC4=y |
| 741 | CONFIG_INTERNAL_DH_GROUP5=y |
| 742 | endif |
| 743 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 744 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 745 | ifeq ($(CONFIG_TLS), internal) |
| 746 | ifndef CONFIG_CRYPTO |
| 747 | CONFIG_CRYPTO=internal |
| 748 | endif |
| 749 | ifdef TLS_FUNCS |
| 750 | OBJS += src/crypto/crypto_internal-rsa.c |
| 751 | OBJS += src/crypto/tls_internal.c |
| 752 | OBJS += src/tls/tlsv1_common.c |
| 753 | OBJS += src/tls/tlsv1_record.c |
| 754 | OBJS += src/tls/tlsv1_cred.c |
| 755 | OBJS += src/tls/tlsv1_server.c |
| 756 | OBJS += src/tls/tlsv1_server_write.c |
| 757 | OBJS += src/tls/tlsv1_server_read.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 758 | OBJS += src/tls/rsa.c |
| 759 | OBJS += src/tls/x509v3.c |
| 760 | OBJS += src/tls/pkcs1.c |
| 761 | OBJS += src/tls/pkcs5.c |
| 762 | OBJS += src/tls/pkcs8.c |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 763 | NEED_ASN1=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 764 | NEED_BASE64=y |
| 765 | NEED_TLS_PRF=y |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 766 | ifdef CONFIG_TLSV12 |
| 767 | NEED_TLS_PRF_SHA256=y |
| 768 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 769 | NEED_MODEXP=y |
| 770 | NEED_CIPHER=y |
| 771 | L_CFLAGS += -DCONFIG_TLS_INTERNAL |
| 772 | L_CFLAGS += -DCONFIG_TLS_INTERNAL_SERVER |
| 773 | endif |
| 774 | ifdef NEED_CIPHER |
| 775 | NEED_DES=y |
| 776 | OBJS += src/crypto/crypto_internal-cipher.c |
| 777 | endif |
| 778 | ifdef NEED_MODEXP |
| 779 | OBJS += src/crypto/crypto_internal-modexp.c |
| 780 | OBJS += src/tls/bignum.c |
| 781 | endif |
| 782 | ifeq ($(CONFIG_CRYPTO), libtomcrypt) |
| 783 | OBJS += src/crypto/crypto_libtomcrypt.c |
| 784 | LIBS += -ltomcrypt -ltfm |
| 785 | LIBS_h += -ltomcrypt -ltfm |
| 786 | CONFIG_INTERNAL_SHA256=y |
| 787 | CONFIG_INTERNAL_RC4=y |
| 788 | CONFIG_INTERNAL_DH_GROUP5=y |
| 789 | endif |
| 790 | ifeq ($(CONFIG_CRYPTO), internal) |
| 791 | OBJS += src/crypto/crypto_internal.c |
| 792 | NEED_AES_DEC=y |
| 793 | L_CFLAGS += -DCONFIG_CRYPTO_INTERNAL |
| 794 | ifdef CONFIG_INTERNAL_LIBTOMMATH |
| 795 | L_CFLAGS += -DCONFIG_INTERNAL_LIBTOMMATH |
| 796 | ifdef CONFIG_INTERNAL_LIBTOMMATH_FAST |
| 797 | L_CFLAGS += -DLTM_FAST |
| 798 | endif |
| 799 | else |
| 800 | LIBS += -ltommath |
| 801 | LIBS_h += -ltommath |
| 802 | endif |
| 803 | CONFIG_INTERNAL_AES=y |
| 804 | CONFIG_INTERNAL_DES=y |
| 805 | CONFIG_INTERNAL_SHA1=y |
| 806 | CONFIG_INTERNAL_MD4=y |
| 807 | CONFIG_INTERNAL_MD5=y |
| 808 | CONFIG_INTERNAL_SHA256=y |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 809 | CONFIG_INTERNAL_SHA384=y |
| 810 | CONFIG_INTERNAL_SHA512=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 811 | CONFIG_INTERNAL_RC4=y |
| 812 | CONFIG_INTERNAL_DH_GROUP5=y |
| 813 | endif |
| 814 | ifeq ($(CONFIG_CRYPTO), cryptoapi) |
| 815 | OBJS += src/crypto/crypto_cryptoapi.c |
| 816 | OBJS_p += src/crypto/crypto_cryptoapi.c |
| 817 | L_CFLAGS += -DCONFIG_CRYPTO_CRYPTOAPI |
| 818 | CONFIG_INTERNAL_SHA256=y |
| 819 | CONFIG_INTERNAL_RC4=y |
| 820 | endif |
| 821 | endif |
| 822 | |
| 823 | ifeq ($(CONFIG_TLS), none) |
| 824 | ifdef TLS_FUNCS |
| 825 | OBJS += src/crypto/tls_none.c |
| 826 | L_CFLAGS += -DEAP_TLS_NONE |
| 827 | CONFIG_INTERNAL_AES=y |
| 828 | CONFIG_INTERNAL_SHA1=y |
| 829 | CONFIG_INTERNAL_MD5=y |
| 830 | endif |
| 831 | OBJS += src/crypto/crypto_none.c |
| 832 | OBJS_p += src/crypto/crypto_none.c |
| 833 | CONFIG_INTERNAL_SHA256=y |
| 834 | CONFIG_INTERNAL_RC4=y |
| 835 | endif |
| 836 | |
| 837 | ifndef TLS_FUNCS |
| 838 | OBJS += src/crypto/tls_none.c |
| 839 | ifeq ($(CONFIG_TLS), internal) |
| 840 | CONFIG_INTERNAL_AES=y |
| 841 | CONFIG_INTERNAL_SHA1=y |
| 842 | CONFIG_INTERNAL_MD5=y |
| 843 | CONFIG_INTERNAL_RC4=y |
| 844 | endif |
| 845 | endif |
| 846 | |
| 847 | AESOBJS = # none so far |
| 848 | ifdef CONFIG_INTERNAL_AES |
| 849 | AESOBJS += src/crypto/aes-internal.c src/crypto/aes-internal-enc.c |
| 850 | endif |
| 851 | |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 852 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 853 | AESOBJS += src/crypto/aes-wrap.c |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 854 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 855 | ifdef NEED_AES_EAX |
| 856 | AESOBJS += src/crypto/aes-eax.c |
| 857 | NEED_AES_CTR=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 858 | endif |
| 859 | ifdef NEED_AES_SIV |
| 860 | AESOBJS += src/crypto/aes-siv.c |
| 861 | NEED_AES_CTR=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 862 | endif |
| 863 | ifdef NEED_AES_CTR |
| 864 | AESOBJS += src/crypto/aes-ctr.c |
| 865 | endif |
| 866 | ifdef NEED_AES_ENCBLOCK |
| 867 | AESOBJS += src/crypto/aes-encblock.c |
| 868 | endif |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 869 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 870 | AESOBJS += src/crypto/aes-omac1.c |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 871 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 872 | ifdef NEED_AES_UNWRAP |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 873 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 874 | NEED_AES_DEC=y |
| 875 | AESOBJS += src/crypto/aes-unwrap.c |
| 876 | endif |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 877 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 878 | ifdef NEED_AES_CBC |
| 879 | NEED_AES_DEC=y |
Dmitry Shmidt | 912c6ec | 2015-03-30 13:16:51 -0700 | [diff] [blame] | 880 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 881 | AESOBJS += src/crypto/aes-cbc.c |
| 882 | endif |
Dmitry Shmidt | 912c6ec | 2015-03-30 13:16:51 -0700 | [diff] [blame] | 883 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 884 | ifdef NEED_AES_DEC |
| 885 | ifdef CONFIG_INTERNAL_AES |
| 886 | AESOBJS += src/crypto/aes-internal-dec.c |
| 887 | endif |
| 888 | endif |
| 889 | ifdef NEED_AES |
| 890 | OBJS += $(AESOBJS) |
| 891 | endif |
| 892 | |
| 893 | SHA1OBJS = |
| 894 | ifdef NEED_SHA1 |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 895 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 896 | ifneq ($(CONFIG_TLS), gnutls) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 897 | SHA1OBJS += src/crypto/sha1.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 898 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 899 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 900 | SHA1OBJS += src/crypto/sha1-prf.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 901 | ifdef CONFIG_INTERNAL_SHA1 |
| 902 | SHA1OBJS += src/crypto/sha1-internal.c |
| 903 | ifdef NEED_FIPS186_2_PRF |
| 904 | SHA1OBJS += src/crypto/fips_prf_internal.c |
| 905 | endif |
| 906 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 907 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 908 | SHA1OBJS += src/crypto/sha1-pbkdf2.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 909 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 910 | ifdef NEED_T_PRF |
| 911 | SHA1OBJS += src/crypto/sha1-tprf.c |
| 912 | endif |
| 913 | ifdef NEED_TLS_PRF |
| 914 | SHA1OBJS += src/crypto/sha1-tlsprf.c |
| 915 | endif |
| 916 | endif |
| 917 | |
| 918 | ifdef NEED_SHA1 |
| 919 | OBJS += $(SHA1OBJS) |
| 920 | endif |
| 921 | |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 922 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 923 | ifneq ($(CONFIG_TLS), gnutls) |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 924 | OBJS += src/crypto/md5.c |
| 925 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 926 | endif |
Dmitry Shmidt | aff761d | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 927 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 928 | ifdef NEED_MD5 |
| 929 | ifdef CONFIG_INTERNAL_MD5 |
| 930 | OBJS += src/crypto/md5-internal.c |
| 931 | HOBJS += src/crypto/md5-internal.c |
| 932 | endif |
| 933 | endif |
| 934 | |
| 935 | ifdef NEED_MD4 |
| 936 | ifdef CONFIG_INTERNAL_MD4 |
| 937 | OBJS += src/crypto/md4-internal.c |
| 938 | endif |
| 939 | endif |
| 940 | |
| 941 | ifdef NEED_DES |
| 942 | ifdef CONFIG_INTERNAL_DES |
| 943 | OBJS += src/crypto/des-internal.c |
| 944 | endif |
| 945 | endif |
| 946 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 947 | ifdef CONFIG_NO_RC4 |
| 948 | L_CFLAGS += -DCONFIG_NO_RC4 |
| 949 | endif |
| 950 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 951 | ifdef NEED_RC4 |
| 952 | ifdef CONFIG_INTERNAL_RC4 |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 953 | ifndef CONFIG_NO_RC4 |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 954 | OBJS += src/crypto/rc4.c |
| 955 | endif |
| 956 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 957 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 958 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 959 | L_CFLAGS += -DCONFIG_SHA256 |
| 960 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 961 | ifneq ($(CONFIG_TLS), gnutls) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 962 | OBJS += src/crypto/sha256.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 963 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 964 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 965 | OBJS += src/crypto/sha256-prf.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 966 | ifdef CONFIG_INTERNAL_SHA256 |
| 967 | OBJS += src/crypto/sha256-internal.c |
| 968 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 969 | ifdef NEED_TLS_PRF_SHA256 |
| 970 | OBJS += src/crypto/sha256-tlsprf.c |
| 971 | endif |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 972 | ifdef NEED_TLS_PRF_SHA384 |
| 973 | OBJS += src/crypto/sha384-tlsprf.c |
| 974 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 975 | ifdef NEED_HMAC_SHA256_KDF |
| 976 | OBJS += src/crypto/sha256-kdf.c |
| 977 | endif |
| 978 | ifdef NEED_HMAC_SHA384_KDF |
| 979 | OBJS += src/crypto/sha384-kdf.c |
| 980 | endif |
| 981 | ifdef NEED_HMAC_SHA512_KDF |
| 982 | OBJS += src/crypto/sha512-kdf.c |
| 983 | endif |
Dmitry Shmidt | 40b0720 | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 984 | ifdef NEED_SHA384 |
| 985 | L_CFLAGS += -DCONFIG_SHA384 |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 986 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 987 | ifneq ($(CONFIG_TLS), gnutls) |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 988 | OBJS += src/crypto/sha384.c |
| 989 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 990 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 991 | OBJS += src/crypto/sha384-prf.c |
Dmitry Shmidt | 40b0720 | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 992 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 993 | ifdef NEED_SHA512 |
| 994 | L_CFLAGS += -DCONFIG_SHA512 |
| 995 | ifneq ($(CONFIG_TLS), openssl) |
| 996 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 997 | ifneq ($(CONFIG_TLS), gnutls) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 998 | OBJS += src/crypto/sha512.c |
| 999 | endif |
| 1000 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1001 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1002 | OBJS += src/crypto/sha512-prf.c |
| 1003 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1004 | |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 1005 | ifdef CONFIG_INTERNAL_SHA384 |
| 1006 | L_CFLAGS += -DCONFIG_INTERNAL_SHA384 |
| 1007 | OBJS += src/crypto/sha384-internal.c |
| 1008 | endif |
| 1009 | |
| 1010 | ifdef CONFIG_INTERNAL_SHA512 |
| 1011 | L_CFLAGS += -DCONFIG_INTERNAL_SHA512 |
| 1012 | OBJS += src/crypto/sha512-internal.c |
| 1013 | endif |
| 1014 | |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 1015 | ifdef NEED_ASN1 |
| 1016 | OBJS += src/tls/asn1.c |
| 1017 | endif |
| 1018 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1019 | ifdef NEED_DH_GROUPS |
| 1020 | OBJS += src/crypto/dh_groups.c |
| 1021 | endif |
| 1022 | ifdef NEED_DH_GROUPS_ALL |
| 1023 | L_CFLAGS += -DALL_DH_GROUPS |
| 1024 | endif |
| 1025 | ifdef CONFIG_INTERNAL_DH_GROUP5 |
| 1026 | ifdef NEED_DH_GROUPS |
| 1027 | OBJS += src/crypto/dh_group5.c |
| 1028 | endif |
| 1029 | endif |
| 1030 | |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 1031 | ifdef NEED_ECC |
| 1032 | L_CFLAGS += -DCONFIG_ECC |
| 1033 | endif |
| 1034 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1035 | ifdef CONFIG_NO_RANDOM_POOL |
| 1036 | L_CFLAGS += -DCONFIG_NO_RANDOM_POOL |
| 1037 | else |
| 1038 | OBJS += src/crypto/random.c |
| 1039 | HOBJS += src/crypto/random.c |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1040 | HOBJS += src/utils/eloop.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1041 | HOBJS += $(SHA1OBJS) |
Dmitry Shmidt | dda10c2 | 2015-03-24 16:05:01 -0700 | [diff] [blame] | 1042 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1043 | HOBJS += src/crypto/md5.c |
| 1044 | endif |
Dmitry Shmidt | dda10c2 | 2015-03-24 16:05:01 -0700 | [diff] [blame] | 1045 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1046 | |
| 1047 | ifdef CONFIG_RADIUS_SERVER |
| 1048 | L_CFLAGS += -DRADIUS_SERVER |
| 1049 | OBJS += src/radius/radius_server.c |
| 1050 | endif |
| 1051 | |
| 1052 | ifdef CONFIG_IPV6 |
| 1053 | L_CFLAGS += -DCONFIG_IPV6 |
| 1054 | endif |
| 1055 | |
| 1056 | ifdef CONFIG_DRIVER_RADIUS_ACL |
| 1057 | L_CFLAGS += -DCONFIG_DRIVER_RADIUS_ACL |
| 1058 | endif |
| 1059 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1060 | ifdef NEED_BASE64 |
| 1061 | OBJS += src/utils/base64.c |
| 1062 | endif |
| 1063 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1064 | ifdef NEED_JSON |
| 1065 | OBJS += src/utils/json.c |
| 1066 | L_CFLAGS += -DCONFIG_JSON |
| 1067 | endif |
| 1068 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1069 | ifdef NEED_AP_MLME |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1070 | OBJS += src/ap/wmm.c |
| 1071 | OBJS += src/ap/ap_list.c |
Sunil Ravi | 38ad1ed | 2023-01-17 23:58:31 +0000 | [diff] [blame] | 1072 | OBJS += src/ap/comeback_token.c |
| 1073 | OBJS += src/pasn/pasn_responder.c |
Sunil Ravi | 99c035e | 2024-07-12 01:42:03 +0000 | [diff] [blame^] | 1074 | OBJS += src/pasn/pasn_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1075 | OBJS += src/ap/ieee802_11.c |
| 1076 | OBJS += src/ap/hw_features.c |
Dmitry Shmidt | 051af73 | 2013-10-22 13:52:46 -0700 | [diff] [blame] | 1077 | OBJS += src/ap/dfs.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1078 | L_CFLAGS += -DNEED_AP_MLME |
| 1079 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1080 | OBJS += src/ap/ieee802_11_ht.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1081 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1082 | ifdef CONFIG_IEEE80211AC |
| 1083 | OBJS += src/ap/ieee802_11_vht.c |
| 1084 | endif |
| 1085 | |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 1086 | ifdef CONFIG_IEEE80211AX |
| 1087 | OBJS += src/ap/ieee802_11_he.c |
| 1088 | endif |
| 1089 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1090 | ifdef CONFIG_P2P_MANAGER |
| 1091 | L_CFLAGS += -DCONFIG_P2P_MANAGER |
| 1092 | OBJS += src/ap/p2p_hostapd.c |
| 1093 | endif |
| 1094 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1095 | ifdef CONFIG_HS20 |
| 1096 | L_CFLAGS += -DCONFIG_HS20 |
| 1097 | OBJS += src/ap/hs20.c |
| 1098 | CONFIG_INTERWORKING=y |
| 1099 | endif |
| 1100 | |
| 1101 | ifdef CONFIG_INTERWORKING |
| 1102 | L_CFLAGS += -DCONFIG_INTERWORKING |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1103 | NEED_GAS=y |
| 1104 | endif |
| 1105 | |
| 1106 | ifdef NEED_GAS |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1107 | OBJS += src/common/gas.c |
| 1108 | OBJS += src/ap/gas_serv.c |
| 1109 | endif |
| 1110 | |
Dmitry Shmidt | fb45fd5 | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 1111 | ifdef CONFIG_PROXYARP |
| 1112 | L_CFLAGS += -DCONFIG_PROXYARP |
| 1113 | OBJS += src/ap/x_snoop.c |
| 1114 | OBJS += src/ap/dhcp_snoop.c |
| 1115 | ifdef CONFIG_IPV6 |
| 1116 | OBJS += src/ap/ndisc_snoop.c |
| 1117 | endif |
| 1118 | endif |
| 1119 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1120 | OBJS += src/drivers/driver_common.c |
| 1121 | |
Dmitry Shmidt | 5460547 | 2013-11-08 11:10:19 -0800 | [diff] [blame] | 1122 | ifdef CONFIG_ACS |
| 1123 | L_CFLAGS += -DCONFIG_ACS |
| 1124 | OBJS += src/ap/acs.c |
| 1125 | LIBS += -lm |
| 1126 | endif |
| 1127 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1128 | ifdef CONFIG_NO_STDOUT_DEBUG |
| 1129 | L_CFLAGS += -DCONFIG_NO_STDOUT_DEBUG |
| 1130 | endif |
| 1131 | |
Paul Stewart | 092955c | 2017-02-06 09:13:09 -0800 | [diff] [blame] | 1132 | ifdef CONFIG_DEBUG_SYSLOG |
| 1133 | L_CFLAGS += -DCONFIG_DEBUG_SYSLOG |
| 1134 | endif |
| 1135 | |
Dmitry Shmidt | 5460547 | 2013-11-08 11:10:19 -0800 | [diff] [blame] | 1136 | ifdef CONFIG_DEBUG_LINUX_TRACING |
| 1137 | L_CFLAGS += -DCONFIG_DEBUG_LINUX_TRACING |
| 1138 | endif |
| 1139 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1140 | ifdef CONFIG_DEBUG_FILE |
| 1141 | L_CFLAGS += -DCONFIG_DEBUG_FILE |
| 1142 | endif |
| 1143 | |
| 1144 | ifdef CONFIG_ANDROID_LOG |
| 1145 | L_CFLAGS += -DCONFIG_ANDROID_LOG |
| 1146 | endif |
| 1147 | |
Dmitry Shmidt | 7f2c753 | 2016-08-15 09:48:12 -0700 | [diff] [blame] | 1148 | OBJS_c = hostapd_cli.c |
| 1149 | OBJS_c += src/common/wpa_ctrl.c |
| 1150 | OBJS_c += src/utils/os_$(CONFIG_OS).c |
| 1151 | OBJS_c += src/common/cli.c |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1152 | OBJS_c += src/utils/eloop.c |
Dmitry Shmidt | a3dc309 | 2015-06-23 11:21:28 -0700 | [diff] [blame] | 1153 | OBJS_c += src/utils/common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1154 | ifdef CONFIG_WPA_TRACE |
| 1155 | OBJS_c += src/utils/trace.c |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1156 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1157 | OBJS_c += src/utils/wpa_debug.c |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1158 | ifdef CONFIG_WPA_CLI_EDIT |
| 1159 | OBJS_c += src/utils/edit.c |
| 1160 | else |
| 1161 | OBJS_c += src/utils/edit_simple.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1162 | endif |
| 1163 | |
Bjoern Johansson | 05c7f27 | 2018-05-15 14:58:52 -0700 | [diff] [blame] | 1164 | ifeq ($(filter gce_x86 gce_x86_64 calypso, $(TARGET_DEVICE)),) |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1165 | ifdef CONFIG_CTRL_IFACE_AIDL |
| 1166 | HOSTAPD_USE_AIDL=y |
| 1167 | L_CFLAGS += -DCONFIG_CTRL_IFACE_AIDL |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1168 | L_CPPFLAGS = -Wall -Werror |
| 1169 | endif |
Roshan Pius | 35ecec4 | 2018-01-16 17:49:00 -0800 | [diff] [blame] | 1170 | endif |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1171 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1172 | ######################## |
| 1173 | |
| 1174 | include $(CLEAR_VARS) |
| 1175 | LOCAL_MODULE := hostapd_cli |
Bob Badour | ef67f87 | 2021-02-12 15:20:04 -0800 | [diff] [blame] | 1176 | LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-BSD-3-Clause SPDX-license-identifier-ISC legacy_unencumbered |
| 1177 | LOCAL_LICENSE_CONDITIONS := notice unencumbered |
Bob Badour | 618e16c | 2022-02-14 12:41:29 -0800 | [diff] [blame] | 1178 | LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../LICENSE |
Po-Chien Hsueh | 2051e4b | 2017-02-10 11:34:58 +0800 | [diff] [blame] | 1179 | LOCAL_PROPRIETARY_MODULE := true |
Ying Wang | e93dd11 | 2013-04-09 21:53:29 -0700 | [diff] [blame] | 1180 | LOCAL_SHARED_LIBRARIES := libc libcutils liblog |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1181 | LOCAL_CFLAGS := $(L_CFLAGS) |
| 1182 | LOCAL_SRC_FILES := $(OBJS_c) |
| 1183 | LOCAL_C_INCLUDES := $(INCLUDES) |
| 1184 | include $(BUILD_EXECUTABLE) |
| 1185 | |
| 1186 | ######################## |
| 1187 | include $(CLEAR_VARS) |
| 1188 | LOCAL_MODULE := hostapd |
Bob Badour | ef67f87 | 2021-02-12 15:20:04 -0800 | [diff] [blame] | 1189 | LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-BSD-3-Clause SPDX-license-identifier-ISC legacy_unencumbered |
| 1190 | LOCAL_LICENSE_CONDITIONS := notice unencumbered |
Bob Badour | 618e16c | 2022-02-14 12:41:29 -0800 | [diff] [blame] | 1191 | LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../LICENSE |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1192 | LOCAL_MODULE_TAGS := optional |
Po-Chien Hsueh | 2051e4b | 2017-02-10 11:34:58 +0800 | [diff] [blame] | 1193 | LOCAL_PROPRIETARY_MODULE := true |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1194 | LOCAL_MODULE_RELATIVE_PATH := hw |
Kiyoung Kim | b853dac | 2024-08-12 08:18:33 +0000 | [diff] [blame] | 1195 | LOCAL_REQUIRED_MODULES += android.hardware.wifi.hostapd.xml |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1196 | ifdef CONFIG_DRIVER_CUSTOM |
| 1197 | LOCAL_STATIC_LIBRARIES := libCustomWifi |
| 1198 | endif |
| 1199 | ifneq ($(BOARD_HOSTAPD_PRIVATE_LIB),) |
| 1200 | LOCAL_STATIC_LIBRARIES += $(BOARD_HOSTAPD_PRIVATE_LIB) |
| 1201 | endif |
Ying Wang | e93dd11 | 2013-04-09 21:53:29 -0700 | [diff] [blame] | 1202 | LOCAL_SHARED_LIBRARIES := libc libcutils liblog libcrypto libssl |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1203 | ifdef CONFIG_DRIVER_NL80211 |
Dmitry Shmidt | cd44645 | 2014-02-18 16:03:35 -0800 | [diff] [blame] | 1204 | ifneq ($(wildcard external/libnl),) |
Dmitry Shmidt | d620e6d | 2014-02-18 11:07:59 -0800 | [diff] [blame] | 1205 | LOCAL_SHARED_LIBRARIES += libnl |
Dmitry Shmidt | cd44645 | 2014-02-18 16:03:35 -0800 | [diff] [blame] | 1206 | else |
| 1207 | LOCAL_STATIC_LIBRARIES += libnl_2 |
| 1208 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1209 | endif |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1210 | ifeq ($(HOSTAPD_USE_AIDL), y) |
Les Lee | 36412a5 | 2024-09-06 18:31:55 +0000 | [diff] [blame] | 1211 | LOCAL_SHARED_LIBRARIES += android.hardware.wifi.hostapd-V3-ndk |
Gabriel Biren | 3c3347e | 2023-10-09 19:41:16 +0000 | [diff] [blame] | 1212 | LOCAL_SHARED_LIBRARIES += android.hardware.wifi.common-V1-ndk |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1213 | LOCAL_SHARED_LIBRARIES += libbase libutils |
| 1214 | LOCAL_SHARED_LIBRARIES += libbinder_ndk |
| 1215 | LOCAL_STATIC_LIBRARIES += libhostapd_aidl |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1216 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1217 | LOCAL_CFLAGS := $(L_CFLAGS) |
| 1218 | LOCAL_SRC_FILES := $(OBJS) |
| 1219 | LOCAL_C_INCLUDES := $(INCLUDES) |
Christopher Wiley | 5ec9510 | 2016-07-13 10:34:47 -0700 | [diff] [blame] | 1220 | LOCAL_INIT_RC := hostapd.android.rc |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1221 | include $(BUILD_EXECUTABLE) |
| 1222 | |
Bjoern Johansson | 05c7f27 | 2018-05-15 14:58:52 -0700 | [diff] [blame] | 1223 | ######################## |
| 1224 | include $(CLEAR_VARS) |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1225 | LOCAL_MODULE := hostapd_noaidl |
Bob Badour | ef67f87 | 2021-02-12 15:20:04 -0800 | [diff] [blame] | 1226 | LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-BSD-3-Clause SPDX-license-identifier-ISC legacy_unencumbered |
| 1227 | LOCAL_LICENSE_CONDITIONS := notice unencumbered |
Bob Badour | 618e16c | 2022-02-14 12:41:29 -0800 | [diff] [blame] | 1228 | LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../LICENSE |
Bjoern Johansson | 05c7f27 | 2018-05-15 14:58:52 -0700 | [diff] [blame] | 1229 | LOCAL_MODULE_TAGS := optional |
| 1230 | LOCAL_PROPRIETARY_MODULE := true |
| 1231 | ifdef CONFIG_DRIVER_CUSTOM |
| 1232 | LOCAL_STATIC_LIBRARIES := libCustomWifi |
| 1233 | endif |
| 1234 | ifneq ($(BOARD_HOSTAPD_PRIVATE_LIB),) |
| 1235 | LOCAL_STATIC_LIBRARIES += $(BOARD_HOSTAPD_PRIVATE_LIB) |
| 1236 | endif |
| 1237 | LOCAL_SHARED_LIBRARIES := libc libcutils liblog libcrypto libssl |
| 1238 | ifdef CONFIG_DRIVER_NL80211 |
| 1239 | ifneq ($(wildcard external/libnl),) |
| 1240 | LOCAL_SHARED_LIBRARIES += libnl |
| 1241 | else |
| 1242 | LOCAL_STATIC_LIBRARIES += libnl_2 |
| 1243 | endif |
| 1244 | endif |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1245 | LOCAL_CFLAGS := $(patsubst -DCONFIG_CTRL_IFACE_AIDL,,$(L_CFLAGS)) |
Bjoern Johansson | 05c7f27 | 2018-05-15 14:58:52 -0700 | [diff] [blame] | 1246 | LOCAL_SRC_FILES := $(OBJS) |
| 1247 | LOCAL_C_INCLUDES := $(INCLUDES) |
| 1248 | include $(BUILD_EXECUTABLE) |
| 1249 | |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1250 | ifeq ($(HOSTAPD_USE_AIDL), y) |
| 1251 | ### Aidl service library ### |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1252 | ######################## |
| 1253 | include $(CLEAR_VARS) |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1254 | LOCAL_MODULE := libhostapd_aidl |
Bob Badour | ef67f87 | 2021-02-12 15:20:04 -0800 | [diff] [blame] | 1255 | LOCAL_LICENSE_KINDS := SPDX-license-identifier-BSD SPDX-license-identifier-BSD-3-Clause SPDX-license-identifier-ISC legacy_unencumbered |
| 1256 | LOCAL_LICENSE_CONDITIONS := notice unencumbered |
| 1257 | LOCAL_NOTICE_FILE := $(LOCAL_PATH)/../COPYING $(LOCAL_PATH)/../NOTICE |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1258 | LOCAL_VENDOR_MODULE := true |
| 1259 | LOCAL_CPPFLAGS := $(L_CPPFLAGS) |
| 1260 | LOCAL_CFLAGS := $(L_CFLAGS) |
| 1261 | LOCAL_C_INCLUDES := $(INCLUDES) |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1262 | LOCAL_SRC_FILES := \ |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1263 | aidl/aidl.cpp \ |
| 1264 | aidl/hostapd.cpp |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1265 | LOCAL_SHARED_LIBRARIES := \ |
Les Lee | 36412a5 | 2024-09-06 18:31:55 +0000 | [diff] [blame] | 1266 | android.hardware.wifi.hostapd-V3-ndk \ |
Gabriel Biren | 3c3347e | 2023-10-09 19:41:16 +0000 | [diff] [blame] | 1267 | android.hardware.wifi.common-V1-ndk \ |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1268 | libbinder_ndk \ |
Roshan Pius | 30b452e | 2017-12-27 13:36:21 -0800 | [diff] [blame] | 1269 | libbase \ |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1270 | libutils \ |
| 1271 | liblog |
| 1272 | LOCAL_EXPORT_C_INCLUDE_DIRS := \ |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1273 | $(LOCAL_PATH)/aidl |
Roshan Pius | cc81756 | 2017-12-22 14:45:05 -0800 | [diff] [blame] | 1274 | include $(BUILD_STATIC_LIBRARY) |
Gabriel Biren | 72cf9a5 | 2021-06-25 23:29:26 +0000 | [diff] [blame] | 1275 | endif # HOSTAPD_USE_AIDL == y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1276 | endif # ifeq ($(WPA_BUILD_HOSTAPD),true) |