Replace NEED_MLME with NEED_AP_MLME
[libeap.git] / hostapd / Makefile
index ab5c8f6..fe09dfe 100644 (file)
@@ -125,64 +125,11 @@ ifdef CONFIG_IEEE80211N
 CFLAGS += -DCONFIG_IEEE80211N
 endif
 
-ifdef CONFIG_DRIVER_HOSTAP
-NEED_MLME=y
-CFLAGS += -DCONFIG_DRIVER_HOSTAP
-OBJS += ../src/drivers/driver_hostap.o
-endif
-
-ifdef CONFIG_DRIVER_WIRED
-CFLAGS += -DCONFIG_DRIVER_WIRED
-OBJS += ../src/drivers/driver_wired.o
-endif
-
-ifdef CONFIG_DRIVER_MADWIFI
-CFLAGS += -DCONFIG_DRIVER_MADWIFI
-OBJS += ../src/drivers/driver_madwifi.o
-CONFIG_L2_PACKET=y
-endif
-
-ifdef CONFIG_DRIVER_ATHEROS
-CFLAGS += -DCONFIG_DRIVER_ATHEROS
-OBJS += ../src/drivers/driver_atheros.o
-CONFIG_L2_PACKET=y
-endif
-
-ifdef CONFIG_DRIVER_PRISM54
-CFLAGS += -DCONFIG_DRIVER_PRISM54
-OBJS += ../src/drivers/driver_prism54.o
-endif
-
-ifdef CONFIG_DRIVER_NL80211
-NEED_MLME=y
-CFLAGS += -DCONFIG_DRIVER_NL80211
-OBJS += ../src/drivers/driver_nl80211.o
-OBJS += ../src/utils/radiotap.o
-LIBS += -lnl
-ifdef CONFIG_LIBNL20
-LIBS += -lnl-genl
-CFLAGS += -DCONFIG_LIBNL20
-endif
-endif
-
-ifdef CONFIG_DRIVER_BSD
-CFLAGS += -DCONFIG_DRIVER_BSD
-OBJS += ../src/drivers/driver_bsd.o
-CONFIG_L2_PACKET=y
-CONFIG_DNET_PCAP=y
-CONFIG_L2_FREEBSD=y
-endif
-
-ifdef CONFIG_DRIVER_TEST
-NEED_MLME=y
-CFLAGS += -DCONFIG_DRIVER_TEST
-OBJS += ../src/drivers/driver_test.o
-endif
-
-ifdef CONFIG_DRIVER_NONE
-CFLAGS += -DCONFIG_DRIVER_NONE
-OBJS += ../src/drivers/driver_none.o
-endif
+include ../src/drivers/drivers.mak
+OBJS += $(DRV_AP_OBJS)
+CFLAGS += $(DRV_AP_CFLAGS)
+LDFLAGS += $(DRV_AP_LDFLAGS)
+LIBS += $(DRV_AP_LIBS)
 
 ifdef CONFIG_L2_PACKET
 ifdef CONFIG_DNET_PCAP
@@ -489,7 +436,6 @@ HOBJS += ../src/crypto/crypto_openssl.o
 ifdef NEED_FIPS186_2_PRF
 OBJS += ../src/crypto/fips_prf_openssl.o
 OBJS_p += ../src/crypto/fips_prf_openssl.o
-HOBJS += ../src/crypto/fips_prf_openssl.o
 endif
 CONFIG_INTERNAL_SHA256=y
 endif
@@ -500,7 +446,6 @@ HOBJS += ../src/crypto/crypto_gnutls.o
 ifdef NEED_FIPS186_2_PRF
 OBJS += ../src/crypto/fips_prf_gnutls.o
 OBJS_p += ../src/crypto/fips_prf_gnutls.o
-HOBJS += ../src/crypto/fips_prf_gnutls.o
 endif
 CONFIG_INTERNAL_SHA256=y
 endif
@@ -599,10 +544,10 @@ ifdef NEED_BASE64
 OBJS += ../src/utils/base64.o
 endif
 
-ifdef NEED_MLME
+ifdef NEED_AP_MLME
 OBJS += beacon.o wme.o ap_list.o ieee802_11.o
 OBJS += hw_features.o
-CFLAGS += -DNEED_MLME
+CFLAGS += -DNEED_AP_MLME
 endif
 
 ifdef CONFIG_NO_STDOUT_DEBUG
@@ -667,7 +612,12 @@ ifdef TLS_FUNCS
 LIBS_n += -lcrypto
 endif
 
-HOBJS=../src/hlr_auc_gw/hlr_auc_gw.o ../src/utils/common.o ../src/utils/wpa_debug.o ../src/utils/os_$(CONFIG_OS).o ../src/hlr_auc_gw/milenage.o $(AESOBJS)
+HOBJS += ../src/hlr_auc_gw/hlr_auc_gw.o ../src/utils/common.o ../src/utils/wpa_debug.o ../src/utils/os_$(CONFIG_OS).o ../src/hlr_auc_gw/milenage.o
+HOBJS += ../src/crypto/aes-encblock.o
+ifdef CONFIG_INTERNAL_AES
+HOBJS += ../src/crypto/aes-internal.o
+HOBJS += ../src/crypto/aes-internal-enc.o
+endif
 
 nt_password_hash: $(NOBJS)
        $(CC) -o nt_password_hash $(NOBJS) $(LIBS_n)