LIBS += -lws2_32
endif
-OBJS = hostapd.o
-OBJS += wpa_auth_glue.o
OBJS += main.o
OBJS += config_file.o
-OBJS += drv_callbacks.o
-OBJS += ap_drv_ops.o
+OBJS += ../src/ap/hostapd.o
+OBJS += ../src/ap/wpa_auth_glue.o
+OBJS += ../src/ap/drv_callbacks.o
+OBJS += ../src/ap/ap_drv_ops.o
OBJS += ../src/ap/utils.o
OBJS += ../src/ap/authsrv.o
OBJS += ../src/ap/ieee802_1x.o
OBJS += ../src/ap/wmm.o
OBJS += ../src/ap/ap_list.o
OBJS += ../src/ap/ieee802_11.o
-OBJS += hw_features.o
+OBJS += ../src/ap/hw_features.o
ifdef CONFIG_IEEE80211N
OBJS += ../src/ap/ieee802_11_ht.o
endif
#include "config_file.h"
#include "eap_register.h"
#include "dump_state.h"
+#include "ctrl_iface.h"
extern int wpa_debug_level;
hapd_iface->config_fname = os_strdup(config_file);
if (hapd_iface->config_fname == NULL)
goto fail;
+ hapd_iface->ctrl_iface_init = hostapd_ctrl_iface_init;
+ hapd_iface->ctrl_iface_deinit = hostapd_ctrl_iface_deinit;
conf = hostapd_config_read(hapd_iface->config_fname);
if (conf == NULL)
#include "ap/wps_hostapd.h"
#include "hw_features.h"
#include "driver_i.h"
-#include "ctrl_iface.h"
#include "wpa_auth_glue.h"
#include "ap_drv_ops.h"
*/
static void hostapd_cleanup(struct hostapd_data *hapd)
{
- hostapd_ctrl_iface_deinit(hapd);
+ if (hapd->iface->ctrl_iface_deinit)
+ hapd->iface->ctrl_iface_deinit(hapd);
iapp_deinit(hapd->iapp);
hapd->iapp = NULL;
return -1;
}
- if (hostapd_ctrl_iface_init(hapd)) {
+ if (hapd->iface->ctrl_iface_init &&
+ hapd->iface->ctrl_iface_init(hapd)) {
wpa_printf(MSG_ERROR, "Failed to setup control interface");
return -1;
}
u16 ht_op_mode;
void (*scan_cb)(struct hostapd_iface *iface);
+
+ int (*ctrl_iface_init)(struct hostapd_data *hapd);
+ void (*ctrl_iface_deinit)(struct hostapd_data *hapd);
};
/* hostapd.c */
CFLAGS += -DCONFIG_NO_RADIUS
CFLAGS += -DCONFIG_NO_ACCOUNTING
CFLAGS += -DCONFIG_NO_VLAN
-OBJS += ../hostapd/hostapd.o
-OBJS += ../hostapd/wpa_auth_glue.o
+OBJS += ../src/ap/hostapd.o
+OBJS += ../src/ap/wpa_auth_glue.o
OBJS += ../src/ap/utils.o
OBJS += ../src/ap/authsrv.o
OBJS += ../src/ap/config.o
OBJS += ../src/ap/ieee802_1x.o
OBJS += ../src/eapol_auth/eapol_auth_sm.o
OBJS += ../src/ap/ieee802_11_auth.o
-OBJS += ../hostapd/drv_callbacks.o
-OBJS += ../hostapd/ap_drv_ops.o
+OBJS += ../src/ap/drv_callbacks.o
+OBJS += ../src/ap/ap_drv_ops.o
ifdef CONFIG_CTRL_IFACE
OBJS += ../src/ap/ctrl_iface_ap.o
endif
OBJS += ../src/ap/wmm.o
OBJS += ../src/ap/ap_list.o
OBJS += ../src/ap/ieee802_11.o
-OBJS += ../hostapd/hw_features.o
+OBJS += ../src/ap/hw_features.o
ifdef CONFIG_IEEE80211N
OBJS += ../src/ap/ieee802_11_ht.o
endif
}
-int hostapd_ctrl_iface_init(struct hostapd_data *hapd)
-{
- return 0;
-}
-
-
-void hostapd_ctrl_iface_deinit(struct hostapd_data *hapd)
-{
-}
-
-
static int wpa_supplicant_conf_ap(struct wpa_supplicant *wpa_s,
struct wpa_ssid *ssid,
struct hostapd_config *conf)