Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1 | BINALL=wpa_supplicant wpa_cli |
| 2 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 3 | ALL = $(BINALL) |
| 4 | ALL += systemd/wpa_supplicant.service |
| 5 | ALL += systemd/wpa_supplicant@.service |
| 6 | ALL += systemd/wpa_supplicant-nl80211@.service |
| 7 | ALL += systemd/wpa_supplicant-wired@.service |
| 8 | ALL += dbus/fi.w1.wpa_supplicant1.service |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 9 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 10 | EXTRA_TARGETS=dynamic_eap_methods |
| 11 | |
| 12 | CONFIG_FILE=.config |
| 13 | include ../src/build.rules |
| 14 | |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 15 | ifdef CONFIG_BUILD_WPA_CLIENT_SO |
| 16 | # add the dependency this way to allow CONFIG_BUILD_WPA_CLIENT_SO |
| 17 | # being set in the config which is read by build.rules |
| 18 | _all: libwpa_client.so |
| 19 | endif |
| 20 | |
| 21 | ifndef CONFIG_NO_WPA_PASSPHRASE |
| 22 | # add the dependency this way to allow CONFIG_NO_WPA_PASSPHRASE |
| 23 | # being set in the config which is read by build.rules |
| 24 | _all: wpa_passphrase |
| 25 | endif |
| 26 | |
Dmitry Shmidt | 014a3ff | 2015-12-28 13:27:49 -0800 | [diff] [blame] | 27 | ifdef LIBS |
| 28 | # If LIBS is set with some global build system defaults, clone those for |
| 29 | # LIBS_c and LIBS_p to cover wpa_passphrase and wpa_cli as well. |
| 30 | ifndef LIBS_c |
| 31 | LIBS_c := $(LIBS) |
| 32 | endif |
| 33 | ifndef LIBS_p |
| 34 | LIBS_p := $(LIBS) |
| 35 | endif |
| 36 | endif |
| 37 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 38 | export LIBDIR ?= /usr/local/lib |
| 39 | export INCDIR ?= /usr/local/include |
| 40 | export BINDIR ?= /usr/local/sbin |
Dmitry Shmidt | c55524a | 2011-07-07 11:18:38 -0700 | [diff] [blame] | 41 | PKG_CONFIG ?= pkg-config |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 42 | |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 43 | CFLAGS += $(EXTRA_CFLAGS) |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 44 | CFLAGS += -I$(abspath ../src) |
| 45 | CFLAGS += -I$(abspath ../src/utils) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 46 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 47 | ifndef CONFIG_NO_GITVER |
| 48 | # Add VERSION_STR postfix for builds from a git repository |
| 49 | ifeq ($(wildcard ../.git),../.git) |
| 50 | GITVER := $(shell git describe --dirty=+) |
| 51 | ifneq ($(GITVER),) |
| 52 | CFLAGS += -DGIT_VERSION_STR_POSTFIX=\"-$(GITVER)\" |
| 53 | endif |
| 54 | endif |
| 55 | endif |
| 56 | |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 57 | ifdef CONFIG_TESTING_OPTIONS |
| 58 | CFLAGS += -DCONFIG_TESTING_OPTIONS |
| 59 | CONFIG_WPS_TESTING=y |
| 60 | CONFIG_TDLS_TESTING=y |
| 61 | endif |
| 62 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 63 | mkconfig: |
| 64 | @if [ -f .config ]; then \ |
| 65 | echo '.config exists - did not replace it'; \ |
| 66 | exit 1; \ |
| 67 | fi |
| 68 | echo CONFIG_DRIVER_HOSTAP=y >> .config |
| 69 | echo CONFIG_DRIVER_WEXT=y >> .config |
| 70 | |
Dmitry Shmidt | c5ec7f5 | 2012-03-06 16:33:24 -0800 | [diff] [blame] | 71 | $(DESTDIR)$(BINDIR)/%: % |
| 72 | install -D $(<) $(@) |
| 73 | |
| 74 | install: $(addprefix $(DESTDIR)$(BINDIR)/,$(BINALL)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 75 | $(MAKE) -C ../src install |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 76 | ifndef CONFIG_NO_WPA_PASSPHRASE |
| 77 | install -D wpa_passphrase $(DESTDIR)/$(BINDIR)/wpa_passphrase |
| 78 | endif |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 79 | ifdef CONFIG_BUILD_WPA_CLIENT_SO |
| 80 | install -m 0644 -D libwpa_client.so $(DESTDIR)/$(LIBDIR)/libwpa_client.so |
| 81 | install -m 0644 -D ../src/common/wpa_ctrl.h $(DESTDIR)/$(INCDIR)/wpa_ctrl.h |
| 82 | endif |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 83 | if ls eap_*.so >/dev/null 2>&1; then \ |
| 84 | install -d $(DESTDIR)$(LIBDIR)/wpa_supplicant && \ |
| 85 | cp *.so $(DESTDIR)$(LIBDIR)/wpa_supplicant \ |
| 86 | ; fi |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 87 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 88 | ifdef CONFIG_FIPS |
| 89 | CONFIG_NO_RANDOM_POOL= |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 90 | endif |
| 91 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 92 | OBJS = config.o |
| 93 | OBJS += notify.o |
| 94 | OBJS += bss.o |
| 95 | OBJS += eap_register.o |
| 96 | OBJS += ../src/utils/common.o |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 97 | OBJS += ../src/utils/config.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 98 | OBJS += ../src/utils/wpa_debug.o |
| 99 | OBJS += ../src/utils/wpabuf.o |
Dmitry Shmidt | 2933359 | 2017-01-09 12:27:11 -0800 | [diff] [blame] | 100 | OBJS += ../src/utils/bitfield.o |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 101 | OBJS += ../src/utils/ip_addr.o |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 102 | OBJS += ../src/utils/crc32.o |
Dmitry Shmidt | 2933359 | 2017-01-09 12:27:11 -0800 | [diff] [blame] | 103 | OBJS += op_classes.o |
| 104 | OBJS += rrm.o |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 105 | OBJS += twt.o |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 106 | OBJS += robust_av.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 107 | OBJS_p = wpa_passphrase.o |
| 108 | OBJS_p += ../src/utils/common.o |
| 109 | OBJS_p += ../src/utils/wpa_debug.o |
| 110 | OBJS_p += ../src/utils/wpabuf.o |
| 111 | OBJS_c = wpa_cli.o ../src/common/wpa_ctrl.o |
| 112 | OBJS_c += ../src/utils/wpa_debug.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 113 | OBJS_c += ../src/utils/common.o |
Dmitry Shmidt | 7f2c753 | 2016-08-15 09:48:12 -0700 | [diff] [blame] | 114 | OBJS_c += ../src/common/cli.o |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 115 | OBJS += wmm_ac.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 116 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 117 | ifndef CONFIG_OS |
| 118 | ifdef CONFIG_NATIVE_WINDOWS |
| 119 | CONFIG_OS=win32 |
| 120 | else |
| 121 | CONFIG_OS=unix |
| 122 | endif |
| 123 | endif |
| 124 | |
| 125 | ifeq ($(CONFIG_OS), internal) |
| 126 | CFLAGS += -DOS_NO_C_LIB_DEFINES |
| 127 | endif |
| 128 | |
| 129 | OBJS += ../src/utils/os_$(CONFIG_OS).o |
| 130 | OBJS_p += ../src/utils/os_$(CONFIG_OS).o |
| 131 | OBJS_c += ../src/utils/os_$(CONFIG_OS).o |
| 132 | |
| 133 | ifdef CONFIG_WPA_TRACE |
| 134 | CFLAGS += -DWPA_TRACE |
| 135 | OBJS += ../src/utils/trace.o |
| 136 | OBJS_p += ../src/utils/trace.o |
| 137 | OBJS_c += ../src/utils/trace.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 138 | OBJS_priv += ../src/utils/trace.o |
Dmitry Shmidt | 7f65602 | 2015-02-25 14:36:37 -0800 | [diff] [blame] | 139 | LIBCTRL += ../src/utils/trace.o |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 140 | LIBCTRLSO += ../src/utils/trace.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 141 | LDFLAGS += -rdynamic |
| 142 | CFLAGS += -funwind-tables |
| 143 | ifdef CONFIG_WPA_TRACE_BFD |
Dmitry Shmidt | ec58b16 | 2014-02-19 12:44:18 -0800 | [diff] [blame] | 144 | CFLAGS += -DPACKAGE="wpa_supplicant" -DWPA_TRACE_BFD |
Dmitry Shmidt | 13ca8d8 | 2014-02-20 10:18:40 -0800 | [diff] [blame] | 145 | LIBS += -lbfd -ldl -liberty -lz |
| 146 | LIBS_p += -lbfd -ldl -liberty -lz |
| 147 | LIBS_c += -lbfd -ldl -liberty -lz |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 148 | endif |
| 149 | endif |
| 150 | |
| 151 | ifndef CONFIG_ELOOP |
| 152 | CONFIG_ELOOP=eloop |
| 153 | endif |
| 154 | OBJS += ../src/utils/$(CONFIG_ELOOP).o |
| 155 | OBJS_c += ../src/utils/$(CONFIG_ELOOP).o |
| 156 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 157 | ifndef CONFIG_OSX |
Dmitry Shmidt | fa3fc4a | 2013-11-21 13:34:38 -0800 | [diff] [blame] | 158 | ifeq ($(CONFIG_ELOOP), eloop) |
| 159 | # Using glibc < 2.17 requires -lrt for clock_gettime() |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 160 | # OS X has an alternate implementation |
Dmitry Shmidt | fa3fc4a | 2013-11-21 13:34:38 -0800 | [diff] [blame] | 161 | LIBS += -lrt |
| 162 | LIBS_c += -lrt |
| 163 | LIBS_p += -lrt |
| 164 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 165 | endif |
Dmitry Shmidt | fa3fc4a | 2013-11-21 13:34:38 -0800 | [diff] [blame] | 166 | |
Dmitry Shmidt | c5ec7f5 | 2012-03-06 16:33:24 -0800 | [diff] [blame] | 167 | ifdef CONFIG_ELOOP_POLL |
| 168 | CFLAGS += -DCONFIG_ELOOP_POLL |
| 169 | endif |
| 170 | |
Dmitry Shmidt | 50b691d | 2014-05-21 14:01:45 -0700 | [diff] [blame] | 171 | ifdef CONFIG_ELOOP_EPOLL |
| 172 | CFLAGS += -DCONFIG_ELOOP_EPOLL |
| 173 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 174 | |
Dmitry Shmidt | b97e428 | 2016-02-08 10:16:07 -0800 | [diff] [blame] | 175 | ifdef CONFIG_ELOOP_KQUEUE |
| 176 | CFLAGS += -DCONFIG_ELOOP_KQUEUE |
| 177 | endif |
| 178 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 179 | ifdef CONFIG_EAPOL_TEST |
| 180 | CFLAGS += -Werror -DEAPOL_TEST |
| 181 | endif |
| 182 | |
Dmitry Shmidt | 01904cf | 2013-12-05 11:08:35 -0800 | [diff] [blame] | 183 | ifdef CONFIG_CODE_COVERAGE |
| 184 | CFLAGS += -O0 -fprofile-arcs -ftest-coverage |
| 185 | LIBS += -lgcov |
| 186 | LIBS_c += -lgcov |
| 187 | LIBS_p += -lgcov |
| 188 | endif |
| 189 | |
Dmitry Shmidt | c5ec7f5 | 2012-03-06 16:33:24 -0800 | [diff] [blame] | 190 | ifdef CONFIG_HT_OVERRIDES |
| 191 | CFLAGS += -DCONFIG_HT_OVERRIDES |
| 192 | endif |
| 193 | |
Dmitry Shmidt | 2f02319 | 2013-03-12 12:44:17 -0700 | [diff] [blame] | 194 | ifdef CONFIG_VHT_OVERRIDES |
| 195 | CFLAGS += -DCONFIG_VHT_OVERRIDES |
| 196 | endif |
| 197 | |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 198 | ifdef CONFIG_HE_OVERRIDES |
| 199 | CFLAGS += -DCONFIG_HE_OVERRIDES |
| 200 | endif |
| 201 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 202 | ifndef CONFIG_BACKEND |
| 203 | CONFIG_BACKEND=file |
| 204 | endif |
| 205 | |
| 206 | ifeq ($(CONFIG_BACKEND), file) |
| 207 | OBJS += config_file.o |
| 208 | ifndef CONFIG_NO_CONFIG_BLOBS |
| 209 | NEED_BASE64=y |
| 210 | endif |
| 211 | CFLAGS += -DCONFIG_BACKEND_FILE |
| 212 | endif |
| 213 | |
| 214 | ifeq ($(CONFIG_BACKEND), winreg) |
| 215 | OBJS += config_winreg.o |
| 216 | endif |
| 217 | |
| 218 | ifeq ($(CONFIG_BACKEND), none) |
| 219 | OBJS += config_none.o |
| 220 | endif |
| 221 | |
| 222 | ifdef CONFIG_NO_CONFIG_WRITE |
| 223 | CFLAGS += -DCONFIG_NO_CONFIG_WRITE |
| 224 | endif |
| 225 | |
| 226 | ifdef CONFIG_NO_CONFIG_BLOBS |
| 227 | CFLAGS += -DCONFIG_NO_CONFIG_BLOBS |
| 228 | endif |
| 229 | |
| 230 | ifdef CONFIG_NO_SCAN_PROCESSING |
| 231 | CFLAGS += -DCONFIG_NO_SCAN_PROCESSING |
| 232 | endif |
| 233 | |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 234 | ifdef CONFIG_SUITEB |
| 235 | CFLAGS += -DCONFIG_SUITEB |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 236 | endif |
| 237 | |
Dmitry Shmidt | 807291d | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 238 | ifdef CONFIG_SUITEB192 |
| 239 | CFLAGS += -DCONFIG_SUITEB192 |
| 240 | NEED_SHA384=y |
| 241 | endif |
| 242 | |
Hai Shalom | 74f70d4 | 2019-02-11 14:42:39 -0800 | [diff] [blame] | 243 | ifdef CONFIG_OCV |
| 244 | CFLAGS += -DCONFIG_OCV |
| 245 | OBJS += ../src/common/ocv.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 246 | endif |
| 247 | |
| 248 | ifdef CONFIG_IEEE80211R |
| 249 | CFLAGS += -DCONFIG_IEEE80211R |
| 250 | OBJS += ../src/rsn_supp/wpa_ft.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 251 | endif |
| 252 | |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 253 | ifdef CONFIG_MESH |
| 254 | NEED_80211_COMMON=y |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 255 | NEED_AES_SIV=y |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 256 | CONFIG_SAE=y |
| 257 | CONFIG_AP=y |
| 258 | CFLAGS += -DCONFIG_MESH |
| 259 | OBJS += mesh.o |
| 260 | OBJS += mesh_mpm.o |
| 261 | OBJS += mesh_rsn.o |
| 262 | endif |
| 263 | |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 264 | ifdef CONFIG_SAE |
| 265 | CFLAGS += -DCONFIG_SAE |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 266 | OBJS += ../src/common/sae.o |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 267 | ifdef CONFIG_SAE_PK |
| 268 | CFLAGS += -DCONFIG_SAE_PK |
Sunil | 8cd6f4d | 2022-06-28 18:40:46 +0000 | [diff] [blame^] | 269 | NEED_AES_SIV=y |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 270 | OBJS += ../src/common/sae_pk.o |
| 271 | endif |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 272 | NEED_ECC=y |
| 273 | NEED_DH_GROUPS=y |
Hai Shalom | b755a2a | 2020-04-23 21:49:02 -0700 | [diff] [blame] | 274 | NEED_HMAC_SHA256_KDF=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 275 | NEED_DRAGONFLY=y |
Ahmed ElArabawy | 0ff61c5 | 2019-12-26 12:38:39 -0800 | [diff] [blame] | 276 | ifdef CONFIG_TESTING_OPTIONS |
| 277 | NEED_DH_GROUPS_ALL=y |
| 278 | endif |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 279 | endif |
| 280 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 281 | ifdef CONFIG_DPP |
| 282 | CFLAGS += -DCONFIG_DPP |
| 283 | OBJS += ../src/common/dpp.o |
Hai Shalom | 4fbc08f | 2020-05-18 12:37:00 -0700 | [diff] [blame] | 284 | OBJS += ../src/common/dpp_auth.o |
| 285 | OBJS += ../src/common/dpp_backup.o |
| 286 | OBJS += ../src/common/dpp_crypto.o |
| 287 | OBJS += ../src/common/dpp_pkex.o |
| 288 | OBJS += ../src/common/dpp_reconfig.o |
| 289 | OBJS += ../src/common/dpp_tcp.o |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 290 | OBJS += dpp_supplicant.o |
| 291 | NEED_AES_SIV=y |
| 292 | NEED_HMAC_SHA256_KDF=y |
| 293 | NEED_HMAC_SHA384_KDF=y |
| 294 | NEED_HMAC_SHA512_KDF=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 295 | NEED_SHA384=y |
| 296 | NEED_SHA512=y |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 297 | NEED_ECC=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 298 | NEED_JSON=y |
| 299 | NEED_GAS_SERVER=y |
| 300 | NEED_BASE64=y |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 301 | NEED_ASN1=y |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 302 | ifdef CONFIG_DPP2 |
| 303 | CFLAGS += -DCONFIG_DPP2 |
| 304 | endif |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 305 | ifdef CONFIG_DPP3 |
| 306 | CFLAGS += -DCONFIG_DPP3 |
| 307 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 308 | endif |
| 309 | |
| 310 | ifdef CONFIG_OWE |
| 311 | CFLAGS += -DCONFIG_OWE |
| 312 | NEED_ECC=y |
| 313 | NEED_HMAC_SHA256_KDF=y |
| 314 | NEED_HMAC_SHA384_KDF=y |
| 315 | NEED_HMAC_SHA512_KDF=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 316 | NEED_SHA384=y |
| 317 | NEED_SHA512=y |
| 318 | endif |
| 319 | |
Jimmy Chen | caaac07 | 2019-09-16 16:36:06 +0800 | [diff] [blame] | 320 | ifdef CONFIG_WAPI_INTERFACE |
| 321 | L_CFLAGS += -DCONFIG_WAPI_INTERFACE |
| 322 | endif |
| 323 | |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 324 | ifdef CONFIG_FILS |
| 325 | CFLAGS += -DCONFIG_FILS |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 326 | NEED_SHA384=y |
| 327 | NEED_AES_SIV=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 328 | ifdef CONFIG_FILS_SK_PFS |
| 329 | CFLAGS += -DCONFIG_FILS_SK_PFS |
| 330 | NEED_ECC=y |
| 331 | endif |
| 332 | endif |
| 333 | |
| 334 | ifdef CONFIG_MBO |
| 335 | CONFIG_WNM=y |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 336 | endif |
| 337 | |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 338 | ifdef CONFIG_WNM |
| 339 | CFLAGS += -DCONFIG_WNM |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 340 | OBJS += wnm_sta.o |
| 341 | endif |
| 342 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 343 | ifdef CONFIG_TDLS |
| 344 | CFLAGS += -DCONFIG_TDLS |
| 345 | OBJS += ../src/rsn_supp/tdls.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 346 | endif |
| 347 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 348 | ifdef CONFIG_TDLS_TESTING |
| 349 | CFLAGS += -DCONFIG_TDLS_TESTING |
| 350 | endif |
| 351 | |
Dmitry Shmidt | 2933359 | 2017-01-09 12:27:11 -0800 | [diff] [blame] | 352 | ifdef CONFIG_PMKSA_CACHE_EXTERNAL |
| 353 | CFLAGS += -DCONFIG_PMKSA_CACHE_EXTERNAL |
| 354 | endif |
| 355 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 356 | ifndef CONFIG_NO_WPA |
| 357 | OBJS += ../src/rsn_supp/wpa.o |
| 358 | OBJS += ../src/rsn_supp/preauth.o |
| 359 | OBJS += ../src/rsn_supp/pmksa_cache.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 360 | OBJS += ../src/rsn_supp/wpa_ie.o |
| 361 | OBJS += ../src/common/wpa_common.o |
| 362 | NEED_AES=y |
| 363 | NEED_SHA1=y |
| 364 | NEED_MD5=y |
| 365 | NEED_RC4=y |
| 366 | else |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 367 | CFLAGS += -DCONFIG_NO_WPA |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 368 | ifeq ($(CONFIG_TLS), internal) |
| 369 | NEED_SHA1=y |
| 370 | NEED_MD5=y |
| 371 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 372 | endif |
| 373 | |
| 374 | ifdef CONFIG_IBSS_RSN |
| 375 | NEED_RSN_AUTHENTICATOR=y |
| 376 | CFLAGS += -DCONFIG_IBSS_RSN |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 377 | CFLAGS += -DCONFIG_NO_VLAN |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 378 | OBJS += ibss_rsn.o |
| 379 | endif |
| 380 | |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 381 | ifdef CONFIG_MATCH_IFACE |
| 382 | CFLAGS += -DCONFIG_MATCH_IFACE |
| 383 | endif |
| 384 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 385 | ifdef CONFIG_P2P |
| 386 | OBJS += p2p_supplicant.o |
Dmitry Shmidt | f73259c | 2015-03-17 11:00:54 -0700 | [diff] [blame] | 387 | OBJS += p2p_supplicant_sd.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 388 | OBJS += ../src/p2p/p2p.o |
| 389 | OBJS += ../src/p2p/p2p_utils.o |
| 390 | OBJS += ../src/p2p/p2p_parse.o |
| 391 | OBJS += ../src/p2p/p2p_build.o |
| 392 | OBJS += ../src/p2p/p2p_go_neg.o |
| 393 | OBJS += ../src/p2p/p2p_sd.o |
| 394 | OBJS += ../src/p2p/p2p_pd.o |
| 395 | OBJS += ../src/p2p/p2p_invitation.o |
| 396 | OBJS += ../src/p2p/p2p_dev_disc.o |
| 397 | OBJS += ../src/p2p/p2p_group.o |
| 398 | OBJS += ../src/ap/p2p_hostapd.o |
| 399 | CFLAGS += -DCONFIG_P2P |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 400 | NEED_GAS=y |
| 401 | NEED_OFFCHANNEL=y |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 402 | CONFIG_WPS=y |
| 403 | CONFIG_AP=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 404 | ifdef CONFIG_P2P_STRICT |
| 405 | CFLAGS += -DCONFIG_P2P_STRICT |
| 406 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 407 | ifdef CONFIG_WIFI_DISPLAY |
| 408 | CFLAGS += -DCONFIG_WIFI_DISPLAY |
| 409 | OBJS += wifi_display.o |
| 410 | endif |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 411 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 412 | |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 413 | ifdef CONFIG_PASN |
| 414 | CFLAGS += -DCONFIG_PASN |
| 415 | CFLAGS += -DCONFIG_PTKSA_CACHE |
| 416 | NEED_HMAC_SHA256_KDF=y |
| 417 | NEED_HMAC_SHA384_KDF=y |
| 418 | NEED_SHA256=y |
| 419 | NEED_SHA384=y |
| 420 | OBJS += ../src/common/ptksa_cache.o |
| 421 | OBJS += pasn_supplicant.o |
| 422 | endif |
| 423 | |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 424 | ifdef CONFIG_HS20 |
| 425 | OBJS += hs20_supplicant.o |
| 426 | CFLAGS += -DCONFIG_HS20 |
| 427 | CONFIG_INTERWORKING=y |
| 428 | endif |
| 429 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 430 | ifdef CONFIG_INTERWORKING |
| 431 | OBJS += interworking.o |
| 432 | CFLAGS += -DCONFIG_INTERWORKING |
| 433 | NEED_GAS=y |
| 434 | endif |
| 435 | |
Dmitry Shmidt | 912c6ec | 2015-03-30 13:16:51 -0700 | [diff] [blame] | 436 | ifdef CONFIG_NO_ROAMING |
| 437 | CFLAGS += -DCONFIG_NO_ROAMING |
| 438 | endif |
| 439 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 440 | include ../src/drivers/drivers.mak |
| 441 | ifdef CONFIG_AP |
| 442 | OBJS_d += $(DRV_BOTH_OBJS) |
| 443 | CFLAGS += $(DRV_BOTH_CFLAGS) |
| 444 | LDFLAGS += $(DRV_BOTH_LDFLAGS) |
| 445 | LIBS += $(DRV_BOTH_LIBS) |
| 446 | else |
| 447 | NEED_AP_MLME= |
| 448 | OBJS_d += $(DRV_WPA_OBJS) |
| 449 | CFLAGS += $(DRV_WPA_CFLAGS) |
| 450 | LDFLAGS += $(DRV_WPA_LDFLAGS) |
| 451 | LIBS += $(DRV_WPA_LIBS) |
| 452 | endif |
| 453 | |
| 454 | ifndef CONFIG_L2_PACKET |
| 455 | CONFIG_L2_PACKET=linux |
| 456 | endif |
| 457 | |
| 458 | OBJS_l2 += ../src/l2_packet/l2_packet_$(CONFIG_L2_PACKET).o |
| 459 | |
| 460 | ifeq ($(CONFIG_L2_PACKET), pcap) |
| 461 | ifdef CONFIG_WINPCAP |
| 462 | CFLAGS += -DCONFIG_WINPCAP |
| 463 | LIBS += -lwpcap -lpacket |
| 464 | LIBS_w += -lwpcap |
| 465 | else |
| 466 | LIBS += -ldnet -lpcap |
| 467 | endif |
| 468 | endif |
| 469 | |
| 470 | ifeq ($(CONFIG_L2_PACKET), winpcap) |
| 471 | LIBS += -lwpcap -lpacket |
| 472 | LIBS_w += -lwpcap |
| 473 | endif |
| 474 | |
| 475 | ifeq ($(CONFIG_L2_PACKET), freebsd) |
| 476 | LIBS += -lpcap |
| 477 | endif |
| 478 | |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 479 | ifdef CONFIG_ERP |
| 480 | CFLAGS += -DCONFIG_ERP |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 481 | NEED_HMAC_SHA256_KDF=y |
| 482 | endif |
| 483 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 484 | ifdef CONFIG_EAP_TLS |
| 485 | # EAP-TLS |
| 486 | ifeq ($(CONFIG_EAP_TLS), dyn) |
| 487 | CFLAGS += -DEAP_TLS_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 488 | EAPDYN += eap_tls.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 489 | else |
| 490 | CFLAGS += -DEAP_TLS |
| 491 | OBJS += ../src/eap_peer/eap_tls.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 492 | endif |
| 493 | TLS_FUNCS=y |
| 494 | CONFIG_IEEE8021X_EAPOL=y |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 495 | ifdef CONFIG_EAP_TLSV1_3 |
| 496 | CFLAGS += -DEAP_TLSV1_3 |
| 497 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 498 | endif |
| 499 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 500 | ifdef CONFIG_EAP_UNAUTH_TLS |
| 501 | # EAP-UNAUTH-TLS |
| 502 | CFLAGS += -DEAP_UNAUTH_TLS |
Dmitry Shmidt | dda10c2 | 2015-03-24 16:05:01 -0700 | [diff] [blame] | 503 | ifndef CONFIG_EAP_TLS |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 504 | OBJS += ../src/eap_peer/eap_tls.o |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 505 | TLS_FUNCS=y |
| 506 | endif |
| 507 | CONFIG_IEEE8021X_EAPOL=y |
| 508 | endif |
| 509 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 510 | ifdef CONFIG_EAP_PEAP |
| 511 | # EAP-PEAP |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 512 | SRC_EAP_PEAP = ../src/eap_peer/eap_peap.c ../src/eap_common/eap_peap_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 513 | ifeq ($(CONFIG_EAP_PEAP), dyn) |
| 514 | CFLAGS += -DEAP_PEAP_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 515 | EAPDYN += eap_peap.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 516 | else |
| 517 | CFLAGS += -DEAP_PEAP |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 518 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_PEAP)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 519 | endif |
| 520 | TLS_FUNCS=y |
| 521 | CONFIG_IEEE8021X_EAPOL=y |
| 522 | endif |
| 523 | |
| 524 | ifdef CONFIG_EAP_TTLS |
| 525 | # EAP-TTLS |
| 526 | ifeq ($(CONFIG_EAP_TTLS), dyn) |
| 527 | CFLAGS += -DEAP_TTLS_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 528 | EAPDYN += eap_ttls.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 529 | else |
| 530 | CFLAGS += -DEAP_TTLS |
| 531 | OBJS += ../src/eap_peer/eap_ttls.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 532 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 533 | TLS_FUNCS=y |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 534 | ifndef CONFIG_FIPS |
| 535 | MS_FUNCS=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 536 | CHAP=y |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 537 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 538 | CONFIG_IEEE8021X_EAPOL=y |
| 539 | endif |
| 540 | |
| 541 | ifdef CONFIG_EAP_MD5 |
| 542 | # EAP-MD5 |
| 543 | ifeq ($(CONFIG_EAP_MD5), dyn) |
| 544 | CFLAGS += -DEAP_MD5_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 545 | EAPDYN += eap_md5.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 546 | else |
| 547 | CFLAGS += -DEAP_MD5 |
| 548 | OBJS += ../src/eap_peer/eap_md5.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 549 | endif |
| 550 | CHAP=y |
| 551 | CONFIG_IEEE8021X_EAPOL=y |
| 552 | endif |
| 553 | |
| 554 | # backwards compatibility for old spelling |
| 555 | ifdef CONFIG_MSCHAPV2 |
| 556 | ifndef CONFIG_EAP_MSCHAPV2 |
| 557 | CONFIG_EAP_MSCHAPV2=y |
| 558 | endif |
| 559 | endif |
| 560 | |
| 561 | ifdef CONFIG_EAP_MSCHAPV2 |
| 562 | # EAP-MSCHAPv2 |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 563 | SRC_EAP_MSCHAPV2 = ../src/eap_peer/eap_mschapv2.c ../src/eap_peer/mschapv2.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 564 | ifeq ($(CONFIG_EAP_MSCHAPV2), dyn) |
| 565 | CFLAGS += -DEAP_MSCHAPv2_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 566 | EAPDYN += eap_mschapv2.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 567 | else |
| 568 | CFLAGS += -DEAP_MSCHAPv2 |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 569 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_MSCHAPV2)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 570 | endif |
| 571 | MS_FUNCS=y |
| 572 | CONFIG_IEEE8021X_EAPOL=y |
| 573 | endif |
| 574 | |
| 575 | ifdef CONFIG_EAP_GTC |
| 576 | # EAP-GTC |
| 577 | ifeq ($(CONFIG_EAP_GTC), dyn) |
| 578 | CFLAGS += -DEAP_GTC_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 579 | EAPDYN += eap_gtc.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 580 | else |
| 581 | CFLAGS += -DEAP_GTC |
| 582 | OBJS += ../src/eap_peer/eap_gtc.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 583 | endif |
| 584 | CONFIG_IEEE8021X_EAPOL=y |
| 585 | endif |
| 586 | |
| 587 | ifdef CONFIG_EAP_OTP |
| 588 | # EAP-OTP |
| 589 | ifeq ($(CONFIG_EAP_OTP), dyn) |
| 590 | CFLAGS += -DEAP_OTP_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 591 | EAPDYN += eap_otp.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 592 | else |
| 593 | CFLAGS += -DEAP_OTP |
| 594 | OBJS += ../src/eap_peer/eap_otp.o |
| 595 | endif |
| 596 | CONFIG_IEEE8021X_EAPOL=y |
| 597 | endif |
| 598 | |
| 599 | ifdef CONFIG_EAP_SIM |
| 600 | # EAP-SIM |
| 601 | ifeq ($(CONFIG_EAP_SIM), dyn) |
| 602 | CFLAGS += -DEAP_SIM_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 603 | EAPDYN += eap_sim.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 604 | else |
| 605 | CFLAGS += -DEAP_SIM |
| 606 | OBJS += ../src/eap_peer/eap_sim.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 607 | endif |
| 608 | CONFIG_IEEE8021X_EAPOL=y |
| 609 | CONFIG_EAP_SIM_COMMON=y |
| 610 | NEED_AES_CBC=y |
| 611 | endif |
| 612 | |
| 613 | ifdef CONFIG_EAP_LEAP |
| 614 | # EAP-LEAP |
| 615 | ifeq ($(CONFIG_EAP_LEAP), dyn) |
| 616 | CFLAGS += -DEAP_LEAP_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 617 | EAPDYN += eap_leap.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 618 | else |
| 619 | CFLAGS += -DEAP_LEAP |
| 620 | OBJS += ../src/eap_peer/eap_leap.o |
| 621 | endif |
| 622 | MS_FUNCS=y |
| 623 | CONFIG_IEEE8021X_EAPOL=y |
| 624 | endif |
| 625 | |
| 626 | ifdef CONFIG_EAP_PSK |
| 627 | # EAP-PSK |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 628 | SRC_EAP_PSK = ../src/eap_peer/eap_psk.c ../src/eap_common/eap_psk_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 629 | ifeq ($(CONFIG_EAP_PSK), dyn) |
| 630 | CFLAGS += -DEAP_PSK_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 631 | EAPDYN += eap_psk.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 632 | else |
| 633 | CFLAGS += -DEAP_PSK |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 634 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_PSK)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 635 | endif |
| 636 | CONFIG_IEEE8021X_EAPOL=y |
| 637 | NEED_AES=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 638 | NEED_AES_ENCBLOCK=y |
| 639 | NEED_AES_EAX=y |
| 640 | endif |
| 641 | |
| 642 | ifdef CONFIG_EAP_AKA |
| 643 | # EAP-AKA |
| 644 | ifeq ($(CONFIG_EAP_AKA), dyn) |
| 645 | CFLAGS += -DEAP_AKA_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 646 | EAPDYN += eap_aka.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 647 | else |
| 648 | CFLAGS += -DEAP_AKA |
| 649 | OBJS += ../src/eap_peer/eap_aka.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 650 | endif |
| 651 | CONFIG_IEEE8021X_EAPOL=y |
| 652 | CONFIG_EAP_SIM_COMMON=y |
| 653 | NEED_AES_CBC=y |
| 654 | endif |
| 655 | |
Dmitry Shmidt | f862328 | 2013-02-20 14:34:59 -0800 | [diff] [blame] | 656 | ifdef CONFIG_EAP_PROXY |
| 657 | CFLAGS += -DCONFIG_EAP_PROXY |
| 658 | OBJS += ../src/eap_peer/eap_proxy_$(CONFIG_EAP_PROXY).o |
Dmitry Shmidt | 61593f0 | 2014-04-21 16:27:35 -0700 | [diff] [blame] | 659 | include eap_proxy_$(CONFIG_EAP_PROXY).mak |
Dmitry Shmidt | f862328 | 2013-02-20 14:34:59 -0800 | [diff] [blame] | 660 | CONFIG_IEEE8021X_EAPOL=y |
| 661 | endif |
| 662 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 663 | ifdef CONFIG_EAP_AKA_PRIME |
| 664 | # EAP-AKA' |
| 665 | ifeq ($(CONFIG_EAP_AKA_PRIME), dyn) |
| 666 | CFLAGS += -DEAP_AKA_PRIME_DYNAMIC |
| 667 | else |
| 668 | CFLAGS += -DEAP_AKA_PRIME |
| 669 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 670 | endif |
| 671 | |
| 672 | ifdef CONFIG_EAP_SIM_COMMON |
| 673 | OBJS += ../src/eap_common/eap_sim_common.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 674 | NEED_AES=y |
| 675 | NEED_FIPS186_2_PRF=y |
| 676 | endif |
| 677 | |
| 678 | ifdef CONFIG_EAP_FAST |
| 679 | # EAP-FAST |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 680 | SRC_EAP_FAST = ../src/eap_peer/eap_fast.c ../src/eap_peer/eap_fast_pac.c |
| 681 | SRC_EAP_FAST += ../src/eap_common/eap_fast_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 682 | ifeq ($(CONFIG_EAP_FAST), dyn) |
| 683 | CFLAGS += -DEAP_FAST_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 684 | EAPDYN += eap_fast.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 685 | else |
| 686 | CFLAGS += -DEAP_FAST |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 687 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_FAST)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 688 | endif |
| 689 | TLS_FUNCS=y |
| 690 | CONFIG_IEEE8021X_EAPOL=y |
| 691 | NEED_T_PRF=y |
| 692 | endif |
| 693 | |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 694 | ifdef CONFIG_EAP_TEAP |
| 695 | # EAP-TEAP |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 696 | SRC_EAP_TEAP = ../src/eap_peer/eap_teap.c ../src/eap_peer/eap_teap_pac.c |
| 697 | SRC_EAP_TEAP += ../src/eap_common/eap_teap_common.c |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 698 | ifeq ($(CONFIG_EAP_TEAP), dyn) |
| 699 | CFLAGS += -DEAP_TEAP_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 700 | EAPDYN += eap_teap.so |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 701 | else |
| 702 | CFLAGS += -DEAP_TEAP |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 703 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_TEAP)) |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 704 | endif |
| 705 | TLS_FUNCS=y |
| 706 | CONFIG_IEEE8021X_EAPOL=y |
| 707 | NEED_T_PRF=y |
| 708 | NEED_SHA384=y |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 709 | NEED_TLS_PRF_SHA256=y |
| 710 | NEED_TLS_PRF_SHA384=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 711 | endif |
| 712 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 713 | ifdef CONFIG_EAP_PAX |
| 714 | # EAP-PAX |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 715 | SRC_EAP_PAX = ../src/eap_peer/eap_pax.c ../src/eap_common/eap_pax_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 716 | ifeq ($(CONFIG_EAP_PAX), dyn) |
| 717 | CFLAGS += -DEAP_PAX_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 718 | EAPDYN += eap_pax.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 719 | else |
| 720 | CFLAGS += -DEAP_PAX |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 721 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_PAX)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 722 | endif |
| 723 | CONFIG_IEEE8021X_EAPOL=y |
| 724 | endif |
| 725 | |
| 726 | ifdef CONFIG_EAP_SAKE |
| 727 | # EAP-SAKE |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 728 | SRC_EAP_SAKE = ../src/eap_peer/eap_sake.c ../src/eap_common/eap_sake_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 729 | ifeq ($(CONFIG_EAP_SAKE), dyn) |
| 730 | CFLAGS += -DEAP_SAKE_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 731 | EAPDYN += eap_sake.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 732 | else |
| 733 | CFLAGS += -DEAP_SAKE |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 734 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_SAKE)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 735 | endif |
| 736 | CONFIG_IEEE8021X_EAPOL=y |
| 737 | endif |
| 738 | |
| 739 | ifdef CONFIG_EAP_GPSK |
| 740 | # EAP-GPSK |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 741 | SRC_EAP_GPSK = ../src/eap_peer/eap_gpsk.c ../src/eap_common/eap_gpsk_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 742 | ifeq ($(CONFIG_EAP_GPSK), dyn) |
| 743 | CFLAGS += -DEAP_GPSK_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 744 | EAPDYN += eap_gpsk.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 745 | else |
| 746 | CFLAGS += -DEAP_GPSK |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 747 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_GPSK)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 748 | endif |
| 749 | CONFIG_IEEE8021X_EAPOL=y |
| 750 | ifdef CONFIG_EAP_GPSK_SHA256 |
| 751 | CFLAGS += -DEAP_GPSK_SHA256 |
| 752 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 753 | endif |
| 754 | |
| 755 | ifdef CONFIG_EAP_PWD |
| 756 | CFLAGS += -DEAP_PWD |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 757 | ifeq ($(CONFIG_TLS), wolfssl) |
| 758 | CFLAGS += -DCONFIG_ECC |
| 759 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 760 | OBJS += ../src/eap_peer/eap_pwd.o ../src/eap_common/eap_pwd_common.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 761 | CONFIG_IEEE8021X_EAPOL=y |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 762 | NEED_ECC=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 763 | NEED_DRAGONFLY=y |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 764 | MS_FUNCS=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 765 | endif |
| 766 | |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 767 | ifdef CONFIG_EAP_EKE |
| 768 | # EAP-EKE |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 769 | SRC_EAP_EKE = ../src/eap_peer/eap_eke.c ../src/eap_common/eap_eke_common.c |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 770 | ifeq ($(CONFIG_EAP_EKE), dyn) |
| 771 | CFLAGS += -DEAP_EKE_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 772 | EAPDYN += eap_eke.so |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 773 | else |
| 774 | CFLAGS += -DEAP_EKE |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 775 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_EKE)) |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 776 | endif |
| 777 | CONFIG_IEEE8021X_EAPOL=y |
| 778 | NEED_DH_GROUPS=y |
| 779 | NEED_DH_GROUPS_ALL=y |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 780 | NEED_AES_CBC=y |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 781 | endif |
| 782 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 783 | ifdef CONFIG_WPS |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 784 | # EAP-WSC |
| 785 | CFLAGS += -DCONFIG_WPS -DEAP_WSC |
| 786 | OBJS += wps_supplicant.o |
| 787 | OBJS += ../src/utils/uuid.o |
| 788 | OBJS += ../src/eap_peer/eap_wsc.o ../src/eap_common/eap_wsc_common.o |
| 789 | OBJS += ../src/wps/wps.o |
| 790 | OBJS += ../src/wps/wps_common.o |
| 791 | OBJS += ../src/wps/wps_attr_parse.o |
| 792 | OBJS += ../src/wps/wps_attr_build.o |
| 793 | OBJS += ../src/wps/wps_attr_process.o |
| 794 | OBJS += ../src/wps/wps_dev_attr.o |
| 795 | OBJS += ../src/wps/wps_enrollee.o |
| 796 | OBJS += ../src/wps/wps_registrar.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 797 | CONFIG_IEEE8021X_EAPOL=y |
| 798 | NEED_DH_GROUPS=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 799 | NEED_BASE64=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 800 | NEED_AES_CBC=y |
| 801 | NEED_MODEXP=y |
| 802 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 803 | ifdef CONFIG_WPS_NFC |
| 804 | CFLAGS += -DCONFIG_WPS_NFC |
| 805 | OBJS += ../src/wps/ndef.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 806 | NEED_WPS_OOB=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 807 | endif |
| 808 | |
| 809 | ifdef NEED_WPS_OOB |
| 810 | CFLAGS += -DCONFIG_WPS_OOB |
| 811 | endif |
| 812 | |
| 813 | ifdef CONFIG_WPS_ER |
| 814 | CONFIG_WPS_UPNP=y |
| 815 | CFLAGS += -DCONFIG_WPS_ER |
| 816 | OBJS += ../src/wps/wps_er.o |
| 817 | OBJS += ../src/wps/wps_er_ssdp.o |
| 818 | endif |
| 819 | |
| 820 | ifdef CONFIG_WPS_UPNP |
| 821 | CFLAGS += -DCONFIG_WPS_UPNP |
| 822 | OBJS += ../src/wps/wps_upnp.o |
| 823 | OBJS += ../src/wps/wps_upnp_ssdp.o |
| 824 | OBJS += ../src/wps/wps_upnp_web.o |
| 825 | OBJS += ../src/wps/wps_upnp_event.o |
| 826 | OBJS += ../src/wps/wps_upnp_ap.o |
| 827 | OBJS += ../src/wps/upnp_xml.o |
| 828 | OBJS += ../src/wps/httpread.o |
| 829 | OBJS += ../src/wps/http_client.o |
| 830 | OBJS += ../src/wps/http_server.o |
| 831 | endif |
| 832 | |
| 833 | ifdef CONFIG_WPS_STRICT |
| 834 | CFLAGS += -DCONFIG_WPS_STRICT |
| 835 | OBJS += ../src/wps/wps_validate.o |
| 836 | endif |
| 837 | |
| 838 | ifdef CONFIG_WPS_TESTING |
| 839 | CFLAGS += -DCONFIG_WPS_TESTING |
| 840 | endif |
| 841 | |
| 842 | ifdef CONFIG_WPS_REG_DISABLE_OPEN |
| 843 | CFLAGS += -DCONFIG_WPS_REG_DISABLE_OPEN |
| 844 | endif |
| 845 | |
| 846 | endif |
| 847 | |
| 848 | ifdef CONFIG_EAP_IKEV2 |
| 849 | # EAP-IKEv2 |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 850 | SRC_EAP_IKEV2 = ../src/eap_peer/eap_ikev2.c |
| 851 | SRC_EAP_IKEV2 += ../src/eap_peer/ikev2.c |
| 852 | SRC_EAP_IKEV2 += ../src/eap_common/eap_ikev2_common.c |
| 853 | SRC_EAP_IKEV2 += ../src/eap_common/ikev2_common.c |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 854 | ifeq ($(CONFIG_EAP_IKEV2), dyn) |
| 855 | CFLAGS += -DEAP_IKEV2_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 856 | EAPDYN += eap_ikev2.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 857 | else |
| 858 | CFLAGS += -DEAP_IKEV2 |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 859 | OBJS += $(patsubst %.c, %.o, $(SRC_EAP_IKEV2)) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 860 | endif |
| 861 | CONFIG_IEEE8021X_EAPOL=y |
| 862 | NEED_DH_GROUPS=y |
| 863 | NEED_DH_GROUPS_ALL=y |
| 864 | NEED_MODEXP=y |
| 865 | NEED_CIPHER=y |
| 866 | endif |
| 867 | |
| 868 | ifdef CONFIG_EAP_VENDOR_TEST |
| 869 | ifeq ($(CONFIG_EAP_VENDOR_TEST), dyn) |
| 870 | CFLAGS += -DEAP_VENDOR_TEST_DYNAMIC |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 871 | EAPDYN += eap_vendor_test.so |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 872 | else |
| 873 | CFLAGS += -DEAP_VENDOR_TEST |
| 874 | OBJS += ../src/eap_peer/eap_vendor_test.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 875 | endif |
| 876 | CONFIG_IEEE8021X_EAPOL=y |
| 877 | endif |
| 878 | |
| 879 | ifdef CONFIG_EAP_TNC |
| 880 | # EAP-TNC |
| 881 | CFLAGS += -DEAP_TNC |
| 882 | OBJS += ../src/eap_peer/eap_tnc.o |
| 883 | OBJS += ../src/eap_peer/tncc.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 884 | NEED_BASE64=y |
| 885 | ifndef CONFIG_NATIVE_WINDOWS |
| 886 | ifndef CONFIG_DRIVER_BSD |
| 887 | LIBS += -ldl |
| 888 | endif |
| 889 | endif |
| 890 | endif |
| 891 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 892 | ifdef CONFIG_MACSEC |
| 893 | CFLAGS += -DCONFIG_MACSEC |
| 894 | CONFIG_IEEE8021X_EAPOL=y |
| 895 | NEED_AES_ENCBLOCK=y |
| 896 | NEED_AES_UNWRAP=y |
| 897 | NEED_AES_WRAP=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 898 | OBJS += wpas_kay.o |
| 899 | OBJS += ../src/pae/ieee802_1x_cp.o |
| 900 | OBJS += ../src/pae/ieee802_1x_kay.o |
| 901 | OBJS += ../src/pae/ieee802_1x_key.o |
| 902 | OBJS += ../src/pae/ieee802_1x_secy_ops.o |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 903 | ifdef CONFIG_AP |
| 904 | OBJS += ../src/ap/wpa_auth_kay.o |
| 905 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 906 | endif |
| 907 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 908 | ifdef CONFIG_IEEE8021X_EAPOL |
| 909 | # IEEE 802.1X/EAPOL state machines (e.g., for RADIUS authentication) |
| 910 | CFLAGS += -DIEEE8021X_EAPOL |
| 911 | OBJS += ../src/eapol_supp/eapol_supp_sm.o |
| 912 | OBJS += ../src/eap_peer/eap.o ../src/eap_peer/eap_methods.o |
| 913 | NEED_EAP_COMMON=y |
| 914 | ifdef CONFIG_DYNAMIC_EAP_METHODS |
| 915 | CFLAGS += -DCONFIG_DYNAMIC_EAP_METHODS |
| 916 | LIBS += -ldl -rdynamic |
| 917 | endif |
| 918 | endif |
| 919 | |
| 920 | ifdef CONFIG_AP |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 921 | NEED_EAP_COMMON=y |
| 922 | NEED_RSN_AUTHENTICATOR=y |
| 923 | CFLAGS += -DCONFIG_AP |
| 924 | OBJS += ap.o |
| 925 | CFLAGS += -DCONFIG_NO_RADIUS |
| 926 | CFLAGS += -DCONFIG_NO_ACCOUNTING |
| 927 | CFLAGS += -DCONFIG_NO_VLAN |
| 928 | OBJS += ../src/ap/hostapd.o |
| 929 | OBJS += ../src/ap/wpa_auth_glue.o |
| 930 | OBJS += ../src/ap/utils.o |
| 931 | OBJS += ../src/ap/authsrv.o |
| 932 | OBJS += ../src/ap/ap_config.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 933 | OBJS += ../src/ap/sta_info.o |
| 934 | OBJS += ../src/ap/tkip_countermeasures.o |
| 935 | OBJS += ../src/ap/ap_mlme.o |
| 936 | OBJS += ../src/ap/ieee802_1x.o |
| 937 | OBJS += ../src/eapol_auth/eapol_auth_sm.o |
| 938 | OBJS += ../src/ap/ieee802_11_auth.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 939 | OBJS += ../src/ap/ieee802_11_shared.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 940 | OBJS += ../src/ap/drv_callbacks.o |
| 941 | OBJS += ../src/ap/ap_drv_ops.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 942 | OBJS += ../src/ap/beacon.o |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 943 | OBJS += ../src/ap/bss_load.o |
Dmitry Shmidt | d5e4923 | 2012-12-03 15:08:10 -0800 | [diff] [blame] | 944 | OBJS += ../src/ap/eap_user_db.o |
Dmitry Shmidt | 849734c | 2016-05-27 09:59:01 -0700 | [diff] [blame] | 945 | OBJS += ../src/ap/neighbor_db.o |
| 946 | OBJS += ../src/ap/rrm.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 947 | OBJS += ../src/ap/ieee802_11_ht.o |
Dmitry Shmidt | 68d0e3e | 2013-10-28 17:59:21 -0700 | [diff] [blame] | 948 | ifdef CONFIG_IEEE80211AC |
| 949 | OBJS += ../src/ap/ieee802_11_vht.o |
| 950 | endif |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 951 | ifdef CONFIG_IEEE80211AX |
| 952 | OBJS += ../src/ap/ieee802_11_he.o |
| 953 | endif |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 954 | ifdef CONFIG_IEEE80211BE |
| 955 | OBJS += ../src/ap/ieee802_11_eht.o |
| 956 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 957 | ifdef CONFIG_WNM_AP |
| 958 | CFLAGS += -DCONFIG_WNM_AP |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 959 | OBJS += ../src/ap/wnm_ap.o |
| 960 | endif |
Dmitry Shmidt | 57c2d39 | 2016-02-23 13:40:19 -0800 | [diff] [blame] | 961 | ifdef CONFIG_MBO |
| 962 | OBJS += ../src/ap/mbo_ap.o |
| 963 | endif |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 964 | ifdef CONFIG_FILS |
| 965 | OBJS += ../src/ap/fils_hlp.o |
| 966 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 967 | ifdef CONFIG_CTRL_IFACE |
| 968 | OBJS += ../src/ap/ctrl_iface_ap.o |
| 969 | endif |
| 970 | |
| 971 | CFLAGS += -DEAP_SERVER -DEAP_SERVER_IDENTITY |
| 972 | OBJS += ../src/eap_server/eap_server.o |
| 973 | OBJS += ../src/eap_server/eap_server_identity.o |
| 974 | OBJS += ../src/eap_server/eap_server_methods.o |
| 975 | |
Dmitry Shmidt | 68d0e3e | 2013-10-28 17:59:21 -0700 | [diff] [blame] | 976 | ifdef CONFIG_IEEE80211AC |
| 977 | CFLAGS += -DCONFIG_IEEE80211AC |
| 978 | endif |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 979 | ifdef CONFIG_IEEE80211BE |
| 980 | CONFIG_IEEE80211AX=y |
| 981 | CFLAGS += -DCONFIG_IEEE80211BE |
| 982 | endif |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 983 | ifdef CONFIG_IEEE80211AX |
| 984 | CFLAGS += -DCONFIG_IEEE80211AX |
| 985 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 986 | |
| 987 | ifdef NEED_AP_MLME |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 988 | OBJS += ../src/ap/wmm.o |
| 989 | OBJS += ../src/ap/ap_list.o |
| 990 | OBJS += ../src/ap/ieee802_11.o |
| 991 | OBJS += ../src/ap/hw_features.o |
Dmitry Shmidt | 051af73 | 2013-10-22 13:52:46 -0700 | [diff] [blame] | 992 | OBJS += ../src/ap/dfs.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 993 | CFLAGS += -DNEED_AP_MLME |
| 994 | endif |
| 995 | ifdef CONFIG_WPS |
| 996 | CFLAGS += -DEAP_SERVER_WSC |
| 997 | OBJS += ../src/ap/wps_hostapd.o |
| 998 | OBJS += ../src/eap_server/eap_server_wsc.o |
| 999 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1000 | ifdef CONFIG_DPP |
| 1001 | OBJS += ../src/ap/dpp_hostapd.o |
| 1002 | OBJS += ../src/ap/gas_query_ap.o |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 1003 | NEED_AP_GAS_SERV=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1004 | endif |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1005 | ifdef CONFIG_INTERWORKING |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 1006 | NEED_AP_GAS_SERV=y |
| 1007 | endif |
| 1008 | ifdef NEED_AP_GAS_SERV |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1009 | OBJS += ../src/ap/gas_serv.o |
| 1010 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1011 | ifdef CONFIG_HS20 |
| 1012 | OBJS += ../src/ap/hs20.o |
| 1013 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1014 | endif |
| 1015 | |
Dmitry Shmidt | 9839ecd | 2016-11-07 11:05:47 -0800 | [diff] [blame] | 1016 | ifdef CONFIG_MBO |
| 1017 | OBJS += mbo.o |
| 1018 | CFLAGS += -DCONFIG_MBO |
| 1019 | endif |
| 1020 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1021 | ifdef NEED_RSN_AUTHENTICATOR |
| 1022 | CFLAGS += -DCONFIG_NO_RADIUS |
| 1023 | NEED_AES_WRAP=y |
| 1024 | OBJS += ../src/ap/wpa_auth.o |
| 1025 | OBJS += ../src/ap/wpa_auth_ie.o |
| 1026 | OBJS += ../src/ap/pmksa_cache_auth.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1027 | endif |
| 1028 | |
Dmitry Shmidt | 014a3ff | 2015-12-28 13:27:49 -0800 | [diff] [blame] | 1029 | ifdef CONFIG_ACS |
| 1030 | CFLAGS += -DCONFIG_ACS |
| 1031 | OBJS += ../src/ap/acs.o |
| 1032 | LIBS += -lm |
| 1033 | endif |
| 1034 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1035 | ifdef CONFIG_PCSC |
| 1036 | # PC/SC interface for smartcards (USIM, GSM SIM) |
| 1037 | CFLAGS += -DPCSC_FUNCS -I/usr/include/PCSC |
| 1038 | OBJS += ../src/utils/pcsc_funcs.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1039 | ifdef CONFIG_NATIVE_WINDOWS |
| 1040 | #Once MinGW gets support for WinScard, -lwinscard could be used instead of the |
| 1041 | #dynamic symbol loading that is now used in pcsc_funcs.c |
| 1042 | #LIBS += -lwinscard |
| 1043 | else |
Dmitry Shmidt | 7f2c753 | 2016-08-15 09:48:12 -0700 | [diff] [blame] | 1044 | ifdef CONFIG_OSX |
| 1045 | LIBS += -framework PCSC |
| 1046 | else |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 1047 | LIBS += $(shell $(PKG_CONFIG) --libs libpcsclite) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1048 | endif |
| 1049 | endif |
Dmitry Shmidt | 7f2c753 | 2016-08-15 09:48:12 -0700 | [diff] [blame] | 1050 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1051 | |
| 1052 | ifdef CONFIG_SIM_SIMULATOR |
| 1053 | CFLAGS += -DCONFIG_SIM_SIMULATOR |
| 1054 | NEED_MILENAGE=y |
| 1055 | endif |
| 1056 | |
| 1057 | ifdef CONFIG_USIM_SIMULATOR |
| 1058 | CFLAGS += -DCONFIG_USIM_SIMULATOR |
| 1059 | NEED_MILENAGE=y |
| 1060 | endif |
| 1061 | |
| 1062 | ifdef NEED_MILENAGE |
| 1063 | OBJS += ../src/crypto/milenage.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1064 | NEED_AES_ENCBLOCK=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1065 | endif |
| 1066 | |
| 1067 | ifdef CONFIG_PKCS12 |
| 1068 | CFLAGS += -DPKCS12_FUNCS |
| 1069 | endif |
| 1070 | |
| 1071 | ifdef CONFIG_SMARTCARD |
| 1072 | CFLAGS += -DCONFIG_SMARTCARD |
| 1073 | endif |
| 1074 | |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 1075 | ifdef NEED_DRAGONFLY |
| 1076 | OBJS += ../src/common/dragonfly.o |
| 1077 | endif |
| 1078 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1079 | ifdef MS_FUNCS |
| 1080 | OBJS += ../src/crypto/ms_funcs.o |
| 1081 | NEED_DES=y |
| 1082 | NEED_MD4=y |
| 1083 | endif |
| 1084 | |
| 1085 | ifdef CHAP |
| 1086 | OBJS += ../src/eap_common/chap.o |
| 1087 | endif |
| 1088 | |
| 1089 | ifdef TLS_FUNCS |
| 1090 | NEED_DES=y |
Hai Shalom | 81f62d8 | 2019-07-22 12:10:00 -0700 | [diff] [blame] | 1091 | # Shared TLS functions (needed for EAP_TLS, EAP_PEAP, EAP_TTLS, EAP_FAST, and |
| 1092 | # EAP_TEAP) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1093 | OBJS += ../src/eap_peer/eap_tls_common.o |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1094 | ifndef CONFIG_FIPS |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1095 | NEED_TLS_PRF=y |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 1096 | NEED_SHA1=y |
| 1097 | NEED_MD5=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1098 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1099 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1100 | |
| 1101 | ifndef CONFIG_TLS |
| 1102 | CONFIG_TLS=openssl |
| 1103 | endif |
| 1104 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1105 | ifdef CONFIG_TLSV11 |
| 1106 | CFLAGS += -DCONFIG_TLSV11 |
| 1107 | endif |
| 1108 | |
| 1109 | ifdef CONFIG_TLSV12 |
| 1110 | CFLAGS += -DCONFIG_TLSV12 |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1111 | endif |
| 1112 | |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1113 | ifeq ($(CONFIG_TLS), wolfssl) |
| 1114 | ifdef TLS_FUNCS |
Hai Shalom | 4fbc08f | 2020-05-18 12:37:00 -0700 | [diff] [blame] | 1115 | CFLAGS += -DWOLFSSL_DER_LOAD |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1116 | OBJS += ../src/crypto/tls_wolfssl.o |
| 1117 | endif |
| 1118 | OBJS += ../src/crypto/crypto_wolfssl.o |
| 1119 | OBJS_p += ../src/crypto/crypto_wolfssl.o |
| 1120 | ifdef NEED_FIPS186_2_PRF |
| 1121 | OBJS += ../src/crypto/fips_prf_wolfssl.o |
| 1122 | endif |
| 1123 | NEED_TLS_PRF_SHA256=y |
| 1124 | LIBS += -lwolfssl -lm |
| 1125 | LIBS_p += -lwolfssl -lm |
| 1126 | endif |
| 1127 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1128 | ifeq ($(CONFIG_TLS), openssl) |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 1129 | CFLAGS += -DCRYPTO_RSA_OAEP_SHA256 |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1130 | ifdef TLS_FUNCS |
| 1131 | CFLAGS += -DEAP_TLS_OPENSSL |
| 1132 | OBJS += ../src/crypto/tls_openssl.o |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 1133 | OBJS += ../src/crypto/tls_openssl_ocsp.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1134 | LIBS += -lssl |
| 1135 | endif |
| 1136 | OBJS += ../src/crypto/crypto_openssl.o |
| 1137 | OBJS_p += ../src/crypto/crypto_openssl.o |
Dmitry Shmidt | 1d755d0 | 2015-04-28 10:34:29 -0700 | [diff] [blame] | 1138 | OBJS_priv += ../src/crypto/crypto_openssl.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1139 | ifdef NEED_FIPS186_2_PRF |
| 1140 | OBJS += ../src/crypto/fips_prf_openssl.o |
| 1141 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1142 | NEED_TLS_PRF_SHA256=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1143 | LIBS += -lcrypto |
| 1144 | LIBS_p += -lcrypto |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1145 | ifdef CONFIG_TLS_ADD_DL |
| 1146 | LIBS += -ldl |
| 1147 | LIBS_p += -ldl |
| 1148 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1149 | ifndef CONFIG_TLS_DEFAULT_CIPHERS |
| 1150 | CONFIG_TLS_DEFAULT_CIPHERS = "DEFAULT:!EXP:!LOW" |
| 1151 | endif |
| 1152 | CFLAGS += -DTLS_DEFAULT_CIPHERS=\"$(CONFIG_TLS_DEFAULT_CIPHERS)\" |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1153 | endif |
| 1154 | |
| 1155 | ifeq ($(CONFIG_TLS), gnutls) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1156 | ifndef CONFIG_CRYPTO |
| 1157 | # default to libgcrypt |
| 1158 | CONFIG_CRYPTO=gnutls |
| 1159 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1160 | ifdef TLS_FUNCS |
| 1161 | OBJS += ../src/crypto/tls_gnutls.o |
| 1162 | LIBS += -lgnutls -lgpg-error |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1163 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1164 | OBJS += ../src/crypto/crypto_$(CONFIG_CRYPTO).o |
| 1165 | OBJS_p += ../src/crypto/crypto_$(CONFIG_CRYPTO).o |
| 1166 | OBJS_priv += ../src/crypto/crypto_$(CONFIG_CRYPTO).o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1167 | ifdef NEED_FIPS186_2_PRF |
Dmitry Shmidt | 9866086 | 2014-03-11 17:26:21 -0700 | [diff] [blame] | 1168 | OBJS += ../src/crypto/fips_prf_internal.o |
| 1169 | SHA1OBJS += ../src/crypto/sha1-internal.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1170 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1171 | ifeq ($(CONFIG_CRYPTO), gnutls) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1172 | LIBS += -lgcrypt |
| 1173 | LIBS_p += -lgcrypt |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1174 | CONFIG_INTERNAL_RC4=y |
| 1175 | CONFIG_INTERNAL_DH_GROUP5=y |
| 1176 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1177 | ifeq ($(CONFIG_CRYPTO), nettle) |
| 1178 | LIBS += -lnettle -lgmp |
| 1179 | LIBS_p += -lnettle -lgmp |
| 1180 | CONFIG_INTERNAL_RC4=y |
| 1181 | CONFIG_INTERNAL_DH_GROUP5=y |
| 1182 | endif |
| 1183 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1184 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1185 | ifeq ($(CONFIG_TLS), internal) |
| 1186 | ifndef CONFIG_CRYPTO |
| 1187 | CONFIG_CRYPTO=internal |
| 1188 | endif |
| 1189 | ifdef TLS_FUNCS |
| 1190 | OBJS += ../src/crypto/crypto_internal-rsa.o |
| 1191 | OBJS += ../src/crypto/tls_internal.o |
| 1192 | OBJS += ../src/tls/tlsv1_common.o |
| 1193 | OBJS += ../src/tls/tlsv1_record.o |
| 1194 | OBJS += ../src/tls/tlsv1_cred.o |
| 1195 | OBJS += ../src/tls/tlsv1_client.o |
| 1196 | OBJS += ../src/tls/tlsv1_client_write.o |
| 1197 | OBJS += ../src/tls/tlsv1_client_read.o |
Dmitry Shmidt | 55840ad | 2015-12-14 12:45:46 -0800 | [diff] [blame] | 1198 | OBJS += ../src/tls/tlsv1_client_ocsp.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1199 | OBJS += ../src/tls/rsa.o |
| 1200 | OBJS += ../src/tls/x509v3.o |
| 1201 | OBJS += ../src/tls/pkcs1.o |
| 1202 | OBJS += ../src/tls/pkcs5.o |
| 1203 | OBJS += ../src/tls/pkcs8.o |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 1204 | NEED_ASN1=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1205 | NEED_BASE64=y |
| 1206 | NEED_TLS_PRF=y |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1207 | ifdef CONFIG_TLSV12 |
| 1208 | NEED_TLS_PRF_SHA256=y |
| 1209 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1210 | NEED_MODEXP=y |
| 1211 | NEED_CIPHER=y |
| 1212 | CFLAGS += -DCONFIG_TLS_INTERNAL_CLIENT |
| 1213 | endif |
| 1214 | ifdef NEED_CIPHER |
| 1215 | NEED_DES=y |
| 1216 | OBJS += ../src/crypto/crypto_internal-cipher.o |
| 1217 | endif |
| 1218 | ifdef NEED_MODEXP |
| 1219 | OBJS += ../src/crypto/crypto_internal-modexp.o |
| 1220 | OBJS += ../src/tls/bignum.o |
| 1221 | endif |
| 1222 | ifeq ($(CONFIG_CRYPTO), libtomcrypt) |
| 1223 | OBJS += ../src/crypto/crypto_libtomcrypt.o |
| 1224 | OBJS_p += ../src/crypto/crypto_libtomcrypt.o |
| 1225 | LIBS += -ltomcrypt -ltfm |
| 1226 | LIBS_p += -ltomcrypt -ltfm |
| 1227 | CONFIG_INTERNAL_SHA256=y |
| 1228 | CONFIG_INTERNAL_RC4=y |
| 1229 | CONFIG_INTERNAL_DH_GROUP5=y |
| 1230 | endif |
| 1231 | ifeq ($(CONFIG_CRYPTO), internal) |
| 1232 | OBJS += ../src/crypto/crypto_internal.o |
| 1233 | OBJS_p += ../src/crypto/crypto_internal.o |
| 1234 | NEED_AES_ENC=y |
| 1235 | CFLAGS += -DCONFIG_CRYPTO_INTERNAL |
| 1236 | ifdef CONFIG_INTERNAL_LIBTOMMATH |
| 1237 | CFLAGS += -DCONFIG_INTERNAL_LIBTOMMATH |
| 1238 | ifdef CONFIG_INTERNAL_LIBTOMMATH_FAST |
| 1239 | CFLAGS += -DLTM_FAST |
| 1240 | endif |
| 1241 | else |
| 1242 | LIBS += -ltommath |
| 1243 | LIBS_p += -ltommath |
| 1244 | endif |
| 1245 | CONFIG_INTERNAL_AES=y |
| 1246 | CONFIG_INTERNAL_DES=y |
| 1247 | CONFIG_INTERNAL_SHA1=y |
| 1248 | CONFIG_INTERNAL_MD4=y |
| 1249 | CONFIG_INTERNAL_MD5=y |
| 1250 | CONFIG_INTERNAL_SHA256=y |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 1251 | CONFIG_INTERNAL_SHA384=y |
| 1252 | CONFIG_INTERNAL_SHA512=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1253 | CONFIG_INTERNAL_RC4=y |
| 1254 | CONFIG_INTERNAL_DH_GROUP5=y |
| 1255 | endif |
| 1256 | ifeq ($(CONFIG_CRYPTO), cryptoapi) |
| 1257 | OBJS += ../src/crypto/crypto_cryptoapi.o |
| 1258 | OBJS_p += ../src/crypto/crypto_cryptoapi.o |
| 1259 | CFLAGS += -DCONFIG_CRYPTO_CRYPTOAPI |
| 1260 | CONFIG_INTERNAL_SHA256=y |
| 1261 | CONFIG_INTERNAL_RC4=y |
| 1262 | endif |
| 1263 | endif |
| 1264 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1265 | ifeq ($(CONFIG_TLS), linux) |
| 1266 | OBJS += ../src/crypto/crypto_linux.o |
| 1267 | OBJS_p += ../src/crypto/crypto_linux.o |
| 1268 | ifdef TLS_FUNCS |
| 1269 | OBJS += ../src/crypto/crypto_internal-rsa.o |
| 1270 | OBJS += ../src/crypto/tls_internal.o |
| 1271 | OBJS += ../src/tls/tlsv1_common.o |
| 1272 | OBJS += ../src/tls/tlsv1_record.o |
| 1273 | OBJS += ../src/tls/tlsv1_cred.o |
| 1274 | OBJS += ../src/tls/tlsv1_client.o |
| 1275 | OBJS += ../src/tls/tlsv1_client_write.o |
| 1276 | OBJS += ../src/tls/tlsv1_client_read.o |
| 1277 | OBJS += ../src/tls/tlsv1_client_ocsp.o |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1278 | OBJS += ../src/tls/rsa.o |
| 1279 | OBJS += ../src/tls/x509v3.o |
| 1280 | OBJS += ../src/tls/pkcs1.o |
| 1281 | OBJS += ../src/tls/pkcs5.o |
| 1282 | OBJS += ../src/tls/pkcs8.o |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 1283 | NEED_ASN1=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1284 | NEED_BASE64=y |
| 1285 | NEED_TLS_PRF=y |
| 1286 | ifdef CONFIG_TLSV12 |
| 1287 | NEED_TLS_PRF_SHA256=y |
| 1288 | endif |
| 1289 | NEED_MODEXP=y |
| 1290 | NEED_CIPHER=y |
| 1291 | CFLAGS += -DCONFIG_TLS_INTERNAL_CLIENT |
| 1292 | endif |
| 1293 | ifdef NEED_MODEXP |
| 1294 | OBJS += ../src/crypto/crypto_internal-modexp.o |
| 1295 | OBJS += ../src/tls/bignum.o |
| 1296 | CFLAGS += -DCONFIG_INTERNAL_LIBTOMMATH |
| 1297 | CFLAGS += -DLTM_FAST |
| 1298 | endif |
| 1299 | CONFIG_INTERNAL_DH_GROUP5=y |
| 1300 | ifdef NEED_FIPS186_2_PRF |
| 1301 | OBJS += ../src/crypto/fips_prf_internal.o |
| 1302 | OBJS += ../src/crypto/sha1-internal.o |
| 1303 | endif |
| 1304 | endif |
| 1305 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1306 | ifeq ($(CONFIG_TLS), none) |
| 1307 | ifdef TLS_FUNCS |
| 1308 | OBJS += ../src/crypto/tls_none.o |
| 1309 | CFLAGS += -DEAP_TLS_NONE |
| 1310 | CONFIG_INTERNAL_AES=y |
| 1311 | CONFIG_INTERNAL_SHA1=y |
| 1312 | CONFIG_INTERNAL_MD5=y |
| 1313 | endif |
| 1314 | OBJS += ../src/crypto/crypto_none.o |
| 1315 | OBJS_p += ../src/crypto/crypto_none.o |
| 1316 | CONFIG_INTERNAL_SHA256=y |
| 1317 | CONFIG_INTERNAL_RC4=y |
| 1318 | endif |
| 1319 | |
| 1320 | ifdef TLS_FUNCS |
| 1321 | ifdef CONFIG_SMARTCARD |
| 1322 | ifndef CONFIG_NATIVE_WINDOWS |
| 1323 | ifneq ($(CONFIG_L2_PACKET), freebsd) |
| 1324 | LIBS += -ldl |
| 1325 | endif |
| 1326 | endif |
| 1327 | endif |
| 1328 | endif |
| 1329 | |
| 1330 | ifndef TLS_FUNCS |
| 1331 | OBJS += ../src/crypto/tls_none.o |
| 1332 | ifeq ($(CONFIG_TLS), internal) |
| 1333 | CONFIG_INTERNAL_AES=y |
| 1334 | CONFIG_INTERNAL_SHA1=y |
| 1335 | CONFIG_INTERNAL_MD5=y |
| 1336 | CONFIG_INTERNAL_RC4=y |
| 1337 | endif |
| 1338 | endif |
| 1339 | |
| 1340 | AESOBJS = # none so far (see below) |
| 1341 | ifdef CONFIG_INTERNAL_AES |
| 1342 | AESOBJS += ../src/crypto/aes-internal.o ../src/crypto/aes-internal-dec.o |
| 1343 | endif |
| 1344 | |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 1345 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1346 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1347 | NEED_INTERNAL_AES_WRAP=y |
| 1348 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1349 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1350 | ifdef CONFIG_OPENSSL_INTERNAL_AES_WRAP |
| 1351 | # Seems to be needed at least with BoringSSL |
| 1352 | NEED_INTERNAL_AES_WRAP=y |
| 1353 | CFLAGS += -DCONFIG_OPENSSL_INTERNAL_AES_WRAP |
| 1354 | endif |
| 1355 | ifdef CONFIG_FIPS |
| 1356 | # Have to use internal AES key wrap routines to use OpenSSL EVP since the |
| 1357 | # OpenSSL AES_wrap_key()/AES_unwrap_key() API is not available in FIPS mode. |
| 1358 | NEED_INTERNAL_AES_WRAP=y |
| 1359 | endif |
| 1360 | |
| 1361 | ifdef NEED_INTERNAL_AES_WRAP |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1362 | ifneq ($(CONFIG_TLS), linux) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1363 | AESOBJS += ../src/crypto/aes-unwrap.o |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 1364 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1365 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1366 | ifdef NEED_AES_EAX |
| 1367 | AESOBJS += ../src/crypto/aes-eax.o |
| 1368 | NEED_AES_CTR=y |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1369 | endif |
| 1370 | ifdef NEED_AES_SIV |
| 1371 | AESOBJS += ../src/crypto/aes-siv.o |
| 1372 | NEED_AES_CTR=y |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1373 | endif |
| 1374 | ifdef NEED_AES_CTR |
| 1375 | AESOBJS += ../src/crypto/aes-ctr.o |
| 1376 | endif |
| 1377 | ifdef NEED_AES_ENCBLOCK |
| 1378 | AESOBJS += ../src/crypto/aes-encblock.o |
| 1379 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1380 | NEED_AES_ENC=y |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 1381 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1382 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1383 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1384 | AESOBJS += ../src/crypto/aes-omac1.o |
| 1385 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1386 | endif |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 1387 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1388 | ifdef NEED_AES_WRAP |
| 1389 | NEED_AES_ENC=y |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1390 | ifdef NEED_INTERNAL_AES_WRAP |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1391 | AESOBJS += ../src/crypto/aes-wrap.o |
| 1392 | endif |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 1393 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1394 | ifdef NEED_AES_CBC |
| 1395 | NEED_AES_ENC=y |
Dmitry Shmidt | 912c6ec | 2015-03-30 13:16:51 -0700 | [diff] [blame] | 1396 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1397 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1398 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1399 | AESOBJS += ../src/crypto/aes-cbc.o |
| 1400 | endif |
Dmitry Shmidt | 912c6ec | 2015-03-30 13:16:51 -0700 | [diff] [blame] | 1401 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1402 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1403 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1404 | ifdef NEED_AES_ENC |
| 1405 | ifdef CONFIG_INTERNAL_AES |
| 1406 | AESOBJS += ../src/crypto/aes-internal-enc.o |
| 1407 | endif |
| 1408 | endif |
| 1409 | ifdef NEED_AES |
| 1410 | OBJS += $(AESOBJS) |
| 1411 | endif |
| 1412 | |
| 1413 | ifdef NEED_SHA1 |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1414 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1415 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1416 | ifneq ($(CONFIG_TLS), gnutls) |
| 1417 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1418 | SHA1OBJS += ../src/crypto/sha1.o |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1419 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1420 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1421 | endif |
| 1422 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1423 | SHA1OBJS += ../src/crypto/sha1-prf.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1424 | ifdef CONFIG_INTERNAL_SHA1 |
| 1425 | SHA1OBJS += ../src/crypto/sha1-internal.o |
| 1426 | ifdef NEED_FIPS186_2_PRF |
| 1427 | SHA1OBJS += ../src/crypto/fips_prf_internal.o |
| 1428 | endif |
| 1429 | endif |
Jouni Malinen | 75ecf52 | 2011-06-27 15:19:46 -0700 | [diff] [blame] | 1430 | ifdef CONFIG_NO_WPA_PASSPHRASE |
| 1431 | CFLAGS += -DCONFIG_NO_PBKDF2 |
| 1432 | else |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1433 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1434 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1435 | SHA1OBJS += ../src/crypto/sha1-pbkdf2.o |
| 1436 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1437 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1438 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1439 | ifdef NEED_T_PRF |
| 1440 | SHA1OBJS += ../src/crypto/sha1-tprf.o |
| 1441 | endif |
| 1442 | ifdef NEED_TLS_PRF |
| 1443 | SHA1OBJS += ../src/crypto/sha1-tlsprf.o |
| 1444 | endif |
| 1445 | endif |
| 1446 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1447 | ifndef CONFIG_FIPS |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 1448 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1449 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1450 | ifneq ($(CONFIG_TLS), gnutls) |
| 1451 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1452 | MD5OBJS += ../src/crypto/md5.o |
| 1453 | endif |
Dmitry Shmidt | 216983b | 2015-02-06 10:50:36 -0800 | [diff] [blame] | 1454 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1455 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1456 | endif |
| 1457 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1458 | ifdef NEED_MD5 |
| 1459 | ifdef CONFIG_INTERNAL_MD5 |
| 1460 | MD5OBJS += ../src/crypto/md5-internal.o |
| 1461 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1462 | OBJS += $(MD5OBJS) |
| 1463 | OBJS_p += $(MD5OBJS) |
Dmitry Shmidt | 1d755d0 | 2015-04-28 10:34:29 -0700 | [diff] [blame] | 1464 | OBJS_priv += $(MD5OBJS) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1465 | endif |
| 1466 | |
| 1467 | ifdef NEED_MD4 |
| 1468 | ifdef CONFIG_INTERNAL_MD4 |
| 1469 | OBJS += ../src/crypto/md4-internal.o |
| 1470 | endif |
| 1471 | endif |
| 1472 | |
| 1473 | DESOBJS = # none needed when not internal |
| 1474 | ifdef NEED_DES |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1475 | ifndef CONFIG_FIPS |
| 1476 | CFLAGS += -DCONFIG_DES |
| 1477 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1478 | ifdef CONFIG_INTERNAL_DES |
| 1479 | DESOBJS += ../src/crypto/des-internal.o |
| 1480 | endif |
| 1481 | endif |
| 1482 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1483 | ifdef CONFIG_NO_RC4 |
| 1484 | CFLAGS += -DCONFIG_NO_RC4 |
| 1485 | endif |
| 1486 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1487 | ifdef NEED_RC4 |
| 1488 | ifdef CONFIG_INTERNAL_RC4 |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1489 | ifndef CONFIG_NO_RC4 |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1490 | OBJS += ../src/crypto/rc4.o |
| 1491 | endif |
| 1492 | endif |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1493 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1494 | |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 1495 | ifdef CONFIG_SAE |
| 1496 | ifdef NEED_SHA384 |
| 1497 | # Need to add HMAC-SHA384 KDF as well, if SHA384 was enabled. |
| 1498 | NEED_HMAC_SHA384_KDF=y |
| 1499 | endif |
| 1500 | ifdef NEED_SHA512 |
| 1501 | # Need to add HMAC-SHA512 KDF as well, if SHA512 was enabled. |
| 1502 | NEED_HMAC_SHA512_KDF=y |
| 1503 | endif |
| 1504 | endif |
| 1505 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1506 | SHA256OBJS = # none by default |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1507 | CFLAGS += -DCONFIG_SHA256 |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1508 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1509 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1510 | ifneq ($(CONFIG_TLS), gnutls) |
| 1511 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1512 | SHA256OBJS += ../src/crypto/sha256.o |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1513 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1514 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1515 | endif |
| 1516 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1517 | SHA256OBJS += ../src/crypto/sha256-prf.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1518 | ifdef CONFIG_INTERNAL_SHA256 |
| 1519 | SHA256OBJS += ../src/crypto/sha256-internal.o |
| 1520 | endif |
Dmitry Shmidt | d7ff03d | 2015-12-04 14:49:35 -0800 | [diff] [blame] | 1521 | ifdef CONFIG_INTERNAL_SHA384 |
| 1522 | CFLAGS += -DCONFIG_INTERNAL_SHA384 |
| 1523 | SHA256OBJS += ../src/crypto/sha384-internal.o |
| 1524 | endif |
| 1525 | ifdef CONFIG_INTERNAL_SHA512 |
| 1526 | CFLAGS += -DCONFIG_INTERNAL_SHA512 |
| 1527 | SHA256OBJS += ../src/crypto/sha512-internal.o |
| 1528 | endif |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1529 | ifdef NEED_TLS_PRF_SHA256 |
| 1530 | SHA256OBJS += ../src/crypto/sha256-tlsprf.o |
| 1531 | endif |
Hai Shalom | c356592 | 2019-10-28 11:58:20 -0700 | [diff] [blame] | 1532 | ifdef NEED_TLS_PRF_SHA384 |
| 1533 | SHA256OBJS += ../src/crypto/sha384-tlsprf.o |
| 1534 | endif |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 1535 | ifdef NEED_HMAC_SHA256_KDF |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1536 | CFLAGS += -DCONFIG_HMAC_SHA256_KDF |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 1537 | OBJS += ../src/crypto/sha256-kdf.o |
| 1538 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1539 | ifdef NEED_HMAC_SHA384_KDF |
| 1540 | CFLAGS += -DCONFIG_HMAC_SHA384_KDF |
| 1541 | OBJS += ../src/crypto/sha384-kdf.o |
| 1542 | endif |
| 1543 | ifdef NEED_HMAC_SHA512_KDF |
| 1544 | CFLAGS += -DCONFIG_HMAC_SHA512_KDF |
| 1545 | OBJS += ../src/crypto/sha512-kdf.o |
| 1546 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1547 | OBJS += $(SHA256OBJS) |
Dmitry Shmidt | 807291d | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 1548 | ifdef NEED_SHA384 |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 1549 | ifneq ($(CONFIG_TLS), openssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1550 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1551 | ifneq ($(CONFIG_TLS), gnutls) |
| 1552 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | ebd93af | 2017-02-21 13:40:44 -0800 | [diff] [blame] | 1553 | OBJS += ../src/crypto/sha384.o |
| 1554 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1555 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1556 | endif |
| 1557 | endif |
Dmitry Shmidt | 807291d | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 1558 | CFLAGS += -DCONFIG_SHA384 |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1559 | OBJS += ../src/crypto/sha384-prf.o |
Dmitry Shmidt | 807291d | 2015-01-27 13:40:23 -0800 | [diff] [blame] | 1560 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1561 | ifdef NEED_SHA512 |
| 1562 | ifneq ($(CONFIG_TLS), openssl) |
| 1563 | ifneq ($(CONFIG_TLS), linux) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1564 | ifneq ($(CONFIG_TLS), gnutls) |
| 1565 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1566 | OBJS += ../src/crypto/sha512.o |
| 1567 | endif |
| 1568 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1569 | endif |
| 1570 | endif |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1571 | CFLAGS += -DCONFIG_SHA512 |
| 1572 | OBJS += ../src/crypto/sha512-prf.o |
| 1573 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1574 | |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 1575 | ifdef NEED_ASN1 |
| 1576 | OBJS += ../src/tls/asn1.o |
| 1577 | endif |
| 1578 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1579 | ifdef NEED_DH_GROUPS |
| 1580 | OBJS += ../src/crypto/dh_groups.o |
| 1581 | endif |
| 1582 | ifdef NEED_DH_GROUPS_ALL |
| 1583 | CFLAGS += -DALL_DH_GROUPS |
| 1584 | endif |
| 1585 | ifdef CONFIG_INTERNAL_DH_GROUP5 |
| 1586 | ifdef NEED_DH_GROUPS |
| 1587 | OBJS += ../src/crypto/dh_group5.o |
| 1588 | endif |
| 1589 | endif |
| 1590 | |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 1591 | ifdef NEED_ECC |
| 1592 | CFLAGS += -DCONFIG_ECC |
| 1593 | endif |
| 1594 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1595 | ifdef CONFIG_NO_RANDOM_POOL |
| 1596 | CFLAGS += -DCONFIG_NO_RANDOM_POOL |
| 1597 | else |
Hai Shalom | 74f70d4 | 2019-02-11 14:42:39 -0800 | [diff] [blame] | 1598 | ifdef CONFIG_GETRANDOM |
| 1599 | CFLAGS += -DCONFIG_GETRANDOM |
| 1600 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1601 | OBJS += ../src/crypto/random.o |
| 1602 | endif |
| 1603 | |
| 1604 | ifdef CONFIG_CTRL_IFACE |
| 1605 | ifeq ($(CONFIG_CTRL_IFACE), y) |
| 1606 | ifdef CONFIG_NATIVE_WINDOWS |
| 1607 | CONFIG_CTRL_IFACE=named_pipe |
| 1608 | else |
| 1609 | CONFIG_CTRL_IFACE=unix |
| 1610 | endif |
| 1611 | endif |
| 1612 | CFLAGS += -DCONFIG_CTRL_IFACE |
| 1613 | ifeq ($(CONFIG_CTRL_IFACE), unix) |
| 1614 | CFLAGS += -DCONFIG_CTRL_IFACE_UNIX |
Dmitry Shmidt | 31a29cc | 2016-03-09 15:58:17 -0800 | [diff] [blame] | 1615 | OBJS += ../src/common/ctrl_iface_common.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1616 | endif |
| 1617 | ifeq ($(CONFIG_CTRL_IFACE), udp) |
| 1618 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP |
| 1619 | endif |
Dmitry Shmidt | f21452a | 2014-02-26 10:55:25 -0800 | [diff] [blame] | 1620 | ifeq ($(CONFIG_CTRL_IFACE), udp6) |
| 1621 | CONFIG_CTRL_IFACE=udp |
| 1622 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP |
| 1623 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP_IPV6 |
| 1624 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1625 | ifeq ($(CONFIG_CTRL_IFACE), named_pipe) |
| 1626 | CFLAGS += -DCONFIG_CTRL_IFACE_NAMED_PIPE |
| 1627 | endif |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1628 | ifeq ($(CONFIG_CTRL_IFACE), udp-remote) |
| 1629 | CONFIG_CTRL_IFACE=udp |
| 1630 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP |
| 1631 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP_REMOTE |
| 1632 | endif |
Dmitry Shmidt | f21452a | 2014-02-26 10:55:25 -0800 | [diff] [blame] | 1633 | ifeq ($(CONFIG_CTRL_IFACE), udp6-remote) |
| 1634 | CONFIG_CTRL_IFACE=udp |
| 1635 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP |
| 1636 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP_REMOTE |
| 1637 | CFLAGS += -DCONFIG_CTRL_IFACE_UDP_IPV6 |
| 1638 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1639 | OBJS += ctrl_iface.o ctrl_iface_$(CONFIG_CTRL_IFACE).o |
| 1640 | endif |
| 1641 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1642 | ifdef CONFIG_CTRL_IFACE_DBUS_NEW |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1643 | CFLAGS += -DCONFIG_CTRL_IFACE_DBUS_NEW |
| 1644 | OBJS += dbus/dbus_dict_helpers.o |
| 1645 | OBJS += dbus/dbus_new_helpers.o |
| 1646 | OBJS += dbus/dbus_new.o dbus/dbus_new_handlers.o |
| 1647 | OBJS += dbus/dbus_common.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1648 | ifdef CONFIG_WPS |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1649 | OBJS += dbus/dbus_new_handlers_wps.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1650 | endif |
Jouni Malinen | 75ecf52 | 2011-06-27 15:19:46 -0700 | [diff] [blame] | 1651 | ifdef CONFIG_P2P |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1652 | OBJS += dbus/dbus_new_handlers_p2p.o |
Jouni Malinen | 75ecf52 | 2011-06-27 15:19:46 -0700 | [diff] [blame] | 1653 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1654 | ifndef DBUS_LIBS |
Dmitry Shmidt | c55524a | 2011-07-07 11:18:38 -0700 | [diff] [blame] | 1655 | DBUS_LIBS := $(shell $(PKG_CONFIG) --libs dbus-1) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1656 | endif |
| 1657 | ifndef DBUS_INCLUDE |
Dmitry Shmidt | c55524a | 2011-07-07 11:18:38 -0700 | [diff] [blame] | 1658 | DBUS_INCLUDE := $(shell $(PKG_CONFIG) --cflags dbus-1) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1659 | endif |
| 1660 | ifdef CONFIG_CTRL_IFACE_DBUS_INTRO |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1661 | OBJS += dbus/dbus_new_introspect.o |
| 1662 | CFLAGS += -DCONFIG_CTRL_IFACE_DBUS_INTRO |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1663 | endif |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1664 | CFLAGS += $(DBUS_INCLUDE) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1665 | LIBS += $(DBUS_LIBS) |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 1666 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1667 | |
| 1668 | ifdef CONFIG_READLINE |
| 1669 | OBJS_c += ../src/utils/edit_readline.o |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1670 | LIBS_c += -lreadline -lncurses |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1671 | else |
| 1672 | ifdef CONFIG_WPA_CLI_EDIT |
| 1673 | OBJS_c += ../src/utils/edit.o |
| 1674 | else |
| 1675 | OBJS_c += ../src/utils/edit_simple.o |
| 1676 | endif |
| 1677 | endif |
| 1678 | |
| 1679 | ifdef CONFIG_NATIVE_WINDOWS |
| 1680 | CFLAGS += -DCONFIG_NATIVE_WINDOWS |
| 1681 | LIBS += -lws2_32 -lgdi32 -lcrypt32 |
| 1682 | LIBS_c += -lws2_32 |
| 1683 | LIBS_p += -lws2_32 -lgdi32 |
| 1684 | ifeq ($(CONFIG_CRYPTO), cryptoapi) |
| 1685 | LIBS_p += -lcrypt32 |
| 1686 | endif |
| 1687 | endif |
| 1688 | |
| 1689 | ifdef CONFIG_NO_STDOUT_DEBUG |
| 1690 | CFLAGS += -DCONFIG_NO_STDOUT_DEBUG |
| 1691 | ifndef CONFIG_CTRL_IFACE |
| 1692 | CFLAGS += -DCONFIG_NO_WPA_MSG |
| 1693 | endif |
| 1694 | endif |
| 1695 | |
| 1696 | ifdef CONFIG_IPV6 |
| 1697 | # for eapol_test only |
| 1698 | CFLAGS += -DCONFIG_IPV6 |
| 1699 | endif |
| 1700 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1701 | ifdef CONFIG_NO_LINUX_PACKET_SOCKET_WAR |
| 1702 | CFLAGS += -DCONFIG_NO_LINUX_PACKET_SOCKET_WAR |
| 1703 | endif |
| 1704 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1705 | ifdef NEED_BASE64 |
| 1706 | OBJS += ../src/utils/base64.o |
| 1707 | endif |
| 1708 | |
| 1709 | ifdef NEED_SME |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1710 | OBJS += sme.o |
| 1711 | CFLAGS += -DCONFIG_SME |
| 1712 | endif |
| 1713 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1714 | OBJS += ../src/common/ieee802_11_common.o |
Dmitry Shmidt | ff787d5 | 2015-01-12 13:01:47 -0800 | [diff] [blame] | 1715 | OBJS += ../src/common/hw_features_common.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1716 | |
| 1717 | ifdef NEED_EAP_COMMON |
| 1718 | OBJS += ../src/eap_common/eap_common.o |
| 1719 | endif |
| 1720 | |
| 1721 | ifndef CONFIG_MAIN |
| 1722 | CONFIG_MAIN=main |
| 1723 | endif |
| 1724 | |
| 1725 | ifdef CONFIG_DEBUG_SYSLOG |
| 1726 | CFLAGS += -DCONFIG_DEBUG_SYSLOG |
| 1727 | ifdef CONFIG_DEBUG_SYSLOG_FACILITY |
| 1728 | CFLAGS += -DLOG_HOSTAPD="$(CONFIG_DEBUG_SYSLOG_FACILITY)" |
| 1729 | endif |
| 1730 | endif |
| 1731 | |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1732 | ifdef CONFIG_DEBUG_LINUX_TRACING |
| 1733 | CFLAGS += -DCONFIG_DEBUG_LINUX_TRACING |
| 1734 | endif |
| 1735 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1736 | ifdef CONFIG_DEBUG_FILE |
| 1737 | CFLAGS += -DCONFIG_DEBUG_FILE |
| 1738 | endif |
| 1739 | |
| 1740 | ifdef CONFIG_DELAYED_MIC_ERROR_REPORT |
| 1741 | CFLAGS += -DCONFIG_DELAYED_MIC_ERROR_REPORT |
| 1742 | endif |
| 1743 | |
| 1744 | ifdef CONFIG_FIPS |
| 1745 | CFLAGS += -DCONFIG_FIPS |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1746 | ifneq ($(CONFIG_TLS), openssl) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1747 | ifneq ($(CONFIG_TLS), wolfssl) |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1748 | $(error CONFIG_FIPS=y requires CONFIG_TLS=openssl) |
| 1749 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1750 | endif |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1751 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1752 | |
| 1753 | OBJS += $(SHA1OBJS) $(DESOBJS) |
| 1754 | |
| 1755 | OBJS_p += $(SHA1OBJS) |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1756 | OBJS_p += $(SHA256OBJS) |
Dmitry Shmidt | 1d755d0 | 2015-04-28 10:34:29 -0700 | [diff] [blame] | 1757 | OBJS_priv += $(SHA1OBJS) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1758 | |
| 1759 | ifdef CONFIG_BGSCAN_SIMPLE |
| 1760 | CFLAGS += -DCONFIG_BGSCAN_SIMPLE |
| 1761 | OBJS += bgscan_simple.o |
| 1762 | NEED_BGSCAN=y |
| 1763 | endif |
| 1764 | |
| 1765 | ifdef CONFIG_BGSCAN_LEARN |
| 1766 | CFLAGS += -DCONFIG_BGSCAN_LEARN |
| 1767 | OBJS += bgscan_learn.o |
| 1768 | NEED_BGSCAN=y |
| 1769 | endif |
| 1770 | |
| 1771 | ifdef NEED_BGSCAN |
| 1772 | CFLAGS += -DCONFIG_BGSCAN |
| 1773 | OBJS += bgscan.o |
| 1774 | endif |
| 1775 | |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1776 | ifdef CONFIG_AUTOSCAN_EXPONENTIAL |
| 1777 | CFLAGS += -DCONFIG_AUTOSCAN_EXPONENTIAL |
| 1778 | OBJS += autoscan_exponential.o |
| 1779 | NEED_AUTOSCAN=y |
| 1780 | endif |
| 1781 | |
| 1782 | ifdef CONFIG_AUTOSCAN_PERIODIC |
| 1783 | CFLAGS += -DCONFIG_AUTOSCAN_PERIODIC |
| 1784 | OBJS += autoscan_periodic.o |
| 1785 | NEED_AUTOSCAN=y |
| 1786 | endif |
| 1787 | |
| 1788 | ifdef NEED_AUTOSCAN |
| 1789 | CFLAGS += -DCONFIG_AUTOSCAN |
| 1790 | OBJS += autoscan.o |
| 1791 | endif |
| 1792 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1793 | ifdef CONFIG_EXT_PASSWORD_TEST |
| 1794 | OBJS += ../src/utils/ext_password_test.o |
| 1795 | CFLAGS += -DCONFIG_EXT_PASSWORD_TEST |
| 1796 | NEED_EXT_PASSWORD=y |
| 1797 | endif |
| 1798 | |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 1799 | ifdef CONFIG_EXT_PASSWORD_FILE |
| 1800 | OBJS += ../src/utils/ext_password_file.o |
| 1801 | CFLAGS += -DCONFIG_EXT_PASSWORD_FILE |
| 1802 | NEED_EXT_PASSWORD=y |
| 1803 | endif |
| 1804 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 1805 | ifdef NEED_EXT_PASSWORD |
| 1806 | OBJS += ../src/utils/ext_password.o |
| 1807 | CFLAGS += -DCONFIG_EXT_PASSWORD |
| 1808 | endif |
| 1809 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1810 | ifdef NEED_GAS_SERVER |
| 1811 | OBJS += ../src/common/gas_server.o |
| 1812 | CFLAGS += -DCONFIG_GAS_SERVER |
| 1813 | NEED_GAS=y |
| 1814 | endif |
| 1815 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1816 | ifdef NEED_GAS |
| 1817 | OBJS += ../src/common/gas.o |
| 1818 | OBJS += gas_query.o |
| 1819 | CFLAGS += -DCONFIG_GAS |
| 1820 | NEED_OFFCHANNEL=y |
| 1821 | endif |
| 1822 | |
| 1823 | ifdef NEED_OFFCHANNEL |
| 1824 | OBJS += offchannel.o |
| 1825 | CFLAGS += -DCONFIG_OFFCHANNEL |
| 1826 | endif |
| 1827 | |
Dmitry Shmidt | d2986c2 | 2017-10-23 14:22:09 -0700 | [diff] [blame] | 1828 | ifdef NEED_JSON |
| 1829 | OBJS += ../src/utils/json.o |
| 1830 | CFLAGS += -DCONFIG_JSON |
| 1831 | endif |
| 1832 | |
Dmitry Shmidt | 7175743 | 2014-06-02 13:50:35 -0700 | [diff] [blame] | 1833 | ifdef CONFIG_MODULE_TESTS |
| 1834 | CFLAGS += -DCONFIG_MODULE_TESTS |
| 1835 | OBJS += wpas_module_tests.o |
| 1836 | OBJS += ../src/utils/utils_module_tests.o |
| 1837 | OBJS += ../src/common/common_module_tests.o |
Dmitry Shmidt | ff787d5 | 2015-01-12 13:01:47 -0800 | [diff] [blame] | 1838 | OBJS += ../src/crypto/crypto_module_tests.o |
Dmitry Shmidt | 7175743 | 2014-06-02 13:50:35 -0700 | [diff] [blame] | 1839 | ifdef CONFIG_WPS |
| 1840 | OBJS += ../src/wps/wps_module_tests.o |
| 1841 | endif |
| 1842 | endif |
| 1843 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1844 | OBJS += ../src/drivers/driver_common.o |
Dmitry Shmidt | a54fa5f | 2013-01-15 13:53:35 -0800 | [diff] [blame] | 1845 | OBJS_priv += ../src/drivers/driver_common.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1846 | |
Hai Shalom | 6084025 | 2021-02-19 19:02:11 -0800 | [diff] [blame] | 1847 | OBJS += wpa_supplicant.o events.o bssid_ignore.o wpas_glue.o scan.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1848 | OBJS_t := $(OBJS) $(OBJS_l2) eapol_test.o |
| 1849 | OBJS_t += ../src/radius/radius_client.o |
| 1850 | OBJS_t += ../src/radius/radius.o |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1851 | OBJS_t2 := $(OBJS) $(OBJS_l2) preauth_test.o |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1852 | |
| 1853 | OBJS_nfc := $(OBJS) $(OBJS_l2) nfc_pw_token.o |
| 1854 | OBJS_nfc += $(OBJS_d) ../src/drivers/drivers.o |
| 1855 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1856 | OBJS += $(CONFIG_MAIN).o |
| 1857 | |
| 1858 | ifdef CONFIG_PRIVSEP |
| 1859 | OBJS_priv += $(OBJS_d) ../src/drivers/drivers.o |
| 1860 | OBJS_priv += $(OBJS_l2) |
| 1861 | OBJS_priv += ../src/utils/os_$(CONFIG_OS).o |
| 1862 | OBJS_priv += ../src/utils/$(CONFIG_ELOOP).o |
| 1863 | OBJS_priv += ../src/utils/common.o |
| 1864 | OBJS_priv += ../src/utils/wpa_debug.o |
| 1865 | OBJS_priv += ../src/utils/wpabuf.o |
| 1866 | OBJS_priv += wpa_priv.o |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1867 | ifdef CONFIG_DRIVER_NL80211 |
| 1868 | OBJS_priv += ../src/common/ieee802_11_common.o |
| 1869 | endif |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1870 | OBJS += ../src/l2_packet/l2_packet_privsep.o |
| 1871 | OBJS += ../src/drivers/driver_privsep.o |
| 1872 | EXTRA_progs += wpa_priv |
| 1873 | else |
| 1874 | OBJS += $(OBJS_d) ../src/drivers/drivers.o |
| 1875 | OBJS += $(OBJS_l2) |
| 1876 | endif |
| 1877 | |
| 1878 | ifdef CONFIG_NDIS_EVENTS_INTEGRATED |
| 1879 | CFLAGS += -DCONFIG_NDIS_EVENTS_INTEGRATED |
| 1880 | OBJS += ../src/drivers/ndis_events.o |
| 1881 | EXTRALIBS += -loleaut32 -lole32 -luuid |
| 1882 | ifdef PLATFORMSDKLIB |
| 1883 | EXTRALIBS += $(PLATFORMSDKLIB)/WbemUuid.Lib |
| 1884 | else |
| 1885 | EXTRALIBS += WbemUuid.Lib |
| 1886 | endif |
| 1887 | endif |
| 1888 | |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1889 | ifdef CONFIG_FST |
| 1890 | CFLAGS += -DCONFIG_FST |
| 1891 | ifdef CONFIG_FST_TEST |
| 1892 | CFLAGS += -DCONFIG_FST_TEST |
| 1893 | endif |
| 1894 | FST_OBJS += ../src/fst/fst.o |
| 1895 | FST_OBJS += ../src/fst/fst_session.o |
| 1896 | FST_OBJS += ../src/fst/fst_iface.o |
| 1897 | FST_OBJS += ../src/fst/fst_group.o |
| 1898 | FST_OBJS += ../src/fst/fst_ctrl_aux.o |
| 1899 | ifdef CONFIG_CTRL_IFACE |
| 1900 | FST_OBJS += ../src/fst/fst_ctrl_iface.o |
| 1901 | endif |
| 1902 | OBJS += $(FST_OBJS) |
| 1903 | OBJS_t += $(FST_OBJS) |
| 1904 | OBJS_t2 += $(FST_OBJS) |
Dmitry Shmidt | e466304 | 2016-04-04 10:07:49 -0700 | [diff] [blame] | 1905 | OBJS_nfc += $(FST_OBJS) |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1906 | endif |
| 1907 | |
Hai Shalom | fdcde76 | 2020-04-02 11:19:20 -0700 | [diff] [blame] | 1908 | ifdef CONFIG_WEP |
| 1909 | CFLAGS += -DCONFIG_WEP |
| 1910 | endif |
| 1911 | |
Hai Shalom | b755a2a | 2020-04-23 21:49:02 -0700 | [diff] [blame] | 1912 | ifdef CONFIG_NO_TKIP |
| 1913 | CFLAGS += -DCONFIG_NO_TKIP |
| 1914 | endif |
| 1915 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1916 | dynamic_eap_methods: $(EAPDYN) |
| 1917 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1918 | _OBJS_VAR := OBJS_priv |
| 1919 | include ../src/objs.mk |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1920 | wpa_priv: $(BCHECK) $(OBJS_priv) |
| 1921 | $(Q)$(LDO) $(LDFLAGS) -o wpa_priv $(OBJS_priv) $(LIBS) |
| 1922 | @$(E) " LD " $@ |
| 1923 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1924 | _OBJS_VAR := OBJS |
| 1925 | include ../src/objs.mk |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1926 | wpa_supplicant: $(BCHECK) $(OBJS) $(EXTRA_progs) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1927 | $(Q)$(LDO) $(LDFLAGS) -o wpa_supplicant $(OBJS) $(LIBS) $(EXTRALIBS) |
| 1928 | @$(E) " LD " $@ |
| 1929 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1930 | _OBJS_VAR := OBJS_t |
| 1931 | include ../src/objs.mk |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1932 | eapol_test: $(OBJS_t) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1933 | $(Q)$(LDO) $(LDFLAGS) -o eapol_test $(OBJS_t) $(LIBS) |
| 1934 | @$(E) " LD " $@ |
| 1935 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1936 | _OBJS_VAR := OBJS_t2 |
| 1937 | include ../src/objs.mk |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 1938 | preauth_test: $(OBJS_t2) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1939 | $(Q)$(LDO) $(LDFLAGS) -o preauth_test $(OBJS_t2) $(LIBS) |
| 1940 | @$(E) " LD " $@ |
| 1941 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1942 | _OBJS_VAR := OBJS_p |
| 1943 | include ../src/objs.mk |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1944 | wpa_passphrase: $(OBJS_p) |
Roshan Pius | 3a1667e | 2018-07-03 15:17:14 -0700 | [diff] [blame] | 1945 | $(Q)$(LDO) $(LDFLAGS) -o wpa_passphrase $(OBJS_p) $(LIBS_p) $(LIBS) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1946 | @$(E) " LD " $@ |
| 1947 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1948 | _OBJS_VAR := OBJS_c |
| 1949 | include ../src/objs.mk |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1950 | wpa_cli: $(OBJS_c) |
| 1951 | $(Q)$(LDO) $(LDFLAGS) -o wpa_cli $(OBJS_c) $(LIBS_c) |
| 1952 | @$(E) " LD " $@ |
| 1953 | |
Dmitry Shmidt | 7f65602 | 2015-02-25 14:36:37 -0800 | [diff] [blame] | 1954 | LIBCTRL += ../src/common/wpa_ctrl.o |
| 1955 | LIBCTRL += ../src/utils/os_$(CONFIG_OS).o |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1956 | LIBCTRL += ../src/utils/common.o |
Dmitry Shmidt | 7f65602 | 2015-02-25 14:36:37 -0800 | [diff] [blame] | 1957 | LIBCTRL += ../src/utils/wpa_debug.o |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 1958 | LIBCTRLSO += ../src/common/wpa_ctrl.c |
| 1959 | LIBCTRLSO += ../src/utils/os_$(CONFIG_OS).c |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1960 | LIBCTRLSO += ../src/utils/common.c |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 1961 | LIBCTRLSO += ../src/utils/wpa_debug.c |
Dmitry Shmidt | 7f65602 | 2015-02-25 14:36:37 -0800 | [diff] [blame] | 1962 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1963 | _OBJS_VAR := LIBCTRL |
| 1964 | include ../src/objs.mk |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 1965 | libwpa_client.a: $(LIBCTRL) |
Dmitry Shmidt | 7f65602 | 2015-02-25 14:36:37 -0800 | [diff] [blame] | 1966 | $(Q)rm -f $@ |
| 1967 | $(Q)$(AR) crs $@ $? |
| 1968 | @$(E) " AR " $@ |
| 1969 | |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 1970 | libwpa_client.so: $(LIBCTRLSO) |
| 1971 | @$(E) " CC $@ ($^)" |
| 1972 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -fPIC $^ |
| 1973 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1974 | OBJS_wpatest := libwpa_test.o |
| 1975 | _OBJS_VAR := OBJS_wpatest |
| 1976 | include ../src/objs.mk |
| 1977 | libwpa_test1: $(OBJS_wpatest) libwpa_client.a |
| 1978 | $(Q)$(LDO) $(LDFLAGS) -o libwpa_test1 $(OBJS_wpatest) libwpa_client.a $(LIBS_c) |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 1979 | @$(E) " LD " $@ |
| 1980 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1981 | libwpa_test2: $(OBJS_wpatest) libwpa_client.so |
| 1982 | $(Q)$(LDO) $(LDFLAGS) -o libwpa_test2 $(OBJS_wpatest) -L. -lwpa_client $(LIBS_c) |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1983 | @$(E) " LD " $@ |
| 1984 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 1985 | _OBJS_VAR := OBJS_nfc |
| 1986 | include ../src/objs.mk |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 1987 | nfc_pw_token: $(OBJS_nfc) |
| 1988 | $(Q)$(LDO) $(LDFLAGS) -o nfc_pw_token $(OBJS_nfc) $(LIBS) |
| 1989 | @$(E) " LD " $@ |
| 1990 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1991 | win_if_list: win_if_list.c |
| 1992 | $(Q)$(LDO) $(LDFLAGS) -o $@ win_if_list.c $(CFLAGS) $(LIBS_w) |
| 1993 | @$(E) " LD " $@ |
| 1994 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 1995 | eap_psk.so: $(SRC_EAP_PSK) |
| 1996 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1997 | -Deap_peer_psk_register=eap_peer_method_dynamic_init |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 1998 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 1999 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2000 | eap_pax.so: $(SRC_EAP_PAX) |
| 2001 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2002 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2003 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2004 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2005 | eap_peap.so: $(SRC_EAP_PEAP) |
| 2006 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2007 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2008 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2009 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2010 | eap_sake.so: $(SRC_EAP_SAKE) |
| 2011 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2012 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2013 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2014 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2015 | eap_ikev2.so: $(SRC_EAP_IKEV2) |
| 2016 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2017 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2018 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2019 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2020 | eap_eke.so: $(SRC_EAP_EKE) |
| 2021 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2022 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2023 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 34af306 | 2013-07-11 10:46:32 -0700 | [diff] [blame] | 2024 | |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2025 | eap_mschapv2.so: $(SRC_EAP_MSCHAPV2) |
| 2026 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2027 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2028 | @$(E) " CC/LD " $@ |
| 2029 | |
| 2030 | eap_fast.so: $(SRC_EAP_FAST) |
| 2031 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2032 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2033 | @$(E) " CC/LD " $@ |
| 2034 | |
| 2035 | eap_teap.so: $(SRC_EAP_TEAP) |
| 2036 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2037 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2038 | @$(E) " CC/LD " $@ |
| 2039 | |
| 2040 | eap_gpsk.so: $(SRC_EAP_GPSK) |
| 2041 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \ |
| 2042 | -D$(@F:eap_%.so=eap_peer_%)_register=eap_peer_method_dynamic_init |
| 2043 | @$(E) " CC/LD " $@ |
| 2044 | |
| 2045 | %.so: ../src/eap_peer/%.c |
| 2046 | $(Q)$(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $< \ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2047 | -D$(*F:eap_%=eap_peer_%)_register=eap_peer_method_dynamic_init |
Hai Shalom | a20dcd7 | 2022-02-04 13:43:00 -0800 | [diff] [blame] | 2048 | @$(E) " CC/LD " $@ |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2049 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 2050 | %.service: %.service.in |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 2051 | $(Q)sed -e 's|\@BINDIR\@|$(BINDIR)|g' $< >$@ |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 2052 | @$(E) " sed" $< |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 2053 | |
Dmitry Shmidt | c5ec7f5 | 2012-03-06 16:33:24 -0800 | [diff] [blame] | 2054 | %@.service: %.service.arg.in |
Hai Shalom | 021b0b5 | 2019-04-10 11:17:58 -0700 | [diff] [blame] | 2055 | $(Q)sed -e 's|\@BINDIR\@|$(BINDIR)|g' $< >$@ |
Dmitry Shmidt | 6c0da2b | 2015-01-05 13:08:17 -0800 | [diff] [blame] | 2056 | @$(E) " sed" $< |
Dmitry Shmidt | c5ec7f5 | 2012-03-06 16:33:24 -0800 | [diff] [blame] | 2057 | |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2058 | wpa_supplicant.exe: wpa_supplicant |
| 2059 | mv -f $< $@ |
| 2060 | wpa_cli.exe: wpa_cli |
| 2061 | mv -f $< $@ |
| 2062 | wpa_passphrase.exe: wpa_passphrase |
| 2063 | mv -f $< $@ |
| 2064 | win_if_list.exe: win_if_list |
| 2065 | mv -f $< $@ |
| 2066 | eapol_test.exe: eapol_test |
| 2067 | mv -f $< $@ |
| 2068 | |
| 2069 | WINALL=wpa_supplicant.exe wpa_cli.exe wpa_passphrase.exe win_if_list.exe |
| 2070 | |
| 2071 | windows-bin: $(WINALL) |
| 2072 | $(STRIP) $(WINALL) |
| 2073 | |
Dmitry Shmidt | 1f69aa5 | 2012-01-24 16:10:04 -0800 | [diff] [blame] | 2074 | wpa_gui: |
| 2075 | @echo "wpa_gui has been removed - see wpa_gui-qt4 for replacement" |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2076 | |
| 2077 | wpa_gui-qt4/Makefile: |
Dmitry Shmidt | 1d755d0 | 2015-04-28 10:34:29 -0700 | [diff] [blame] | 2078 | qmake -o wpa_gui-qt4/Makefile wpa_gui-qt4/wpa_gui.pro |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2079 | |
| 2080 | wpa_gui-qt4/lang/wpa_gui_de.qm: wpa_gui-qt4/lang/wpa_gui_de.ts |
| 2081 | lrelease wpa_gui-qt4/wpa_gui.pro |
| 2082 | |
| 2083 | wpa_gui-qt4: wpa_gui-qt4/Makefile wpa_gui-qt4/lang/wpa_gui_de.qm |
| 2084 | $(MAKE) -C wpa_gui-qt4 |
| 2085 | |
Dmitry Shmidt | 61d9df3 | 2012-08-29 16:22:06 -0700 | [diff] [blame] | 2086 | FIPSDIR=/usr/local/ssl/fips-2.0 |
| 2087 | FIPSLD=$(FIPSDIR)/bin/fipsld |
| 2088 | fips: |
| 2089 | $(MAKE) CC=$(FIPSLD) FIPSLD_CC="$(CC)" |
| 2090 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 2091 | .PHONY: lcov-html |
| 2092 | lcov-html: $(call BUILDOBJ,wpa_supplicant.gcda) |
| 2093 | lcov -c -d $(BUILDDIR) > lcov.info |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 2094 | genhtml lcov.info --output-directory lcov-html |
| 2095 | |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 2096 | clean: common-clean |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2097 | $(MAKE) -C ../src clean |
| 2098 | $(MAKE) -C dbus clean |
Dmitry Shmidt | 01904cf | 2013-12-05 11:08:35 -0800 | [diff] [blame] | 2099 | rm -f core *~ *.o *.d *.gcno *.gcda *.gcov |
Hai Shalom | 899fcc7 | 2020-10-19 14:38:18 -0700 | [diff] [blame] | 2100 | rm -f eap_*.so $(WINALL) eapol_test preauth_test |
Dmitry Shmidt | 8d520ff | 2011-05-09 14:06:53 -0700 | [diff] [blame] | 2101 | rm -f wpa_priv |
Dmitry Shmidt | 0494959 | 2012-07-19 12:16:46 -0700 | [diff] [blame] | 2102 | rm -f nfc_pw_token |
Dmitry Shmidt | fb79edc | 2014-01-10 10:45:54 -0800 | [diff] [blame] | 2103 | rm -f lcov.info |
| 2104 | rm -rf lcov-html |
Dmitry Shmidt | b1e5210 | 2015-05-29 12:36:29 -0700 | [diff] [blame] | 2105 | rm -f libwpa_client.a |
| 2106 | rm -f libwpa_client.so |
Dmitry Shmidt | d80a401 | 2015-11-05 16:35:40 -0800 | [diff] [blame] | 2107 | rm -f libwpa_test1 libwpa_test2 |
Sunil Ravi | a04bd25 | 2022-05-02 22:54:18 -0700 | [diff] [blame] | 2108 | rm -f wpa_passphrase |