Makefile 35 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234123512361237123812391240124112421243124412451246124712481249125012511252125312541255125612571258125912601261126212631264126512661267126812691270127112721273127412751276127712781279128012811282128312841285128612871288128912901291129212931294129512961297129812991300130113021303130413051306130713081309131013111312131313141315131613171318131913201321132213231324132513261327132813291330133113321333133413351336133713381339134013411342134313441345134613471348134913501351135213531354135513561357135813591360136113621363136413651366136713681369137013711372137313741375137613771378137913801381138213831384138513861387138813891390139113921393139413951396139713981399140014011402140314041405140614071408140914101411141214131414141514161417141814191420142114221423142414251426142714281429143014311432143314341435143614371438143914401441144214431444144514461447144814491450145114521453145414551456145714581459146014611462146314641465146614671468146914701471147214731474147514761477147814791480148114821483148414851486148714881489149014911492149314941495149614971498149915001501150215031504150515061507150815091510151115121513151415151516151715181519152015211522152315241525152615271528152915301531153215331534153515361537153815391540154115421543154415451546154715481549155015511552155315541555155615571558155915601561156215631564156515661567156815691570157115721573157415751576157715781579158015811582158315841585158615871588158915901591159215931594159515961597159815991600160116021603160416051606160716081609161016111612161316141615161616171618161916201621162216231624162516261627162816291630163116321633163416351636
  1. ifndef CC
  2. CC=gcc
  3. endif
  4. ifndef CFLAGS
  5. CFLAGS = -MMD -O2 -Wall -g
  6. endif
  7. export LIBDIR ?= /usr/local/lib/
  8. export BINDIR ?= /usr/local/sbin/
  9. PKG_CONFIG ?= pkg-config
  10. CFLAGS += -I../src
  11. CFLAGS += -I../src/utils
  12. -include .config
  13. BINALL=wpa_supplicant wpa_cli
  14. ifndef CONFIG_NO_WPA_PASSPHRASE
  15. BINALL += wpa_passphrase
  16. endif
  17. ALL = $(BINALL)
  18. ALL += systemd/wpa_supplicant.service
  19. ALL += systemd/wpa_supplicant@.service
  20. ALL += systemd/wpa_supplicant-nl80211@.service
  21. ALL += systemd/wpa_supplicant-wired@.service
  22. ALL += dbus/fi.epitest.hostap.WPASupplicant.service
  23. ALL += dbus/fi.w1.wpa_supplicant1.service
  24. all: verify_config $(ALL) dynamic_eap_methods
  25. verify_config:
  26. @if [ ! -r .config ]; then \
  27. echo 'Building wpa_supplicant requires a configuration file'; \
  28. echo '(.config). See README for more instructions. You can'; \
  29. echo 'run "cp defconfig .config" to create an example'; \
  30. echo 'configuration.'; \
  31. exit 1; \
  32. fi
  33. mkconfig:
  34. @if [ -f .config ]; then \
  35. echo '.config exists - did not replace it'; \
  36. exit 1; \
  37. fi
  38. echo CONFIG_DRIVER_HOSTAP=y >> .config
  39. echo CONFIG_DRIVER_WEXT=y >> .config
  40. $(DESTDIR)$(BINDIR)/%: %
  41. install -D $(<) $(@)
  42. install: $(addprefix $(DESTDIR)$(BINDIR)/,$(BINALL))
  43. $(MAKE) -C ../src install
  44. ifdef CONFIG_FIPS
  45. CONFIG_NO_RANDOM_POOL=
  46. CONFIG_OPENSSL_CMAC=y
  47. endif
  48. OBJS = config.o
  49. OBJS += notify.o
  50. OBJS += bss.o
  51. OBJS += eap_register.o
  52. OBJS += ../src/utils/common.o
  53. OBJS += ../src/utils/wpa_debug.o
  54. OBJS += ../src/utils/wpabuf.o
  55. OBJS_p = wpa_passphrase.o
  56. OBJS_p += ../src/utils/common.o
  57. OBJS_p += ../src/utils/wpa_debug.o
  58. OBJS_p += ../src/utils/wpabuf.o
  59. OBJS_c = wpa_cli.o ../src/common/wpa_ctrl.o
  60. OBJS_c += ../src/utils/wpa_debug.o
  61. OBJS_c += ../src/utils/common.o
  62. ifndef CONFIG_OS
  63. ifdef CONFIG_NATIVE_WINDOWS
  64. CONFIG_OS=win32
  65. else
  66. CONFIG_OS=unix
  67. endif
  68. endif
  69. ifeq ($(CONFIG_OS), internal)
  70. CFLAGS += -DOS_NO_C_LIB_DEFINES
  71. endif
  72. OBJS += ../src/utils/os_$(CONFIG_OS).o
  73. OBJS_p += ../src/utils/os_$(CONFIG_OS).o
  74. OBJS_c += ../src/utils/os_$(CONFIG_OS).o
  75. ifdef CONFIG_WPA_TRACE
  76. CFLAGS += -DWPA_TRACE
  77. OBJS += ../src/utils/trace.o
  78. OBJS_p += ../src/utils/trace.o
  79. OBJS_c += ../src/utils/trace.o
  80. OBJS_priv += ../src/utils/trace.o
  81. LDFLAGS += -rdynamic
  82. CFLAGS += -funwind-tables
  83. ifdef CONFIG_WPA_TRACE_BFD
  84. CFLAGS += -DWPA_TRACE_BFD
  85. LIBS += -lbfd
  86. LIBS_p += -lbfd
  87. LIBS_c += -lbfd
  88. endif
  89. endif
  90. ifndef CONFIG_ELOOP
  91. CONFIG_ELOOP=eloop
  92. endif
  93. OBJS += ../src/utils/$(CONFIG_ELOOP).o
  94. OBJS_c += ../src/utils/$(CONFIG_ELOOP).o
  95. ifdef CONFIG_ELOOP_POLL
  96. CFLAGS += -DCONFIG_ELOOP_POLL
  97. endif
  98. ifdef CONFIG_EAPOL_TEST
  99. CFLAGS += -Werror -DEAPOL_TEST
  100. endif
  101. ifdef CONFIG_HT_OVERRIDES
  102. CFLAGS += -DCONFIG_HT_OVERRIDES
  103. endif
  104. ifndef CONFIG_BACKEND
  105. CONFIG_BACKEND=file
  106. endif
  107. ifeq ($(CONFIG_BACKEND), file)
  108. OBJS += config_file.o
  109. ifndef CONFIG_NO_CONFIG_BLOBS
  110. NEED_BASE64=y
  111. endif
  112. CFLAGS += -DCONFIG_BACKEND_FILE
  113. endif
  114. ifeq ($(CONFIG_BACKEND), winreg)
  115. OBJS += config_winreg.o
  116. endif
  117. ifeq ($(CONFIG_BACKEND), none)
  118. OBJS += config_none.o
  119. endif
  120. ifdef CONFIG_NO_CONFIG_WRITE
  121. CFLAGS += -DCONFIG_NO_CONFIG_WRITE
  122. endif
  123. ifdef CONFIG_NO_CONFIG_BLOBS
  124. CFLAGS += -DCONFIG_NO_CONFIG_BLOBS
  125. endif
  126. ifdef CONFIG_NO_SCAN_PROCESSING
  127. CFLAGS += -DCONFIG_NO_SCAN_PROCESSING
  128. endif
  129. ifdef CONFIG_IEEE80211W
  130. CFLAGS += -DCONFIG_IEEE80211W
  131. NEED_SHA256=y
  132. NEED_AES_OMAC1=y
  133. endif
  134. ifdef CONFIG_IEEE80211R
  135. CFLAGS += -DCONFIG_IEEE80211R
  136. OBJS += ../src/rsn_supp/wpa_ft.o
  137. NEED_80211_COMMON=y
  138. NEED_SHA256=y
  139. NEED_AES_OMAC1=y
  140. endif
  141. ifdef CONFIG_SAE
  142. CFLAGS += -DCONFIG_SAE
  143. OBJS += ../src/common/sae.o
  144. NEED_ECC=y
  145. endif
  146. ifdef CONFIG_WNM
  147. CFLAGS += -DCONFIG_WNM
  148. OBJS += wnm_sta.o
  149. endif
  150. ifdef CONFIG_TDLS
  151. CFLAGS += -DCONFIG_TDLS
  152. OBJS += ../src/rsn_supp/tdls.o
  153. NEED_SHA256=y
  154. NEED_AES_OMAC1=y
  155. endif
  156. ifdef CONFIG_TDLS_TESTING
  157. CFLAGS += -DCONFIG_TDLS_TESTING
  158. endif
  159. ifdef CONFIG_PEERKEY
  160. CFLAGS += -DCONFIG_PEERKEY
  161. endif
  162. ifndef CONFIG_NO_WPA
  163. OBJS += ../src/rsn_supp/wpa.o
  164. OBJS += ../src/rsn_supp/preauth.o
  165. OBJS += ../src/rsn_supp/pmksa_cache.o
  166. OBJS += ../src/rsn_supp/peerkey.o
  167. OBJS += ../src/rsn_supp/wpa_ie.o
  168. OBJS += ../src/common/wpa_common.o
  169. NEED_AES=y
  170. NEED_SHA1=y
  171. NEED_MD5=y
  172. NEED_RC4=y
  173. else
  174. CFLAGS += -DCONFIG_NO_WPA -DCONFIG_NO_WPA2
  175. endif
  176. ifdef CONFIG_IBSS_RSN
  177. NEED_RSN_AUTHENTICATOR=y
  178. CFLAGS += -DCONFIG_IBSS_RSN
  179. OBJS += ibss_rsn.o
  180. endif
  181. ifdef CONFIG_P2P
  182. OBJS += p2p_supplicant.o
  183. OBJS += ../src/p2p/p2p.o
  184. OBJS += ../src/p2p/p2p_utils.o
  185. OBJS += ../src/p2p/p2p_parse.o
  186. OBJS += ../src/p2p/p2p_build.o
  187. OBJS += ../src/p2p/p2p_go_neg.o
  188. OBJS += ../src/p2p/p2p_sd.o
  189. OBJS += ../src/p2p/p2p_pd.o
  190. OBJS += ../src/p2p/p2p_invitation.o
  191. OBJS += ../src/p2p/p2p_dev_disc.o
  192. OBJS += ../src/p2p/p2p_group.o
  193. OBJS += ../src/ap/p2p_hostapd.o
  194. CFLAGS += -DCONFIG_P2P
  195. NEED_GAS=y
  196. NEED_OFFCHANNEL=y
  197. NEED_80211_COMMON=y
  198. CONFIG_WPS=y
  199. CONFIG_AP=y
  200. ifdef CONFIG_P2P_STRICT
  201. CFLAGS += -DCONFIG_P2P_STRICT
  202. endif
  203. endif
  204. ifdef CONFIG_WIFI_DISPLAY
  205. CFLAGS += -DCONFIG_WIFI_DISPLAY
  206. OBJS += wifi_display.o
  207. endif
  208. ifdef CONFIG_HS20
  209. OBJS += hs20_supplicant.o
  210. CFLAGS += -DCONFIG_HS20
  211. CONFIG_INTERWORKING=y
  212. endif
  213. ifdef CONFIG_INTERWORKING
  214. OBJS += interworking.o
  215. CFLAGS += -DCONFIG_INTERWORKING
  216. NEED_GAS=y
  217. endif
  218. ifdef CONFIG_NO_WPA2
  219. CFLAGS += -DCONFIG_NO_WPA2
  220. endif
  221. include ../src/drivers/drivers.mak
  222. ifdef CONFIG_AP
  223. OBJS_d += $(DRV_BOTH_OBJS)
  224. CFLAGS += $(DRV_BOTH_CFLAGS)
  225. LDFLAGS += $(DRV_BOTH_LDFLAGS)
  226. LIBS += $(DRV_BOTH_LIBS)
  227. else
  228. NEED_AP_MLME=
  229. OBJS_d += $(DRV_WPA_OBJS)
  230. CFLAGS += $(DRV_WPA_CFLAGS)
  231. LDFLAGS += $(DRV_WPA_LDFLAGS)
  232. LIBS += $(DRV_WPA_LIBS)
  233. endif
  234. ifndef CONFIG_L2_PACKET
  235. CONFIG_L2_PACKET=linux
  236. endif
  237. OBJS_l2 += ../src/l2_packet/l2_packet_$(CONFIG_L2_PACKET).o
  238. ifeq ($(CONFIG_L2_PACKET), pcap)
  239. ifdef CONFIG_WINPCAP
  240. CFLAGS += -DCONFIG_WINPCAP
  241. LIBS += -lwpcap -lpacket
  242. LIBS_w += -lwpcap
  243. else
  244. LIBS += -ldnet -lpcap
  245. endif
  246. endif
  247. ifeq ($(CONFIG_L2_PACKET), winpcap)
  248. LIBS += -lwpcap -lpacket
  249. LIBS_w += -lwpcap
  250. endif
  251. ifeq ($(CONFIG_L2_PACKET), freebsd)
  252. LIBS += -lpcap
  253. endif
  254. ifdef CONFIG_EAP_TLS
  255. # EAP-TLS
  256. ifeq ($(CONFIG_EAP_TLS), dyn)
  257. CFLAGS += -DEAP_TLS_DYNAMIC
  258. EAPDYN += ../src/eap_peer/eap_tls.so
  259. else
  260. CFLAGS += -DEAP_TLS
  261. OBJS += ../src/eap_peer/eap_tls.o
  262. OBJS_h += ../src/eap_server/eap_server_tls.o
  263. endif
  264. TLS_FUNCS=y
  265. CONFIG_IEEE8021X_EAPOL=y
  266. endif
  267. ifdef CONFIG_EAP_UNAUTH_TLS
  268. # EAP-UNAUTH-TLS
  269. CFLAGS += -DEAP_UNAUTH_TLS
  270. ifndef CONFIG_EAP_UNAUTH_TLS
  271. OBJS += ../src/eap_peer/eap_tls.o
  272. OBJS_h += ../src/eap_server/eap_server_tls.o
  273. TLS_FUNCS=y
  274. endif
  275. CONFIG_IEEE8021X_EAPOL=y
  276. endif
  277. ifdef CONFIG_EAP_PEAP
  278. # EAP-PEAP
  279. ifeq ($(CONFIG_EAP_PEAP), dyn)
  280. CFLAGS += -DEAP_PEAP_DYNAMIC
  281. EAPDYN += ../src/eap_peer/eap_peap.so
  282. else
  283. CFLAGS += -DEAP_PEAP
  284. OBJS += ../src/eap_peer/eap_peap.o
  285. OBJS += ../src/eap_common/eap_peap_common.o
  286. OBJS_h += ../src/eap_server/eap_server_peap.o
  287. endif
  288. TLS_FUNCS=y
  289. CONFIG_IEEE8021X_EAPOL=y
  290. endif
  291. ifdef CONFIG_EAP_TTLS
  292. # EAP-TTLS
  293. ifeq ($(CONFIG_EAP_TTLS), dyn)
  294. CFLAGS += -DEAP_TTLS_DYNAMIC
  295. EAPDYN += ../src/eap_peer/eap_ttls.so
  296. else
  297. CFLAGS += -DEAP_TTLS
  298. OBJS += ../src/eap_peer/eap_ttls.o
  299. OBJS_h += ../src/eap_server/eap_server_ttls.o
  300. endif
  301. MS_FUNCS=y
  302. TLS_FUNCS=y
  303. CHAP=y
  304. CONFIG_IEEE8021X_EAPOL=y
  305. endif
  306. ifdef CONFIG_EAP_MD5
  307. # EAP-MD5
  308. ifeq ($(CONFIG_EAP_MD5), dyn)
  309. CFLAGS += -DEAP_MD5_DYNAMIC
  310. EAPDYN += ../src/eap_peer/eap_md5.so
  311. else
  312. CFLAGS += -DEAP_MD5
  313. OBJS += ../src/eap_peer/eap_md5.o
  314. OBJS_h += ../src/eap_server/eap_server_md5.o
  315. endif
  316. CHAP=y
  317. CONFIG_IEEE8021X_EAPOL=y
  318. endif
  319. # backwards compatibility for old spelling
  320. ifdef CONFIG_MSCHAPV2
  321. ifndef CONFIG_EAP_MSCHAPV2
  322. CONFIG_EAP_MSCHAPV2=y
  323. endif
  324. endif
  325. ifdef CONFIG_EAP_MSCHAPV2
  326. # EAP-MSCHAPv2
  327. ifeq ($(CONFIG_EAP_MSCHAPV2), dyn)
  328. CFLAGS += -DEAP_MSCHAPv2_DYNAMIC
  329. EAPDYN += ../src/eap_peer/eap_mschapv2.so
  330. EAPDYN += ../src/eap_peer/mschapv2.so
  331. else
  332. CFLAGS += -DEAP_MSCHAPv2
  333. OBJS += ../src/eap_peer/eap_mschapv2.o
  334. OBJS += ../src/eap_peer/mschapv2.o
  335. OBJS_h += ../src/eap_server/eap_server_mschapv2.o
  336. endif
  337. MS_FUNCS=y
  338. CONFIG_IEEE8021X_EAPOL=y
  339. endif
  340. ifdef CONFIG_EAP_GTC
  341. # EAP-GTC
  342. ifeq ($(CONFIG_EAP_GTC), dyn)
  343. CFLAGS += -DEAP_GTC_DYNAMIC
  344. EAPDYN += ../src/eap_peer/eap_gtc.so
  345. else
  346. CFLAGS += -DEAP_GTC
  347. OBJS += ../src/eap_peer/eap_gtc.o
  348. OBJS_h += ../src/eap_server/eap_server_gtc.o
  349. endif
  350. CONFIG_IEEE8021X_EAPOL=y
  351. endif
  352. ifdef CONFIG_EAP_OTP
  353. # EAP-OTP
  354. ifeq ($(CONFIG_EAP_OTP), dyn)
  355. CFLAGS += -DEAP_OTP_DYNAMIC
  356. EAPDYN += ../src/eap_peer/eap_otp.so
  357. else
  358. CFLAGS += -DEAP_OTP
  359. OBJS += ../src/eap_peer/eap_otp.o
  360. endif
  361. CONFIG_IEEE8021X_EAPOL=y
  362. endif
  363. ifdef CONFIG_EAP_SIM
  364. # EAP-SIM
  365. ifeq ($(CONFIG_EAP_SIM), dyn)
  366. CFLAGS += -DEAP_SIM_DYNAMIC
  367. EAPDYN += ../src/eap_peer/eap_sim.so
  368. else
  369. CFLAGS += -DEAP_SIM
  370. OBJS += ../src/eap_peer/eap_sim.o
  371. OBJS_h += ../src/eap_server/eap_server_sim.o
  372. endif
  373. CONFIG_IEEE8021X_EAPOL=y
  374. CONFIG_EAP_SIM_COMMON=y
  375. NEED_AES_CBC=y
  376. endif
  377. ifdef CONFIG_EAP_LEAP
  378. # EAP-LEAP
  379. ifeq ($(CONFIG_EAP_LEAP), dyn)
  380. CFLAGS += -DEAP_LEAP_DYNAMIC
  381. EAPDYN += ../src/eap_peer/eap_leap.so
  382. else
  383. CFLAGS += -DEAP_LEAP
  384. OBJS += ../src/eap_peer/eap_leap.o
  385. endif
  386. MS_FUNCS=y
  387. CONFIG_IEEE8021X_EAPOL=y
  388. endif
  389. ifdef CONFIG_EAP_PSK
  390. # EAP-PSK
  391. ifeq ($(CONFIG_EAP_PSK), dyn)
  392. CFLAGS += -DEAP_PSK_DYNAMIC
  393. EAPDYN += ../src/eap_peer/eap_psk.so
  394. else
  395. CFLAGS += -DEAP_PSK
  396. OBJS += ../src/eap_peer/eap_psk.o ../src/eap_common/eap_psk_common.o
  397. OBJS_h += ../src/eap_server/eap_server_psk.o
  398. endif
  399. CONFIG_IEEE8021X_EAPOL=y
  400. NEED_AES=y
  401. NEED_AES_OMAC1=y
  402. NEED_AES_ENCBLOCK=y
  403. NEED_AES_EAX=y
  404. endif
  405. ifdef CONFIG_EAP_AKA
  406. # EAP-AKA
  407. ifeq ($(CONFIG_EAP_AKA), dyn)
  408. CFLAGS += -DEAP_AKA_DYNAMIC
  409. EAPDYN += ../src/eap_peer/eap_aka.so
  410. else
  411. CFLAGS += -DEAP_AKA
  412. OBJS += ../src/eap_peer/eap_aka.o
  413. OBJS_h += ../src/eap_server/eap_server_aka.o
  414. endif
  415. CONFIG_IEEE8021X_EAPOL=y
  416. CONFIG_EAP_SIM_COMMON=y
  417. NEED_AES_CBC=y
  418. endif
  419. ifdef CONFIG_EAP_AKA_PRIME
  420. # EAP-AKA'
  421. ifeq ($(CONFIG_EAP_AKA_PRIME), dyn)
  422. CFLAGS += -DEAP_AKA_PRIME_DYNAMIC
  423. else
  424. CFLAGS += -DEAP_AKA_PRIME
  425. endif
  426. NEED_SHA256=y
  427. endif
  428. ifdef CONFIG_EAP_SIM_COMMON
  429. OBJS += ../src/eap_common/eap_sim_common.o
  430. OBJS_h += ../src/eap_server/eap_sim_db.o
  431. NEED_AES=y
  432. NEED_FIPS186_2_PRF=y
  433. endif
  434. ifdef CONFIG_EAP_FAST
  435. # EAP-FAST
  436. ifeq ($(CONFIG_EAP_FAST), dyn)
  437. CFLAGS += -DEAP_FAST_DYNAMIC
  438. EAPDYN += ../src/eap_peer/eap_fast.so
  439. EAPDYN += ../src/eap_common/eap_fast_common.o
  440. else
  441. CFLAGS += -DEAP_FAST
  442. OBJS += ../src/eap_peer/eap_fast.o ../src/eap_peer/eap_fast_pac.o
  443. OBJS += ../src/eap_common/eap_fast_common.o
  444. OBJS_h += ../src/eap_server/eap_server_fast.o
  445. endif
  446. TLS_FUNCS=y
  447. CONFIG_IEEE8021X_EAPOL=y
  448. NEED_T_PRF=y
  449. endif
  450. ifdef CONFIG_EAP_PAX
  451. # EAP-PAX
  452. ifeq ($(CONFIG_EAP_PAX), dyn)
  453. CFLAGS += -DEAP_PAX_DYNAMIC
  454. EAPDYN += ../src/eap_peer/eap_pax.so
  455. else
  456. CFLAGS += -DEAP_PAX
  457. OBJS += ../src/eap_peer/eap_pax.o ../src/eap_common/eap_pax_common.o
  458. OBJS_h += ../src/eap_server/eap_server_pax.o
  459. endif
  460. CONFIG_IEEE8021X_EAPOL=y
  461. endif
  462. ifdef CONFIG_EAP_SAKE
  463. # EAP-SAKE
  464. ifeq ($(CONFIG_EAP_SAKE), dyn)
  465. CFLAGS += -DEAP_SAKE_DYNAMIC
  466. EAPDYN += ../src/eap_peer/eap_sake.so
  467. else
  468. CFLAGS += -DEAP_SAKE
  469. OBJS += ../src/eap_peer/eap_sake.o ../src/eap_common/eap_sake_common.o
  470. OBJS_h += ../src/eap_server/eap_server_sake.o
  471. endif
  472. CONFIG_IEEE8021X_EAPOL=y
  473. endif
  474. ifdef CONFIG_EAP_GPSK
  475. # EAP-GPSK
  476. ifeq ($(CONFIG_EAP_GPSK), dyn)
  477. CFLAGS += -DEAP_GPSK_DYNAMIC
  478. EAPDYN += ../src/eap_peer/eap_gpsk.so
  479. else
  480. CFLAGS += -DEAP_GPSK
  481. OBJS += ../src/eap_peer/eap_gpsk.o ../src/eap_common/eap_gpsk_common.o
  482. OBJS_h += ../src/eap_server/eap_server_gpsk.o
  483. endif
  484. CONFIG_IEEE8021X_EAPOL=y
  485. ifdef CONFIG_EAP_GPSK_SHA256
  486. CFLAGS += -DEAP_GPSK_SHA256
  487. endif
  488. NEED_SHA256=y
  489. NEED_AES_OMAC1=y
  490. endif
  491. ifdef CONFIG_EAP_PWD
  492. CFLAGS += -DEAP_PWD
  493. OBJS += ../src/eap_peer/eap_pwd.o ../src/eap_common/eap_pwd_common.o
  494. OBJS_h += ../src/eap_server/eap_pwd.o
  495. CONFIG_IEEE8021X_EAPOL=y
  496. NEED_SHA256=y
  497. endif
  498. ifdef CONFIG_WPS
  499. ifdef CONFIG_WPS2
  500. CFLAGS += -DCONFIG_WPS2
  501. endif
  502. # EAP-WSC
  503. CFLAGS += -DCONFIG_WPS -DEAP_WSC
  504. OBJS += wps_supplicant.o
  505. OBJS += ../src/utils/uuid.o
  506. OBJS += ../src/eap_peer/eap_wsc.o ../src/eap_common/eap_wsc_common.o
  507. OBJS += ../src/wps/wps.o
  508. OBJS += ../src/wps/wps_common.o
  509. OBJS += ../src/wps/wps_attr_parse.o
  510. OBJS += ../src/wps/wps_attr_build.o
  511. OBJS += ../src/wps/wps_attr_process.o
  512. OBJS += ../src/wps/wps_dev_attr.o
  513. OBJS += ../src/wps/wps_enrollee.o
  514. OBJS += ../src/wps/wps_registrar.o
  515. OBJS_h += ../src/eap_server/eap_server_wsc.o
  516. CONFIG_IEEE8021X_EAPOL=y
  517. NEED_DH_GROUPS=y
  518. NEED_SHA256=y
  519. NEED_BASE64=y
  520. NEED_80211_COMMON=y
  521. NEED_AES_CBC=y
  522. NEED_MODEXP=y
  523. ifdef CONFIG_WPS_NFC
  524. CFLAGS += -DCONFIG_WPS_NFC
  525. OBJS += ../src/wps/ndef.o
  526. NEED_WPS_OOB=y
  527. endif
  528. ifdef NEED_WPS_OOB
  529. CFLAGS += -DCONFIG_WPS_OOB
  530. endif
  531. ifdef CONFIG_WPS_ER
  532. CONFIG_WPS_UPNP=y
  533. CFLAGS += -DCONFIG_WPS_ER
  534. OBJS += ../src/wps/wps_er.o
  535. OBJS += ../src/wps/wps_er_ssdp.o
  536. endif
  537. ifdef CONFIG_WPS_UPNP
  538. CFLAGS += -DCONFIG_WPS_UPNP
  539. OBJS += ../src/wps/wps_upnp.o
  540. OBJS += ../src/wps/wps_upnp_ssdp.o
  541. OBJS += ../src/wps/wps_upnp_web.o
  542. OBJS += ../src/wps/wps_upnp_event.o
  543. OBJS += ../src/wps/wps_upnp_ap.o
  544. OBJS += ../src/wps/upnp_xml.o
  545. OBJS += ../src/wps/httpread.o
  546. OBJS += ../src/wps/http_client.o
  547. OBJS += ../src/wps/http_server.o
  548. endif
  549. ifdef CONFIG_WPS_STRICT
  550. CFLAGS += -DCONFIG_WPS_STRICT
  551. OBJS += ../src/wps/wps_validate.o
  552. endif
  553. ifdef CONFIG_WPS_TESTING
  554. CFLAGS += -DCONFIG_WPS_TESTING
  555. endif
  556. ifdef CONFIG_WPS_REG_DISABLE_OPEN
  557. CFLAGS += -DCONFIG_WPS_REG_DISABLE_OPEN
  558. endif
  559. endif
  560. ifdef CONFIG_EAP_IKEV2
  561. # EAP-IKEv2
  562. ifeq ($(CONFIG_EAP_IKEV2), dyn)
  563. CFLAGS += -DEAP_IKEV2_DYNAMIC
  564. EAPDYN += ../src/eap_peer/eap_ikev2.so ../src/eap_peer/ikev2.o
  565. EAPDYN += ../src/eap_common/eap_ikev2_common.o ../src/eap_common/ikev2_common.o
  566. else
  567. CFLAGS += -DEAP_IKEV2
  568. OBJS += ../src/eap_peer/eap_ikev2.o ../src/eap_peer/ikev2.o
  569. OBJS += ../src/eap_common/eap_ikev2_common.o ../src/eap_common/ikev2_common.o
  570. OBJS_h += ../src/eap_server/eap_server_ikev2.o
  571. OBJS_h += ../src/eap_server/ikev2.o
  572. endif
  573. CONFIG_IEEE8021X_EAPOL=y
  574. NEED_DH_GROUPS=y
  575. NEED_DH_GROUPS_ALL=y
  576. NEED_MODEXP=y
  577. NEED_CIPHER=y
  578. endif
  579. ifdef CONFIG_EAP_VENDOR_TEST
  580. ifeq ($(CONFIG_EAP_VENDOR_TEST), dyn)
  581. CFLAGS += -DEAP_VENDOR_TEST_DYNAMIC
  582. EAPDYN += ../src/eap_peer/eap_vendor_test.so
  583. else
  584. CFLAGS += -DEAP_VENDOR_TEST
  585. OBJS += ../src/eap_peer/eap_vendor_test.o
  586. OBJS_h += ../src/eap_server/eap_server_vendor_test.o
  587. endif
  588. CONFIG_IEEE8021X_EAPOL=y
  589. endif
  590. ifdef CONFIG_EAP_TNC
  591. # EAP-TNC
  592. CFLAGS += -DEAP_TNC
  593. OBJS += ../src/eap_peer/eap_tnc.o
  594. OBJS += ../src/eap_peer/tncc.o
  595. OBJS_h += ../src/eap_server/eap_server_tnc.o
  596. OBJS_h += ../src/eap_server/tncs.o
  597. NEED_BASE64=y
  598. ifndef CONFIG_NATIVE_WINDOWS
  599. ifndef CONFIG_DRIVER_BSD
  600. LIBS += -ldl
  601. endif
  602. endif
  603. endif
  604. ifdef CONFIG_IEEE8021X_EAPOL
  605. # IEEE 802.1X/EAPOL state machines (e.g., for RADIUS authentication)
  606. CFLAGS += -DIEEE8021X_EAPOL
  607. OBJS += ../src/eapol_supp/eapol_supp_sm.o
  608. OBJS += ../src/eap_peer/eap.o ../src/eap_peer/eap_methods.o
  609. NEED_EAP_COMMON=y
  610. ifdef CONFIG_DYNAMIC_EAP_METHODS
  611. CFLAGS += -DCONFIG_DYNAMIC_EAP_METHODS
  612. LIBS += -ldl -rdynamic
  613. endif
  614. endif
  615. ifdef CONFIG_AP
  616. NEED_80211_COMMON=y
  617. NEED_EAP_COMMON=y
  618. NEED_RSN_AUTHENTICATOR=y
  619. CFLAGS += -DCONFIG_AP
  620. OBJS += ap.o
  621. CFLAGS += -DCONFIG_NO_RADIUS
  622. CFLAGS += -DCONFIG_NO_ACCOUNTING
  623. CFLAGS += -DCONFIG_NO_VLAN
  624. OBJS += ../src/ap/hostapd.o
  625. OBJS += ../src/ap/wpa_auth_glue.o
  626. OBJS += ../src/ap/utils.o
  627. OBJS += ../src/ap/authsrv.o
  628. OBJS += ../src/ap/ap_config.o
  629. OBJS += ../src/utils/ip_addr.o
  630. OBJS += ../src/ap/sta_info.o
  631. OBJS += ../src/ap/tkip_countermeasures.o
  632. OBJS += ../src/ap/ap_mlme.o
  633. OBJS += ../src/ap/ieee802_1x.o
  634. OBJS += ../src/eapol_auth/eapol_auth_sm.o
  635. OBJS += ../src/ap/ieee802_11_auth.o
  636. OBJS += ../src/ap/ieee802_11_shared.o
  637. OBJS += ../src/ap/drv_callbacks.o
  638. OBJS += ../src/ap/ap_drv_ops.o
  639. OBJS += ../src/ap/beacon.o
  640. OBJS += ../src/ap/eap_user_db.o
  641. ifdef CONFIG_IEEE80211N
  642. OBJS += ../src/ap/ieee802_11_ht.o
  643. endif
  644. ifdef CONFIG_WNM
  645. OBJS += ../src/ap/wnm_ap.o
  646. endif
  647. ifdef CONFIG_CTRL_IFACE
  648. OBJS += ../src/ap/ctrl_iface_ap.o
  649. endif
  650. CFLAGS += -DEAP_SERVER -DEAP_SERVER_IDENTITY
  651. OBJS += ../src/eap_server/eap_server.o
  652. OBJS += ../src/eap_server/eap_server_identity.o
  653. OBJS += ../src/eap_server/eap_server_methods.o
  654. ifdef CONFIG_IEEE80211N
  655. CFLAGS += -DCONFIG_IEEE80211N
  656. endif
  657. ifdef NEED_AP_MLME
  658. OBJS += ../src/ap/wmm.o
  659. OBJS += ../src/ap/ap_list.o
  660. OBJS += ../src/ap/ieee802_11.o
  661. OBJS += ../src/ap/hw_features.o
  662. CFLAGS += -DNEED_AP_MLME
  663. endif
  664. ifdef CONFIG_WPS
  665. CFLAGS += -DEAP_SERVER_WSC
  666. OBJS += ../src/ap/wps_hostapd.o
  667. OBJS += ../src/eap_server/eap_server_wsc.o
  668. endif
  669. ifdef CONFIG_INTERWORKING
  670. OBJS += ../src/ap/gas_serv.o
  671. endif
  672. ifdef CONFIG_HS20
  673. OBJS += ../src/ap/hs20.o
  674. endif
  675. endif
  676. ifdef NEED_RSN_AUTHENTICATOR
  677. CFLAGS += -DCONFIG_NO_RADIUS
  678. NEED_AES_WRAP=y
  679. OBJS += ../src/ap/wpa_auth.o
  680. OBJS += ../src/ap/wpa_auth_ie.o
  681. OBJS += ../src/ap/pmksa_cache_auth.o
  682. ifdef CONFIG_IEEE80211R
  683. OBJS += ../src/ap/wpa_auth_ft.o
  684. endif
  685. ifdef CONFIG_PEERKEY
  686. OBJS += ../src/ap/peerkey_auth.o
  687. endif
  688. endif
  689. ifdef CONFIG_EAP_SERVER
  690. CFLAGS += -DEAP_SERVER
  691. OBJS_h += ../src/eap_server/eap_server.o
  692. OBJS_h += ../src/eap_server/eap_server_identity.o
  693. OBJS_h += ../src/eap_server/eap_server_methods.o
  694. endif
  695. ifdef CONFIG_RADIUS_CLIENT
  696. OBJS_h += ../src/utils/ip_addr.o
  697. OBJS_h += ../src/radius/radius.o
  698. OBJS_h += ../src/radius/radius_client.o
  699. endif
  700. ifdef CONFIG_AUTHENTICATOR
  701. OBJS_h += ../src/eapol_auth/eapol_auth_sm.o
  702. OBJS_h += ../src/ap/ieee802_1x.o
  703. endif
  704. ifdef CONFIG_WPA_AUTHENTICATOR
  705. OBJS_h += ../src/ap/wpa_auth.o
  706. OBJS_h += ../src/ap/wpa_auth_ie.o
  707. OBJS_h += ../src/ap/pmksa_cache_auth.o
  708. ifdef CONFIG_IEEE80211R
  709. OBJS_h += ../src/ap/wpa_auth_ft.o
  710. endif
  711. ifdef CONFIG_PEERKEY
  712. OBJS_h += ../src/ap/peerkey_auth.o
  713. endif
  714. endif
  715. ifdef CONFIG_PCSC
  716. # PC/SC interface for smartcards (USIM, GSM SIM)
  717. CFLAGS += -DPCSC_FUNCS -I/usr/include/PCSC
  718. OBJS += ../src/utils/pcsc_funcs.o
  719. # -lpthread may not be needed depending on how pcsc-lite was configured
  720. ifdef CONFIG_NATIVE_WINDOWS
  721. #Once MinGW gets support for WinScard, -lwinscard could be used instead of the
  722. #dynamic symbol loading that is now used in pcsc_funcs.c
  723. #LIBS += -lwinscard
  724. else
  725. LIBS += -lpcsclite -lpthread
  726. endif
  727. endif
  728. ifdef CONFIG_SIM_SIMULATOR
  729. CFLAGS += -DCONFIG_SIM_SIMULATOR
  730. NEED_MILENAGE=y
  731. endif
  732. ifdef CONFIG_USIM_SIMULATOR
  733. CFLAGS += -DCONFIG_USIM_SIMULATOR
  734. NEED_MILENAGE=y
  735. endif
  736. ifdef NEED_MILENAGE
  737. OBJS += ../src/crypto/milenage.o
  738. NEED_AES_ENCBLOCK=y
  739. endif
  740. ifdef CONFIG_PKCS12
  741. CFLAGS += -DPKCS12_FUNCS
  742. endif
  743. ifdef CONFIG_SMARTCARD
  744. CFLAGS += -DCONFIG_SMARTCARD
  745. endif
  746. ifdef MS_FUNCS
  747. OBJS += ../src/crypto/ms_funcs.o
  748. NEED_DES=y
  749. NEED_MD4=y
  750. endif
  751. ifdef CHAP
  752. OBJS += ../src/eap_common/chap.o
  753. endif
  754. ifdef TLS_FUNCS
  755. NEED_DES=y
  756. # Shared TLS functions (needed for EAP_TLS, EAP_PEAP, EAP_TTLS, and EAP_FAST)
  757. OBJS += ../src/eap_peer/eap_tls_common.o
  758. OBJS_h += ../src/eap_server/eap_server_tls_common.o
  759. ifndef CONFIG_FIPS
  760. NEED_TLS_PRF=y
  761. NEED_SHA1=y
  762. NEED_MD5=y
  763. endif
  764. endif
  765. ifndef CONFIG_TLS
  766. CONFIG_TLS=openssl
  767. endif
  768. ifdef CONFIG_TLSV11
  769. CFLAGS += -DCONFIG_TLSV11
  770. endif
  771. ifdef CONFIG_TLSV12
  772. CFLAGS += -DCONFIG_TLSV12
  773. NEED_SHA256=y
  774. endif
  775. ifeq ($(CONFIG_TLS), openssl)
  776. ifdef TLS_FUNCS
  777. CFLAGS += -DEAP_TLS_OPENSSL
  778. OBJS += ../src/crypto/tls_openssl.o
  779. LIBS += -lssl
  780. endif
  781. OBJS += ../src/crypto/crypto_openssl.o
  782. OBJS_p += ../src/crypto/crypto_openssl.o
  783. ifdef NEED_FIPS186_2_PRF
  784. OBJS += ../src/crypto/fips_prf_openssl.o
  785. endif
  786. LIBS += -lcrypto
  787. LIBS_p += -lcrypto
  788. ifdef CONFIG_TLS_ADD_DL
  789. LIBS += -ldl
  790. LIBS_p += -ldl
  791. endif
  792. endif
  793. ifeq ($(CONFIG_TLS), gnutls)
  794. ifdef TLS_FUNCS
  795. OBJS += ../src/crypto/tls_gnutls.o
  796. LIBS += -lgnutls -lgpg-error
  797. endif
  798. OBJS += ../src/crypto/crypto_gnutls.o
  799. OBJS_p += ../src/crypto/crypto_gnutls.o
  800. ifdef NEED_FIPS186_2_PRF
  801. OBJS += ../src/crypto/fips_prf_gnutls.o
  802. endif
  803. LIBS += -lgcrypt
  804. LIBS_p += -lgcrypt
  805. CONFIG_INTERNAL_SHA256=y
  806. CONFIG_INTERNAL_RC4=y
  807. CONFIG_INTERNAL_DH_GROUP5=y
  808. endif
  809. ifeq ($(CONFIG_TLS), schannel)
  810. ifdef TLS_FUNCS
  811. OBJS += ../src/crypto/tls_schannel.o
  812. endif
  813. OBJS += ../src/crypto/crypto_cryptoapi.o
  814. OBJS_p += ../src/crypto/crypto_cryptoapi.o
  815. ifdef NEED_FIPS186_2_PRF
  816. OBJS += ../src/crypto/fips_prf_cryptoapi.o
  817. endif
  818. CONFIG_INTERNAL_SHA256=y
  819. CONFIG_INTERNAL_RC4=y
  820. CONFIG_INTERNAL_DH_GROUP5=y
  821. endif
  822. ifeq ($(CONFIG_TLS), nss)
  823. ifdef TLS_FUNCS
  824. OBJS += ../src/crypto/tls_nss.o
  825. LIBS += -lssl3
  826. endif
  827. OBJS += ../src/crypto/crypto_nss.o
  828. OBJS_p += ../src/crypto/crypto_nss.o
  829. ifdef NEED_FIPS186_2_PRF
  830. OBJS += ../src/crypto/fips_prf_nss.o
  831. endif
  832. LIBS += -lnss3
  833. LIBS_p += -lnss3
  834. CONFIG_INTERNAL_MD4=y
  835. CONFIG_INTERNAL_DH_GROUP5=y
  836. endif
  837. ifeq ($(CONFIG_TLS), internal)
  838. ifndef CONFIG_CRYPTO
  839. CONFIG_CRYPTO=internal
  840. endif
  841. ifdef TLS_FUNCS
  842. OBJS += ../src/crypto/crypto_internal-rsa.o
  843. OBJS += ../src/crypto/tls_internal.o
  844. OBJS += ../src/tls/tlsv1_common.o
  845. OBJS += ../src/tls/tlsv1_record.o
  846. OBJS += ../src/tls/tlsv1_cred.o
  847. OBJS += ../src/tls/tlsv1_client.o
  848. OBJS += ../src/tls/tlsv1_client_write.o
  849. OBJS += ../src/tls/tlsv1_client_read.o
  850. OBJS += ../src/tls/asn1.o
  851. OBJS += ../src/tls/rsa.o
  852. OBJS += ../src/tls/x509v3.o
  853. OBJS += ../src/tls/pkcs1.o
  854. OBJS += ../src/tls/pkcs5.o
  855. OBJS += ../src/tls/pkcs8.o
  856. NEED_SHA256=y
  857. NEED_BASE64=y
  858. NEED_TLS_PRF=y
  859. ifdef CONFIG_TLSV12
  860. NEED_TLS_PRF_SHA256=y
  861. endif
  862. NEED_MODEXP=y
  863. NEED_CIPHER=y
  864. CFLAGS += -DCONFIG_TLS_INTERNAL_CLIENT
  865. endif
  866. ifdef NEED_CIPHER
  867. NEED_DES=y
  868. OBJS += ../src/crypto/crypto_internal-cipher.o
  869. endif
  870. ifdef NEED_MODEXP
  871. OBJS += ../src/crypto/crypto_internal-modexp.o
  872. OBJS += ../src/tls/bignum.o
  873. endif
  874. ifeq ($(CONFIG_CRYPTO), libtomcrypt)
  875. OBJS += ../src/crypto/crypto_libtomcrypt.o
  876. OBJS_p += ../src/crypto/crypto_libtomcrypt.o
  877. LIBS += -ltomcrypt -ltfm
  878. LIBS_p += -ltomcrypt -ltfm
  879. CONFIG_INTERNAL_SHA256=y
  880. CONFIG_INTERNAL_RC4=y
  881. CONFIG_INTERNAL_DH_GROUP5=y
  882. endif
  883. ifeq ($(CONFIG_CRYPTO), internal)
  884. OBJS += ../src/crypto/crypto_internal.o
  885. OBJS_p += ../src/crypto/crypto_internal.o
  886. NEED_AES_ENC=y
  887. CFLAGS += -DCONFIG_CRYPTO_INTERNAL
  888. ifdef CONFIG_INTERNAL_LIBTOMMATH
  889. CFLAGS += -DCONFIG_INTERNAL_LIBTOMMATH
  890. ifdef CONFIG_INTERNAL_LIBTOMMATH_FAST
  891. CFLAGS += -DLTM_FAST
  892. endif
  893. else
  894. LIBS += -ltommath
  895. LIBS_p += -ltommath
  896. endif
  897. CONFIG_INTERNAL_AES=y
  898. CONFIG_INTERNAL_DES=y
  899. CONFIG_INTERNAL_SHA1=y
  900. CONFIG_INTERNAL_MD4=y
  901. CONFIG_INTERNAL_MD5=y
  902. CONFIG_INTERNAL_SHA256=y
  903. CONFIG_INTERNAL_RC4=y
  904. CONFIG_INTERNAL_DH_GROUP5=y
  905. endif
  906. ifeq ($(CONFIG_CRYPTO), cryptoapi)
  907. OBJS += ../src/crypto/crypto_cryptoapi.o
  908. OBJS_p += ../src/crypto/crypto_cryptoapi.o
  909. CFLAGS += -DCONFIG_CRYPTO_CRYPTOAPI
  910. CONFIG_INTERNAL_SHA256=y
  911. CONFIG_INTERNAL_RC4=y
  912. endif
  913. endif
  914. ifeq ($(CONFIG_TLS), none)
  915. ifdef TLS_FUNCS
  916. OBJS += ../src/crypto/tls_none.o
  917. CFLAGS += -DEAP_TLS_NONE
  918. CONFIG_INTERNAL_AES=y
  919. CONFIG_INTERNAL_SHA1=y
  920. CONFIG_INTERNAL_MD5=y
  921. endif
  922. OBJS += ../src/crypto/crypto_none.o
  923. OBJS_p += ../src/crypto/crypto_none.o
  924. CONFIG_INTERNAL_SHA256=y
  925. CONFIG_INTERNAL_RC4=y
  926. endif
  927. ifdef TLS_FUNCS
  928. ifdef CONFIG_SMARTCARD
  929. ifndef CONFIG_NATIVE_WINDOWS
  930. ifneq ($(CONFIG_L2_PACKET), freebsd)
  931. LIBS += -ldl
  932. endif
  933. endif
  934. endif
  935. endif
  936. ifndef TLS_FUNCS
  937. OBJS += ../src/crypto/tls_none.o
  938. ifeq ($(CONFIG_TLS), internal)
  939. CONFIG_INTERNAL_AES=y
  940. CONFIG_INTERNAL_SHA1=y
  941. CONFIG_INTERNAL_MD5=y
  942. CONFIG_INTERNAL_RC4=y
  943. endif
  944. endif
  945. AESOBJS = # none so far (see below)
  946. ifdef CONFIG_INTERNAL_AES
  947. AESOBJS += ../src/crypto/aes-internal.o ../src/crypto/aes-internal-dec.o
  948. endif
  949. AESOBJS += ../src/crypto/aes-unwrap.o
  950. ifdef NEED_AES_EAX
  951. AESOBJS += ../src/crypto/aes-eax.o
  952. NEED_AES_CTR=y
  953. endif
  954. ifdef NEED_AES_CTR
  955. AESOBJS += ../src/crypto/aes-ctr.o
  956. endif
  957. ifdef NEED_AES_ENCBLOCK
  958. AESOBJS += ../src/crypto/aes-encblock.o
  959. endif
  960. ifdef NEED_AES_OMAC1
  961. NEED_AES_ENC=y
  962. ifdef CONFIG_OPENSSL_CMAC
  963. CFLAGS += -DCONFIG_OPENSSL_CMAC
  964. else
  965. AESOBJS += ../src/crypto/aes-omac1.o
  966. endif
  967. endif
  968. ifdef NEED_AES_WRAP
  969. NEED_AES_ENC=y
  970. AESOBJS += ../src/crypto/aes-wrap.o
  971. endif
  972. ifdef NEED_AES_CBC
  973. NEED_AES_ENC=y
  974. AESOBJS += ../src/crypto/aes-cbc.o
  975. endif
  976. ifdef NEED_AES_ENC
  977. ifdef CONFIG_INTERNAL_AES
  978. AESOBJS += ../src/crypto/aes-internal-enc.o
  979. endif
  980. endif
  981. ifdef NEED_AES
  982. OBJS += $(AESOBJS)
  983. endif
  984. ifdef NEED_SHA1
  985. ifneq ($(CONFIG_TLS), openssl)
  986. SHA1OBJS += ../src/crypto/sha1.o
  987. endif
  988. SHA1OBJS += ../src/crypto/sha1-prf.o
  989. ifdef CONFIG_INTERNAL_SHA1
  990. SHA1OBJS += ../src/crypto/sha1-internal.o
  991. ifdef NEED_FIPS186_2_PRF
  992. SHA1OBJS += ../src/crypto/fips_prf_internal.o
  993. endif
  994. endif
  995. ifdef CONFIG_NO_WPA_PASSPHRASE
  996. CFLAGS += -DCONFIG_NO_PBKDF2
  997. else
  998. ifneq ($(CONFIG_TLS), openssl)
  999. SHA1OBJS += ../src/crypto/sha1-pbkdf2.o
  1000. endif
  1001. endif
  1002. ifdef NEED_T_PRF
  1003. SHA1OBJS += ../src/crypto/sha1-tprf.o
  1004. endif
  1005. ifdef NEED_TLS_PRF
  1006. SHA1OBJS += ../src/crypto/sha1-tlsprf.o
  1007. endif
  1008. endif
  1009. ifndef CONFIG_FIPS
  1010. MD5OBJS += ../src/crypto/md5.o
  1011. endif
  1012. ifdef NEED_MD5
  1013. ifdef CONFIG_INTERNAL_MD5
  1014. MD5OBJS += ../src/crypto/md5-internal.o
  1015. endif
  1016. OBJS += $(MD5OBJS)
  1017. OBJS_p += $(MD5OBJS)
  1018. endif
  1019. ifdef NEED_MD4
  1020. ifdef CONFIG_INTERNAL_MD4
  1021. OBJS += ../src/crypto/md4-internal.o
  1022. endif
  1023. endif
  1024. DESOBJS = # none needed when not internal
  1025. ifdef NEED_DES
  1026. ifdef CONFIG_INTERNAL_DES
  1027. DESOBJS += ../src/crypto/des-internal.o
  1028. endif
  1029. endif
  1030. ifdef NEED_RC4
  1031. ifdef CONFIG_INTERNAL_RC4
  1032. OBJS += ../src/crypto/rc4.o
  1033. endif
  1034. endif
  1035. SHA256OBJS = # none by default
  1036. ifdef NEED_SHA256
  1037. CFLAGS += -DCONFIG_SHA256
  1038. ifneq ($(CONFIG_TLS), openssl)
  1039. SHA256OBJS += ../src/crypto/sha256.o
  1040. endif
  1041. SHA256OBJS += ../src/crypto/sha256-prf.o
  1042. ifdef CONFIG_INTERNAL_SHA256
  1043. SHA256OBJS += ../src/crypto/sha256-internal.o
  1044. endif
  1045. ifdef NEED_TLS_PRF_SHA256
  1046. SHA256OBJS += ../src/crypto/sha256-tlsprf.o
  1047. endif
  1048. OBJS += $(SHA256OBJS)
  1049. endif
  1050. ifdef NEED_DH_GROUPS
  1051. OBJS += ../src/crypto/dh_groups.o
  1052. endif
  1053. ifdef NEED_DH_GROUPS_ALL
  1054. CFLAGS += -DALL_DH_GROUPS
  1055. endif
  1056. ifdef CONFIG_INTERNAL_DH_GROUP5
  1057. ifdef NEED_DH_GROUPS
  1058. OBJS += ../src/crypto/dh_group5.o
  1059. endif
  1060. endif
  1061. ifdef NEED_ECC
  1062. CFLAGS += -DCONFIG_ECC
  1063. endif
  1064. ifdef CONFIG_NO_RANDOM_POOL
  1065. CFLAGS += -DCONFIG_NO_RANDOM_POOL
  1066. else
  1067. OBJS += ../src/crypto/random.o
  1068. endif
  1069. ifdef CONFIG_CTRL_IFACE
  1070. ifeq ($(CONFIG_CTRL_IFACE), y)
  1071. ifdef CONFIG_NATIVE_WINDOWS
  1072. CONFIG_CTRL_IFACE=named_pipe
  1073. else
  1074. CONFIG_CTRL_IFACE=unix
  1075. endif
  1076. endif
  1077. CFLAGS += -DCONFIG_CTRL_IFACE
  1078. ifeq ($(CONFIG_CTRL_IFACE), unix)
  1079. CFLAGS += -DCONFIG_CTRL_IFACE_UNIX
  1080. endif
  1081. ifeq ($(CONFIG_CTRL_IFACE), udp)
  1082. CFLAGS += -DCONFIG_CTRL_IFACE_UDP
  1083. endif
  1084. ifeq ($(CONFIG_CTRL_IFACE), named_pipe)
  1085. CFLAGS += -DCONFIG_CTRL_IFACE_NAMED_PIPE
  1086. endif
  1087. ifeq ($(CONFIG_CTRL_IFACE), udp-remote)
  1088. CONFIG_CTRL_IFACE=udp
  1089. CFLAGS += -DCONFIG_CTRL_IFACE_UDP
  1090. CFLAGS += -DCONFIG_CTRL_IFACE_UDP_REMOTE
  1091. endif
  1092. OBJS += ctrl_iface.o ctrl_iface_$(CONFIG_CTRL_IFACE).o
  1093. endif
  1094. ifdef CONFIG_CTRL_IFACE_DBUS
  1095. DBUS=y
  1096. DBUS_CFLAGS += -DCONFIG_CTRL_IFACE_DBUS -DDBUS_API_SUBJECT_TO_CHANGE
  1097. DBUS_OBJS += dbus/dbus_old.o dbus/dbus_old_handlers.o
  1098. ifdef CONFIG_WPS
  1099. DBUS_OBJS += dbus/dbus_old_handlers_wps.o
  1100. endif
  1101. DBUS_OBJS += dbus/dbus_dict_helpers.o
  1102. ifndef DBUS_LIBS
  1103. DBUS_LIBS := $(shell $(PKG_CONFIG) --libs dbus-1)
  1104. endif
  1105. ifndef DBUS_INCLUDE
  1106. DBUS_INCLUDE := $(shell $(PKG_CONFIG) --cflags dbus-1)
  1107. endif
  1108. DBUS_CFLAGS += $(DBUS_INCLUDE)
  1109. endif
  1110. ifdef CONFIG_CTRL_IFACE_DBUS_NEW
  1111. DBUS=y
  1112. DBUS_CFLAGS += -DCONFIG_CTRL_IFACE_DBUS_NEW
  1113. DBUS_OBJS ?= dbus/dbus_dict_helpers.o
  1114. DBUS_OBJS += dbus/dbus_new_helpers.o
  1115. DBUS_OBJS += dbus/dbus_new.o dbus/dbus_new_handlers.o
  1116. ifdef CONFIG_WPS
  1117. DBUS_OBJS += dbus/dbus_new_handlers_wps.o
  1118. endif
  1119. ifdef CONFIG_P2P
  1120. DBUS_OBJS += dbus/dbus_new_handlers_p2p.o
  1121. endif
  1122. ifndef DBUS_LIBS
  1123. DBUS_LIBS := $(shell $(PKG_CONFIG) --libs dbus-1)
  1124. endif
  1125. ifndef DBUS_INCLUDE
  1126. DBUS_INCLUDE := $(shell $(PKG_CONFIG) --cflags dbus-1)
  1127. endif
  1128. ifdef CONFIG_CTRL_IFACE_DBUS_INTRO
  1129. DBUS_OBJS += dbus/dbus_new_introspect.o
  1130. DBUS_CFLAGS += -DCONFIG_CTRL_IFACE_DBUS_INTRO
  1131. endif
  1132. DBUS_CFLAGS += $(DBUS_INCLUDE)
  1133. endif
  1134. ifdef DBUS
  1135. DBUS_CFLAGS += -DCONFIG_DBUS
  1136. DBUS_OBJS += dbus/dbus_common.o
  1137. endif
  1138. OBJS += $(DBUS_OBJS)
  1139. CFLAGS += $(DBUS_CFLAGS)
  1140. LIBS += $(DBUS_LIBS)
  1141. ifdef CONFIG_READLINE
  1142. OBJS_c += ../src/utils/edit_readline.o
  1143. LIBS_c += -lncurses -lreadline
  1144. else
  1145. ifdef CONFIG_WPA_CLI_EDIT
  1146. OBJS_c += ../src/utils/edit.o
  1147. else
  1148. OBJS_c += ../src/utils/edit_simple.o
  1149. endif
  1150. endif
  1151. ifdef CONFIG_NATIVE_WINDOWS
  1152. CFLAGS += -DCONFIG_NATIVE_WINDOWS
  1153. LIBS += -lws2_32 -lgdi32 -lcrypt32
  1154. LIBS_c += -lws2_32
  1155. LIBS_p += -lws2_32 -lgdi32
  1156. ifeq ($(CONFIG_CRYPTO), cryptoapi)
  1157. LIBS_p += -lcrypt32
  1158. endif
  1159. endif
  1160. ifdef CONFIG_NO_STDOUT_DEBUG
  1161. CFLAGS += -DCONFIG_NO_STDOUT_DEBUG
  1162. ifndef CONFIG_CTRL_IFACE
  1163. CFLAGS += -DCONFIG_NO_WPA_MSG
  1164. endif
  1165. endif
  1166. ifdef CONFIG_IPV6
  1167. # for eapol_test only
  1168. CFLAGS += -DCONFIG_IPV6
  1169. endif
  1170. ifdef NEED_BASE64
  1171. OBJS += ../src/utils/base64.o
  1172. endif
  1173. ifdef NEED_SME
  1174. NEED_80211_COMMON=y
  1175. OBJS += sme.o
  1176. CFLAGS += -DCONFIG_SME
  1177. endif
  1178. ifdef NEED_80211_COMMON
  1179. OBJS += ../src/common/ieee802_11_common.o
  1180. endif
  1181. ifdef NEED_EAP_COMMON
  1182. OBJS += ../src/eap_common/eap_common.o
  1183. endif
  1184. ifndef CONFIG_MAIN
  1185. CONFIG_MAIN=main
  1186. endif
  1187. ifdef CONFIG_DEBUG_SYSLOG
  1188. CFLAGS += -DCONFIG_DEBUG_SYSLOG
  1189. ifdef CONFIG_DEBUG_SYSLOG_FACILITY
  1190. CFLAGS += -DLOG_HOSTAPD="$(CONFIG_DEBUG_SYSLOG_FACILITY)"
  1191. endif
  1192. endif
  1193. ifdef CONFIG_DEBUG_LINUX_TRACING
  1194. CFLAGS += -DCONFIG_DEBUG_LINUX_TRACING
  1195. endif
  1196. ifdef CONFIG_DEBUG_FILE
  1197. CFLAGS += -DCONFIG_DEBUG_FILE
  1198. endif
  1199. ifdef CONFIG_DELAYED_MIC_ERROR_REPORT
  1200. CFLAGS += -DCONFIG_DELAYED_MIC_ERROR_REPORT
  1201. endif
  1202. ifdef CONFIG_FIPS
  1203. CFLAGS += -DCONFIG_FIPS
  1204. ifneq ($(CONFIG_TLS), openssl)
  1205. $(error CONFIG_FIPS=y requires CONFIG_TLS=openssl)
  1206. endif
  1207. endif
  1208. OBJS += $(SHA1OBJS) $(DESOBJS)
  1209. OBJS_p += $(SHA1OBJS)
  1210. OBJS_p += $(SHA256OBJS)
  1211. ifdef CONFIG_BGSCAN_SIMPLE
  1212. CFLAGS += -DCONFIG_BGSCAN_SIMPLE
  1213. OBJS += bgscan_simple.o
  1214. NEED_BGSCAN=y
  1215. endif
  1216. ifdef CONFIG_BGSCAN_LEARN
  1217. CFLAGS += -DCONFIG_BGSCAN_LEARN
  1218. OBJS += bgscan_learn.o
  1219. NEED_BGSCAN=y
  1220. endif
  1221. ifdef NEED_BGSCAN
  1222. CFLAGS += -DCONFIG_BGSCAN
  1223. OBJS += bgscan.o
  1224. endif
  1225. ifdef CONFIG_AUTOSCAN_EXPONENTIAL
  1226. CFLAGS += -DCONFIG_AUTOSCAN_EXPONENTIAL
  1227. OBJS += autoscan_exponential.o
  1228. NEED_AUTOSCAN=y
  1229. endif
  1230. ifdef CONFIG_AUTOSCAN_PERIODIC
  1231. CFLAGS += -DCONFIG_AUTOSCAN_PERIODIC
  1232. OBJS += autoscan_periodic.o
  1233. NEED_AUTOSCAN=y
  1234. endif
  1235. ifdef NEED_AUTOSCAN
  1236. CFLAGS += -DCONFIG_AUTOSCAN
  1237. OBJS += autoscan.o
  1238. endif
  1239. ifdef CONFIG_EXT_PASSWORD_TEST
  1240. OBJS += ../src/utils/ext_password_test.o
  1241. CFLAGS += -DCONFIG_EXT_PASSWORD_TEST
  1242. NEED_EXT_PASSWORD=y
  1243. endif
  1244. ifdef NEED_EXT_PASSWORD
  1245. OBJS += ../src/utils/ext_password.o
  1246. CFLAGS += -DCONFIG_EXT_PASSWORD
  1247. endif
  1248. ifdef NEED_GAS
  1249. OBJS += ../src/common/gas.o
  1250. OBJS += gas_query.o
  1251. CFLAGS += -DCONFIG_GAS
  1252. NEED_OFFCHANNEL=y
  1253. endif
  1254. ifdef NEED_OFFCHANNEL
  1255. OBJS += offchannel.o
  1256. CFLAGS += -DCONFIG_OFFCHANNEL
  1257. endif
  1258. OBJS += ../src/drivers/driver_common.o
  1259. OBJS_wpa_rm := ctrl_iface.o ctrl_iface_unix.o
  1260. OBJS_wpa := $(filter-out $(OBJS_wpa_rm),$(OBJS)) $(OBJS_h) tests/test_wpa.o
  1261. ifdef CONFIG_AUTHENTICATOR
  1262. OBJS_wpa += tests/link_test.o
  1263. endif
  1264. OBJS_wpa += $(OBJS_l2)
  1265. OBJS += wpa_supplicant.o events.o blacklist.o wpas_glue.o scan.o
  1266. OBJS_t := $(OBJS) $(OBJS_l2) eapol_test.o
  1267. OBJS_t += ../src/radius/radius_client.o
  1268. OBJS_t += ../src/radius/radius.o
  1269. ifndef CONFIG_AP
  1270. OBJS_t += ../src/utils/ip_addr.o
  1271. endif
  1272. OBJS_t2 := $(OBJS) $(OBJS_l2) preauth_test.o
  1273. OBJS_nfc := $(OBJS) $(OBJS_l2) nfc_pw_token.o
  1274. OBJS_nfc += $(OBJS_d) ../src/drivers/drivers.o
  1275. OBJS += $(CONFIG_MAIN).o
  1276. ifdef CONFIG_PRIVSEP
  1277. OBJS_priv += $(OBJS_d) ../src/drivers/drivers.o
  1278. OBJS_priv += $(OBJS_l2)
  1279. OBJS_priv += ../src/utils/os_$(CONFIG_OS).o
  1280. OBJS_priv += ../src/utils/$(CONFIG_ELOOP).o
  1281. OBJS_priv += ../src/utils/common.o
  1282. OBJS_priv += ../src/utils/wpa_debug.o
  1283. OBJS_priv += ../src/utils/wpabuf.o
  1284. OBJS_priv += wpa_priv.o
  1285. ifdef CONFIG_DRIVER_NL80211
  1286. OBJS_priv += ../src/common/ieee802_11_common.o
  1287. endif
  1288. ifdef CONFIG_DRIVER_TEST
  1289. OBJS_priv += $(SHA1OBJS)
  1290. OBJS_priv += $(MD5OBJS)
  1291. ifeq ($(CONFIG_TLS), openssl)
  1292. OBJS_priv += ../src/crypto/crypto_openssl.o
  1293. endif
  1294. ifeq ($(CONFIG_TLS), gnutls)
  1295. OBJS_priv += ../src/crypto/crypto_gnutls.o
  1296. endif
  1297. ifeq ($(CONFIG_TLS), nss)
  1298. OBJS_priv += ../src/crypto/crypto_nss.o
  1299. endif
  1300. ifeq ($(CONFIG_TLS), internal)
  1301. ifeq ($(CONFIG_CRYPTO), libtomcrypt)
  1302. OBJS_priv += ../src/crypto/crypto_libtomcrypt.o
  1303. else
  1304. OBJS_priv += ../src/crypto/crypto_internal.o
  1305. endif
  1306. endif
  1307. endif # CONFIG_DRIVER_TEST
  1308. OBJS += ../src/l2_packet/l2_packet_privsep.o
  1309. OBJS += ../src/drivers/driver_privsep.o
  1310. EXTRA_progs += wpa_priv
  1311. else
  1312. OBJS += $(OBJS_d) ../src/drivers/drivers.o
  1313. OBJS += $(OBJS_l2)
  1314. endif
  1315. ifdef CONFIG_NDIS_EVENTS_INTEGRATED
  1316. CFLAGS += -DCONFIG_NDIS_EVENTS_INTEGRATED
  1317. OBJS += ../src/drivers/ndis_events.o
  1318. EXTRALIBS += -loleaut32 -lole32 -luuid
  1319. ifdef PLATFORMSDKLIB
  1320. EXTRALIBS += $(PLATFORMSDKLIB)/WbemUuid.Lib
  1321. else
  1322. EXTRALIBS += WbemUuid.Lib
  1323. endif
  1324. endif
  1325. ifndef LDO
  1326. LDO=$(CC)
  1327. endif
  1328. Q=@
  1329. E=echo
  1330. ifeq ($(V), 1)
  1331. Q=
  1332. E=true
  1333. endif
  1334. dynamic_eap_methods: $(EAPDYN)
  1335. ../src/drivers/build.wpa_supplicant:
  1336. @if [ -f ../src/drivers/build.hostapd ]; then \
  1337. $(MAKE) -C ../src/drivers clean; \
  1338. fi
  1339. @touch ../src/drivers/build.wpa_supplicant
  1340. BCHECK=../src/drivers/build.wpa_supplicant
  1341. wpa_priv: $(BCHECK) $(OBJS_priv)
  1342. $(Q)$(LDO) $(LDFLAGS) -o wpa_priv $(OBJS_priv) $(LIBS)
  1343. @$(E) " LD " $@
  1344. $(OBJS_c) $(OBJS_t) $(OBJS_t2) $(OBJS) $(BCHECK) $(EXTRA_progs): .config
  1345. wpa_supplicant: $(BCHECK) $(OBJS) $(EXTRA_progs)
  1346. $(Q)$(LDO) $(LDFLAGS) -o wpa_supplicant $(OBJS) $(LIBS) $(EXTRALIBS)
  1347. @$(E) " LD " $@
  1348. eapol_test: $(OBJS_t)
  1349. $(Q)$(LDO) $(LDFLAGS) -o eapol_test $(OBJS_t) $(LIBS)
  1350. @$(E) " LD " $@
  1351. preauth_test: $(OBJS_t2)
  1352. $(Q)$(LDO) $(LDFLAGS) -o preauth_test $(OBJS_t2) $(LIBS)
  1353. @$(E) " LD " $@
  1354. wpa_passphrase: $(OBJS_p)
  1355. $(Q)$(LDO) $(LDFLAGS) -o wpa_passphrase $(OBJS_p) $(LIBS_p)
  1356. @$(E) " LD " $@
  1357. wpa_cli: $(OBJS_c)
  1358. $(Q)$(LDO) $(LDFLAGS) -o wpa_cli $(OBJS_c) $(LIBS_c)
  1359. @$(E) " LD " $@
  1360. link_test: $(OBJS) $(OBJS_h) tests/link_test.o
  1361. $(Q)$(LDO) $(LDFLAGS) -o link_test $(OBJS) $(OBJS_h) tests/link_test.o $(LIBS)
  1362. @$(E) " LD " $@
  1363. test_wpa: $(OBJS_wpa) $(OBJS_h)
  1364. $(Q)$(LDO) $(LDFLAGS) -o test_wpa $(OBJS_wpa) $(LIBS)
  1365. @$(E) " LD " $@
  1366. nfc_pw_token: $(OBJS_nfc)
  1367. $(Q)$(LDO) $(LDFLAGS) -o nfc_pw_token $(OBJS_nfc) $(LIBS)
  1368. @$(E) " LD " $@
  1369. win_if_list: win_if_list.c
  1370. $(Q)$(LDO) $(LDFLAGS) -o $@ win_if_list.c $(CFLAGS) $(LIBS_w)
  1371. @$(E) " LD " $@
  1372. eap_psk.so: ../src/eap_peer/eap_psk.c ../src/eap_common/eap_psk_common.c
  1373. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \
  1374. -Deap_peer_psk_register=eap_peer_method_dynamic_init
  1375. eap_pax.so: ../src/eap_peer/eap_pax.c ../src/eap_common/eap_pax_common.c
  1376. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \
  1377. -Deap_peer_pax_register=eap_peer_method_dynamic_init
  1378. eap_sake.so: ../src/eap_peer/eap_sake.c ../src/eap_common/eap_sake_common.c
  1379. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \
  1380. -Deap_peer_sake_register=eap_peer_method_dynamic_init
  1381. eap_wsc.so: ../src/eap_peer/eap_wsc.c ../src/eap_common/eap_wsc_common.c ../src/wps/wps.c
  1382. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \
  1383. -Deap_peer_wsc_register=eap_peer_method_dynamic_init
  1384. eap_ikev2.so: ../src/eap_peer/eap_ikev2.c ../src/eap_peer/ikev2.c ../src/eap_common/eap_ikev2_common.o ../src/eap_common/ikev2_common.c
  1385. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $^ \
  1386. -Deap_peer_ikev2_register=eap_peer_method_dynamic_init
  1387. %.so: %.c
  1388. $(CC) $(LDFLAGS) -o $@ $(CFLAGS) -shared -rdynamic -fPIC $< \
  1389. -D$(*F:eap_%=eap_peer_%)_register=eap_peer_method_dynamic_init
  1390. %.o: %.c
  1391. $(Q)$(CC) -c -o $@ $(CFLAGS) $<
  1392. @$(E) " CC " $<
  1393. %.service: %.service.in
  1394. sed -e 's|\@BINDIR\@|$(BINDIR)|g' $< >$@
  1395. %@.service: %.service.arg.in
  1396. sed -e 's|\@BINDIR\@|$(BINDIR)|g' $< >$@
  1397. wpa_supplicant.exe: wpa_supplicant
  1398. mv -f $< $@
  1399. wpa_cli.exe: wpa_cli
  1400. mv -f $< $@
  1401. wpa_passphrase.exe: wpa_passphrase
  1402. mv -f $< $@
  1403. win_if_list.exe: win_if_list
  1404. mv -f $< $@
  1405. eapol_test.exe: eapol_test
  1406. mv -f $< $@
  1407. WINALL=wpa_supplicant.exe wpa_cli.exe wpa_passphrase.exe win_if_list.exe
  1408. windows-bin: $(WINALL)
  1409. $(STRIP) $(WINALL)
  1410. wpa_gui:
  1411. @echo "wpa_gui has been removed - see wpa_gui-qt4 for replacement"
  1412. wpa_gui-qt4/Makefile:
  1413. qmake -o wpa_gui-qt4/Makefile wpa_gui-qt4/wpa_gui.pro
  1414. wpa_gui-qt4/lang/wpa_gui_de.qm: wpa_gui-qt4/lang/wpa_gui_de.ts
  1415. lrelease wpa_gui-qt4/wpa_gui.pro
  1416. wpa_gui-qt4: wpa_gui-qt4/Makefile wpa_gui-qt4/lang/wpa_gui_de.qm
  1417. $(MAKE) -C wpa_gui-qt4
  1418. TEST_EAP_SIM_COMMON_OBJS = $(SHA1OBJS) $(MD5OBJS) \
  1419. ../src/utils/common.o ../src/utils/os_unix.o \
  1420. ../src/utils/wpa_debug.o $(AESOBJS) \
  1421. tests/test_eap_sim_common.o
  1422. test-eap_sim_common: $(TEST_EAP_SIM_COMMON_OBJS)
  1423. $(LDO) $(LDFLAGS) -o $@ $(TEST_EAP_SIM_COMMON_OBJS) $(LIBS)
  1424. ./test-eap_sim_common
  1425. rm test-eap_sim_common
  1426. tests: test-eap_sim_common
  1427. FIPSDIR=/usr/local/ssl/fips-2.0
  1428. FIPSLD=$(FIPSDIR)/bin/fipsld
  1429. fips:
  1430. $(MAKE) CC=$(FIPSLD) FIPSLD_CC="$(CC)"
  1431. clean:
  1432. $(MAKE) -C ../src clean
  1433. $(MAKE) -C dbus clean
  1434. rm -f core *~ *.o *.d eap_*.so $(ALL) $(WINALL) eapol_test preauth_test
  1435. rm -f wpa_priv
  1436. rm -f nfc_pw_token
  1437. -include $(OBJS:%.o=%.d)