Compilation of hostapd

Daamn M daamn.m at gmail.com
Wed Apr 1 14:53:53 PDT 2009


Hi!

I'm trying to set up wifi access point using my FreeBSD box and
hostapd deamon. My goal is running EAP-TTLS server. It seems that the
version shipped with base system isn't compiled with options allowing
to use EAP server (I'm using 7.0 version but the same is with the
latest 8.0 snapshot). I was suprised that some part of base system
requires nonstandard tool (gmake) (I changed it to be able to use
standard FreeBSD make). Besides, trying to compile it I get the
following error:

preauth.o(.text+0x1b2): In function `rsn_preauth_send':
/usr/src/contrib/hostapd/preauth.c:263: undefined reference to `l2_packet_send'
preauth.o(.text+0x55c): In function `rsn_preauth_iface_deinit':
/usr/src/contrib/hostapd/preauth.c:148: undefined reference to
`l2_packet_deinit'
preauth.o(.text+0x660): In function `rsn_preauth_iface_init':
/usr/src/contrib/hostapd/preauth.c:119: undefined reference to `l2_packet_init'
gmake: *** [hostapd] Error 1


This is ,,.config'' file I used (after this I pasted error I get if I
modify a bit config file):


# Example hostapd build time configuration
#
# This file lists the configuration options that are used when building the
# hostapd binary. All lines starting with # are ignored. Configuration option
# lines must be commented out complete, if they are not to be included, i.e.,
# just setting VARIABLE=n is not disabling that variable.
#
# This file is included in Makefile, so variables like CFLAGS and LIBS can also
# be modified from here. In most cass, these lines should use += in order not
# to override previous values of the variables.

# Driver interface for Host AP driver
#CONFIG_DRIVER_HOSTAP=y

# Driver interface for wired authenticator
#CONFIG_DRIVER_WIRED=y

# Driver interface for madwifi driver
#CONFIG_DRIVER_MADWIFI=y
#CFLAGS += -I../head # change to reflect local setup; directory for madwifi src

CONFIG_L2_PACKET=y
#CONFIG_DNET_PCAP=y
#CONFIG_L2_FREEBSD=y

# Driver interface for Prism54 driver
#CONFIG_DRIVER_PRISM54=y

# Driver interface for drivers using Devicescape IEEE 802.11 stack
#CONFIG_DRIVER_DEVICESCAPE=y
# Currently, driver_devicescape.c build requires some additional parameters
# to be able to include some of the kernel header files. Following lines can
# be used to set these (WIRELESS_DEV must point to the root directory of the
# wireless-dev.git tree).
#WIRELESS_DEV=/usr/src/wireless-dev
#CFLAGS += -I$(WIRELESS_DEV)/net/mac80211

# Driver interface for FreeBSD net80211 layer (e.g., Atheros driver)
#CONFIG_DRIVER_BSD=y
#CFLAGS += -I/usr/local/include
#LIBS += -L/usr/local/lib

# IEEE 802.11F/IAPP
#CONFIG_IAPP=y

# WPA2/IEEE 802.11i RSN pre-authentication
CONFIG_RSN_PREAUTH=y

# PeerKey handshake for Station to Station Link (IEEE 802.11e DLS)
CONFIG_PEERKEY=y

# IEEE 802.11w (management frame protection)
# This version is an experimental implementation based on IEEE 802.11w/D1.0
# draft and is subject to change since the standard has not yet been finalized.
# Driver support is also needed for IEEE 802.11w.
#CONFIG_IEEE80211W=y

# Integrated EAP server
CONFIG_EAP=y

# EAP-MD5 for the integrated EAP server
CONFIG_EAP_MD5=y

# EAP-TLS for the integrated EAP server
CONFIG_EAP_TLS=y

# EAP-MSCHAPv2 for the integrated EAP server
CONFIG_EAP_MSCHAPV2=y

# EAP-PEAP for the integrated EAP server
CONFIG_EAP_PEAP=y

# EAP-GTC for the integrated EAP server
CONFIG_EAP_GTC=y

# EAP-TTLS for the integrated EAP server
CONFIG_EAP_TTLS=y

# EAP-SIM for the integrated EAP server
#CONFIG_EAP_SIM=y

# EAP-AKA for the integrated EAP server
#CONFIG_EAP_AKA=y

# EAP-PAX for the integrated EAP server
#CONFIG_EAP_PAX=y

# EAP-PSK for the integrated EAP server (this is _not_ needed for WPA-PSK)
#CONFIG_EAP_PSK=y

# EAP-SAKE for the integrated EAP server
#CONFIG_EAP_SAKE=y

# EAP-GPSK for the integrated EAP server
#CONFIG_EAP_GPSK=y
# Include support for optional SHA256 cipher suite in EAP-GPSK
#CONFIG_EAP_GPSK_SHA256=y

# PKCS#12 (PFX) support (used to read private key and certificate file from
# a file that usually has extension .p12 or .pfx)
CONFIG_PKCS12=y

# RADIUS authentication server. This provides access to the integrated EAP
# server from external hosts using RADIUS.
#CONFIG_RADIUS_SERVER=y

# Build IPv6 support for RADIUS operations
#CONFIG_IPV6=y







If I uncomment line

      #CONFIG_IAPP=y

then I get:

cc -MMD -O2 -Wall -g -DHOSTAPD_DUMP_STATE -I../src -I../src/crypto
-I../src/utils -I../src/common -DCONFIG_CTRL_IFACE
-DCONFIG_CTRL_IFACE_UNIX -DCONFIG_IAPP -DCONFIG_RSN_PREAUTH
-DCONFIG_PEERKEY -DEAP_MD5 -DEAP_TLS -DEAP_PEAP -DEAP_TTLS
-DEAP_MSCHAPv2 -DEAP_GTC -DEAP_SERVER -DEAP_TLS_FUNCS -DPKCS12_FUNCS
-DINTERNAL_SHA256 -DCONFIG_NO_FIPS186_2_PRF -DCONFIG_NO_T_PRF   -c -o
iapp.o iapp.c
iapp.c:46:30: warning: netpacket/packet.h: No such file or directory
iapp.c: In function 'iapp_init':
iapp.c:394: error: storage size of 'addr' isn't known
iapp.c:424: error: 'struct ifreq' has no member named 'ifr_ifindex'
iapp.c:468: error: 'SOL_IP' undeclared (first use in this function)
iapp.c:468: error: (Each undeclared identifier is reported only once
iapp.c:468: error: for each function it appears in.)
iapp.c:475: error: 'PF_PACKET' undeclared (first use in this function)
iapp.c:483: error: 'AF_PACKET' undeclared (first use in this function)
iapp.c:394: warning: unused variable 'addr'
iapp.c: In function 'iapp_deinit':
iapp.c:522: error: 'SOL_IP' undeclared (first use in this function)
gmake: *** [iapp.o] Error 1


thanks in advance


More information about the freebsd-hackers mailing list