2 # Copyright (C) 2008 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
11 PKG_NAME
:=wpa_supplicant
14 PKG_MD5SUM
:=b51b2975f21006f85f7297f3fb1acde1
16 PKG_SOURCE_URL
:=http
://hostap.epitest.fi
/releases
17 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
19 include $(INCLUDE_DIR
)/package.mk
20 STAMP_CONFIGURED
:=$(STAMP_CONFIGURED
)_
$(call confvar
,CONFIG_PACKAGE_kmod-madwifi CONFIG_WPA_SUPPLICANT_NO_TIMESTAMP_CHECK
)
22 define Package
/wpa-supplicant
26 DEPENDS
:=$(if
$(CONFIG_WPA_SUPPLICANT_OPENSSL
),+libopenssl
)
27 URL
:=http
://hostap.epitest.fi
/wpa_supplicant
/
30 define Package
/wpa-supplicant
/Description
34 define Package
/wpa-supplicant
/config
35 source
"$(SOURCE)/Config.in"
38 define Package
/wpa-cli
41 DEPENDS
:=wpa-supplicant
42 TITLE
:=WPA Supplicant command line interface
45 define Package
/wpa-cli
/Description
46 WPA Supplicant control utility
49 CONFIG
=$(firstword $(wildcard .
/files
/config.
$(BOARD
) .
/files
/config.
$(ARCH
) .
/config
))
50 TARGET_CFLAGS
+= -I
$(STAGING_DIR
)/usr
/include/madwifi
$(if
$(CONFIG_WPA_SUPPLICANT_NO_TIMESTAMP_CHECK
),-DNO_TIMESTAMP_CHECK
)
52 define Build
/Configure
53 cp
$(CONFIG
) $(PKG_BUILD_DIR
)/wpa_supplicant
/.config
54 $(if
$(CONFIG_PACKAGE_kmod-madwifi
),,$(SED
) 's,^CONFIG_DRIVER_MADWIFI,#CONFIG_DRIVER_MADWIFI,g' $(PKG_BUILD_DIR
)/wpa_supplicant
/.config
)
55 $(if
$(CONFIG_WPA_SUPPLICANT_OPENSSL
),$(SED
) 's|^CONFIG_TLS.*|CONFIG_TLS=openssl|g' $(PKG_BUILD_DIR
)/wpa_supplicant
/.config
)
59 rm -rf
$(PKG_INSTALL_DIR
)
60 mkdir
-p
$(PKG_INSTALL_DIR
)
61 CFLAGS
="$(TARGET_CFLAGS)" \
62 $(MAKE
) -C
$(PKG_BUILD_DIR
)/wpa_supplicant \
65 CPPFLAGS
="$(TARGET_CPPFLAGS)" \
66 LDFLAGS
="$(TARGET_LDFLAGS)" \
70 define Package
/wpa-supplicant
/install
71 $(INSTALL_DIR
) $(1)/usr
/sbin
73 $(PKG_BUILD_DIR
)/wpa_supplicant
/wpa_supplicant \
74 $(PKG_BUILD_DIR
)/wpa_supplicant
/wpa_passphrase \
78 define Package
/wpa-cli
/install
79 $(INSTALL_DIR
) $(1)/usr
/sbin
80 $(CP
) $(PKG_BUILD_DIR
)/wpa_supplicant
/wpa_cli
$(1)/usr
/sbin
/
83 $(eval
$(call BuildPackage
,wpa-supplicant
))
84 $(eval
$(call BuildPackage
,wpa-cli
))