summaryrefslogtreecommitdiffstats
path: root/package/hostapd
diff options
context:
space:
mode:
authorPeter Korsgaard <jacmet@sunsite.dk>2012-05-31 09:23:23 +0200
committerPeter Korsgaard <jacmet@sunsite.dk>2012-05-31 09:23:23 +0200
commitbdb4c3a6dc9efecc4d1e40fabf8cb9b3e0eb3ee2 (patch)
treed6012109e704c5e9abc709c23a7133a3d4b4f779 /package/hostapd
parent5b11223fb6cd0469becf49b0986868832c076bfc (diff)
parent2105ecbd86d04e446effa11108f6bd755ed5f19a (diff)
downloadbuildroot-novena-bdb4c3a6dc9efecc4d1e40fabf8cb9b3e0eb3ee2.tar.gz
buildroot-novena-bdb4c3a6dc9efecc4d1e40fabf8cb9b3e0eb3ee2.zip
Merge branch 'next'
Conflicts: toolchain/kernel-headers/Config.in
Diffstat (limited to 'package/hostapd')
-rw-r--r--package/hostapd/Config.in6
-rw-r--r--package/hostapd/hostapd-0.7.3-ht40-secondary.patch52
-rw-r--r--package/hostapd/hostapd-0.7.3-libnl3.patch15
-rw-r--r--package/hostapd/hostapd.mk93
4 files changed, 49 insertions, 117 deletions
diff --git a/package/hostapd/Config.in b/package/hostapd/Config.in
index 376a087b4..4a474c37e 100644
--- a/package/hostapd/Config.in
+++ b/package/hostapd/Config.in
@@ -10,14 +10,16 @@ config BR2_PACKAGE_HOSTAPD
http://hostap.epitest.fi/
+if BR2_PACKAGE_HOSTAPD
+
config BR2_PACKAGE_HOSTAPD_EAP
bool "Enable EAP"
- depends on BR2_PACKAGE_HOSTAPD
help
Enable support for EAP and RADIUS.
config BR2_PACKAGE_HOSTAPD_WPS
bool "Enable WPS"
- depends on BR2_PACKAGE_HOSTAPD
help
Enable support for Wi-Fi Protected Setup.
+
+endif
diff --git a/package/hostapd/hostapd-0.7.3-ht40-secondary.patch b/package/hostapd/hostapd-0.7.3-ht40-secondary.patch
deleted file mode 100644
index 7664f0360..000000000
--- a/package/hostapd/hostapd-0.7.3-ht40-secondary.patch
+++ /dev/null
@@ -1,52 +0,0 @@
-From dea50507861b79f522c70500fe978072f143af8f Mon Sep 17 00:00:00 2001
-From: Jouni Malinen <jouni.malinen@atheros.com>
-Date: Fri, 12 Nov 2010 18:31:56 +0200
-Subject: [PATCH] AP: Verify that HT40 secondary channel is supported
-
-Refuse to enable HT40 mode AP unless both the primary and secondary
-channels are enabled for AP use.
-(cherry picked from commit 8ea3dd21d2e8b760612af0c7b6a3bb5b89ba7304)
----
- src/ap/hw_features.c | 26 ++++++++++++++++++++++++++
- 1 files changed, 26 insertions(+), 0 deletions(-)
-
-diff --git a/src/ap/hw_features.c b/src/ap/hw_features.c
-index 0159c72..7fc5b83 100644
---- a/src/ap/hw_features.c
-+++ b/src/ap/hw_features.c
-@@ -642,6 +642,32 @@ int hostapd_select_hw_mode(struct hostapd_iface *iface)
- break;
- }
- }
-+ if (ok && iface->conf->secondary_channel) {
-+ int sec_ok = 0;
-+ int sec_chan = iface->conf->channel +
-+ iface->conf->secondary_channel * 4;
-+ for (j = 0; j < iface->current_mode->num_channels; j++) {
-+ struct hostapd_channel_data *chan =
-+ &iface->current_mode->channels[j];
-+ if (!(chan->flag & HOSTAPD_CHAN_DISABLED) &&
-+ (chan->chan == sec_chan)) {
-+ sec_ok = 1;
-+ break;
-+ }
-+ }
-+ if (!sec_ok) {
-+ hostapd_logger(iface->bss[0], NULL,
-+ HOSTAPD_MODULE_IEEE80211,
-+ HOSTAPD_LEVEL_WARNING,
-+ "Configured HT40 secondary channel "
-+ "(%d) not found from the channel list "
-+ "of current mode (%d) %s",
-+ sec_chan, iface->current_mode->mode,
-+ hostapd_hw_mode_txt(
-+ iface->current_mode->mode));
-+ ok = 0;
-+ }
-+ }
- if (iface->conf->channel == 0) {
- /* TODO: could request a scan of neighboring BSSes and select
- * the channel automatically */
---
-1.7.4-rc1
-
diff --git a/package/hostapd/hostapd-0.7.3-libnl3.patch b/package/hostapd/hostapd-0.7.3-libnl3.patch
deleted file mode 100644
index e47da73dd..000000000
--- a/package/hostapd/hostapd-0.7.3-libnl3.patch
+++ /dev/null
@@ -1,15 +0,0 @@
---- a/src/drivers/drivers.mak 2011-11-29 19:09:23.889942913 +0100
-+++ b/src/drivers/drivers.mak 2011-11-29 19:09:40.637381428 +0100
-@@ -31,10 +31,10 @@
- NEED_AP_MLME=y
- NEED_NETLINK=y
- NEED_LINUX_IOCTL=y
--DRV_LIBS += -lnl
-+DRV_LIBS += -lnl-3
-
- ifdef CONFIG_LIBNL20
--DRV_LIBS += -lnl-genl
-+DRV_LIBS += -lnl-genl-3
- DRV_CFLAGS += -DCONFIG_LIBNL20
- endif
- endif
diff --git a/package/hostapd/hostapd.mk b/package/hostapd/hostapd.mk
index 26ebf1de0..c7c59ecc3 100644
--- a/package/hostapd/hostapd.mk
+++ b/package/hostapd/hostapd.mk
@@ -4,11 +4,12 @@
#
#############################################################
-HOSTAPD_VERSION = 0.7.3
+HOSTAPD_VERSION = 1.0
HOSTAPD_SITE = http://hostap.epitest.fi/releases
HOSTAPD_SUBDIR = hostapd
HOSTAPD_CONFIG = $(HOSTAPD_DIR)/$(HOSTAPD_SUBDIR)/.config
HOSTAPD_DEPENDENCIES = libnl
+HOSTAPD_CFLAGS = $(TARGET_CFLAGS) -I$(STAGING_DIR)/usr/include/libnl3/
HOSTAPD_LDFLAGS = $(TARGET_LDFLAGS)
# libnl needs -lm (for rint) if linking statically
@@ -17,78 +18,73 @@ HOSTAPD_LDFLAGS += -lm
endif
define HOSTAPD_LIBNL_CONFIG
- echo "CONFIG_LIBNL20=y" >>$(HOSTAPD_CONFIG)
- echo "CFLAGS += -I$(STAGING_DIR)/usr/include/libnl3/" >>$(HOSTAPD_CONFIG)
+ echo 'CONFIG_LIBNL32=y' >>$(HOSTAPD_CONFIG)
endef
-define HOSTAPD_CRYPTO_CONFIG
- echo "CONFIG_CRYPTO=internal" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_INTERNAL_LIBTOMMATH=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_INTERNAL_LIBTOMMATH_FAST=y" >>$(HOSTAPD_CONFIG)
+define HOSTAPD_LIBTOMMATH_CONFIG
+ $(SED) 's/\(#\)\(CONFIG_INTERNAL_LIBTOMMATH.*\)/\2/' $(HOSTAPD_CONFIG)
endef
-# Try to use openssl for TLS if it's already available
-# gnutls is also supported for TLS
+# Try to use openssl or gnutls if it's already available
ifeq ($(BR2_PACKAGE_OPENSSL),y)
HOSTAPD_DEPENDENCIES += openssl
define HOSTAPD_TLS_CONFIG
- echo "CONFIG_TLS=openssl" >>$(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_TLS=openssl\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_PWD.*\)/\2/' $(HOSTAPD_CONFIG)
endef
else
+ifeq ($(BR2_PACKAGE_GNUTLS),y)
+ HOSTAPD_DEPENDENCIES += gnutls
define HOSTAPD_TLS_CONFIG
- echo "CONFIG_TLS=internal" >>$(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_TLS=\).*/\2gnutls/' $(HOSTAPD_CONFIG)
endef
+else
+define HOSTAPD_TLS_CONFIG
+ $(SED) 's/\(#\)\(CONFIG_TLS=\).*/\2internal/' $(HOSTAPD_CONFIG)
+endef
+endif
endif
ifeq ($(BR2_PACKAGE_HOSTAPD_EAP),y)
define HOSTAPD_EAP_CONFIG
- $(SED) "s/CONFIG_EAP_MSCHAPV2=y//" $(HOSTAPD_CONFIG)
- $(SED) "s/CONFIG_EAP_PEAP=y//" $(HOSTAPD_CONFIG)
- $(SED) "s/CONFIG_EAP_TLS=y//" $(HOSTAPD_CONFIG)
- $(SED) "s/CONFIG_EAP_TTLS=y//" $(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_AKA=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_AKA_PRIME=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_GPSK=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_GPSK_SHA256=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_PAX=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_PSK=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_SAKE=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_EAP_SIM=y" >>$(HOSTAPD_CONFIG)
- echo "CONFIG_RADIUS_SERVER=y" >>$(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_AKA.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_FAST.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_GPSK.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_IKEV2.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_PAX.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_PSK.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_SAKE.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_SIM.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_EAP_TNC.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_RADIUS_SERVER.*\)/\2/' $(HOSTAPD_CONFIG)
endef
-ifeq ($(BR2_INET_IPV6),y)
+ifneq ($(BR2_INET_IPV6),y)
define HOSTAPD_RADIUS_IPV6_CONFIG
- $(SED) "s/^#CONFIG_IPV6/CONFIG_IPV6/" $(HOSTAPD_CONFIG)
+ $(SED) 's/\(CONFIG_IPV6.*\)/#\1/' $(HOSTAPD_CONFIG)
endef
endif
else
define HOSTAPD_EAP_CONFIG
- $(SED) "s/^CONFIG_EAP/#CONFIG_EAP/g" $(HOSTAPD_CONFIG)
- $(SED) "s/^#CONFIG_NO_ACCOUNTING/CONFIG_NO_ACCOUNTING/" $(HOSTAPD_CONFIG)
- $(SED) "s/^#CONFIG_NO_RADIUS/CONFIG_NO_RADIUS/" $(HOSTAPD_CONFIG)
+ $(SED) 's/^\(CONFIG_EAP.*\)/#\1/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_NO_ACCOUNTING.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_NO_RADIUS.*\)/\2/' $(HOSTAPD_CONFIG)
endef
endif
ifeq ($(BR2_PACKAGE_HOSTAPD_WPS),y)
define HOSTAPD_WPS_CONFIG
- $(SED) "s/^#CONFIG_WPS/CONFIG_WPS/g" $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_WPS.*\)/\2/' $(HOSTAPD_CONFIG)
endef
endif
define HOSTAPD_CONFIGURE_CMDS
- cp $(@D)/$(HOSTAPD_SUBDIR)/defconfig $(HOSTAPD_CONFIG)
- $(SED) "s/\/local//" $(@D)/$(HOSTAPD_SUBDIR)/Makefile
- echo "CFLAGS += $(TARGET_CFLAGS)" >>$(HOSTAPD_CONFIG)
- echo "LDFLAGS += $(HOSTAPD_LDFLAGS)" >>$(HOSTAPD_CONFIG)
- echo "CC = $(TARGET_CC)" >>$(HOSTAPD_CONFIG)
-# Drivers
- $(SED) "s/^#CONFIG_DRIVER_WIRED/CONFIG_DRIVER_WIRED/" $(HOSTAPD_CONFIG)
- $(SED) "s/^#CONFIG_DRIVER_NL80211/CONFIG_DRIVER_NL80211/" $(HOSTAPD_CONFIG)
+ cp $(@D)/hostapd/defconfig $(HOSTAPD_CONFIG)
# Misc
- $(SED) "s/^CONFIG_IPV6/#CONFIG_IPV6/" $(HOSTAPD_CONFIG)
- $(SED) "s/^#CONFIG_IEEE80211N/CONFIG_IEEE80211N/" $(HOSTAPD_CONFIG)
- $(SED) "s/^#CONFIG_IEEE80211R/CONFIG_IEEE80211R/" $(HOSTAPD_CONFIG)
- $(HOSTAPD_CRYPTO_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_IEEE80211N.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_IEEE80211R.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_INTERWORKING.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(SED) 's/\(#\)\(CONFIG_FULL_DYNAMIC_VLAN.*\)/\2/' $(HOSTAPD_CONFIG)
+ $(HOSTAPD_LIBTOMMATH_CONFIG)
$(HOSTAPD_TLS_CONFIG)
$(HOSTAPD_RADIUS_IPV6_CONFIG)
$(HOSTAPD_EAP_CONFIG)
@@ -96,6 +92,12 @@ define HOSTAPD_CONFIGURE_CMDS
$(HOSTAPD_LIBNL_CONFIG)
endef
+define HOSTAPD_BUILD_CMDS
+ $(TARGET_MAKE_ENV) CFLAGS="$(HOSTAPD_CFLAGS)" \
+ LDFLAGS="$(TARGET_LDFLAGS)" \
+ $(MAKE) CC="$(TARGET_CC)" -C $(@D)/$(HOSTAPD_SUBDIR)
+endef
+
define HOSTAPD_INSTALL_TARGET_CMDS
$(INSTALL) -m 0755 -D $(@D)/$(HOSTAPD_SUBDIR)/hostapd \
$(TARGET_DIR)/usr/sbin/hostapd
@@ -103,9 +105,4 @@ define HOSTAPD_INSTALL_TARGET_CMDS
$(TARGET_DIR)/usr/bin/hostapd_cli
endef
-define HOSTAPD_UNINSTALL_TARGET_CMDS
- rm -f $(TARGET_DIR)/usr/sbin/hostapd
- rm -f $(TARGET_DIR)/usr/bin/hostapd
-endef
-
-$(eval $(call AUTOTARGETS))
+$(eval $(call GENTARGETS))