diff options
author | Dmitry Shmidt <dimitrysh@google.com> | 2010-02-01 10:46:13 -0800 |
---|---|---|
committer | Dmitry Shmidt <dimitrysh@google.com> | 2010-02-01 10:46:13 -0800 |
commit | 358ae72d314bf9df7050908541f30b78a2871c8a (patch) | |
tree | 63e15397a1fd07c7a25b9b53a2b34062d59b53c2 /wl1271 | |
parent | ddac9c138c5b4b16b99fb8bc5f0f10418efa1029 (diff) | |
download | wlan-358ae72d314bf9df7050908541f30b78a2871c8a.tar.gz |
wl1271: Fix Android utility compilation
Signed-off-by: Dmitry Shmidt <dimitrysh@google.com>
Diffstat (limited to 'wl1271')
-rw-r--r-- | wl1271/CUDK/configurationutility/Android.mk | 35 | ||||
-rw-r--r-- | wl1271/CUDK/configurationutility/src/wpa_core.c | 4 | ||||
-rw-r--r-- | wl1271/CUDK/os/common/inc/cu_osapi.h | 6 | ||||
-rw-r--r-- | wl1271/CUDK/os/linux/src/Android.mk | 65 | ||||
-rw-r--r-- | wl1271/CUDK/tiwlan_loader/Android.mk | 9 | ||||
-rw-r--r-- | wl1271/wpa_supplicant_lib/Android.mk | 7 |
6 files changed, 81 insertions, 45 deletions
diff --git a/wl1271/CUDK/configurationutility/Android.mk b/wl1271/CUDK/configurationutility/Android.mk index 5d9c5417..93450b6d 100644 --- a/wl1271/CUDK/configurationutility/Android.mk +++ b/wl1271/CUDK/configurationutility/Android.mk @@ -11,17 +11,36 @@ WILINK_ROOT = ../.. CUDK_ROOT ?= $(WILINK_ROOT)/CUDK CU_ROOT = $(CUDK_ROOT)/configurationutility +ifndef WPA_SUPPLICANT_VERSION +WPA_SUPPLICANT_VERSION := VER_0_5_X +endif + +ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_5_X) +WPA_SUPPL_DIR = external/wpa_supplicant +else +WPA_SUPPL_DIR = external/wpa_supplicant_6/wpa_supplicant +endif +WPA_SUPPL_DIR_INCLUDE = $(WPA_SUPPL_DIR) +ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_6_X) +WPA_SUPPL_DIR_INCLUDE += $(WPA_SUPPL_DIR)/src \ + $(WPA_SUPPL_DIR)/src/common \ + $(WPA_SUPPL_DIR)/src/drivers \ + $(WPA_SUPPL_DIR)/src/l2_packet \ + $(WPA_SUPPL_DIR)/src/utils \ + $(WPA_SUPPL_DIR)/src/wps +endif + ifeq ($(DEBUG),y) - DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin +DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin else - DEBUGFLAGS = -O2 +DEBUGFLAGS = -O2 endif ifeq ($(DEBUG),y) - DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin # "-O" is needed to expand inlines +DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin # "-O" is needed to expand inlines # DEBUGFLAGS+= -DDEBUG_MESSAGES else - DEBUGFLAGS = -O2 +DEBUGFLAGS = -O2 endif DEBUGFLAGS += -DHOST_COMPILE @@ -36,13 +55,13 @@ endif #Supplicant image building ifeq ($(BUILD_SUPPL), y) DK_DEFINES += -D WPA_SUPPLICANT -D CONFIG_CTRL_IFACE -D CONFIG_CTRL_IFACE_UNIX - -include external/wpa_supplicant/.config +-include external/wpa_supplicant/.config ifeq ($(CONFIG_WPS), y) -DK_DEFINES += -DCONFIG_WPS + DK_DEFINES += -DCONFIG_WPS endif endif -ARMFLAGS = -fno-common -g #-fno-builtin -Wall #-pipe +ARMFLAGS = -fno-common -g #-fno-builtin -Wall #-pipe LOCAL_C_INCLUDES = \ $(LOCAL_PATH)/inc \ @@ -60,7 +79,7 @@ LOCAL_C_INCLUDES = \ $(LOCAL_PATH)/$(WILINK_ROOT)/platforms/os/common/inc \ $(LOCAL_PATH)/$(KERNEL_DIR)/include \ $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/FW_Transfer/Export_Inc \ - external/wpa_supplicant + $(WPA_SUPPL_DIR_INCLUDE) LOCAL_SRC_FILES = \ src/console.c \ diff --git a/wl1271/CUDK/configurationutility/src/wpa_core.c b/wl1271/CUDK/configurationutility/src/wpa_core.c index 9506c75f..f4b0a86e 100644 --- a/wl1271/CUDK/configurationutility/src/wpa_core.c +++ b/wl1271/CUDK/configurationutility/src/wpa_core.c @@ -35,10 +35,10 @@ #include <unistd.h> #endif -#include <string.h> +#include <netinet/if_ether.h> + #include "cu_osapi.h" #include "TWDriver.h" -#include "common.h" #include "config_ssid.h" #include "driver.h" #include "ipc_wpa.h" diff --git a/wl1271/CUDK/os/common/inc/cu_osapi.h b/wl1271/CUDK/os/common/inc/cu_osapi.h index 665af075..f22e8f2a 100644 --- a/wl1271/CUDK/os/common/inc/cu_osapi.h +++ b/wl1271/CUDK/os/common/inc/cu_osapi.h @@ -48,11 +48,15 @@ * be specifically declared here, and only if they weren't defined before by someone * including common.h */ -#ifndef ANDROID +#ifndef COMMON_H typedef unsigned char u8; typedef unsigned short u16; typedef unsigned long u32; typedef unsigned long long u64; + +#ifndef BIT +#define BIT(x) (1 << (x)) +#endif #endif #ifndef NULL diff --git a/wl1271/CUDK/os/linux/src/Android.mk b/wl1271/CUDK/os/linux/src/Android.mk index 3ae1e403..ec1e47e7 100644 --- a/wl1271/CUDK/os/linux/src/Android.mk +++ b/wl1271/CUDK/os/linux/src/Android.mk @@ -14,19 +14,36 @@ endif WILINK_ROOT = ../../../.. CUDK_ROOT = $(WILINK_ROOT)/CUDK -TI_SUPP_LIB_DIR = $(WILINK_ROOT)/../../../../external/wpa_supplicant +ifndef WPA_SUPPLICANT_VERSION +WPA_SUPPLICANT_VERSION := VER_0_5_X +endif + +ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_5_X) +WPA_SUPPL_DIR = external/wpa_supplicant +else +WPA_SUPPL_DIR = external/wpa_supplicant_6/wpa_supplicant +endif +WPA_SUPPL_DIR_INCLUDE = $(WPA_SUPPL_DIR) +ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_6_X) +WPA_SUPPL_DIR_INCLUDE += $(WPA_SUPPL_DIR)/src \ + $(WPA_SUPPL_DIR)/src/common \ + $(WPA_SUPPL_DIR)/src/drivers \ + $(WPA_SUPPL_DIR)/src/l2_packet \ + $(WPA_SUPPL_DIR)/src/utils \ + $(WPA_SUPPL_DIR)/src/wps +endif DK_DEFINES = ifeq ($(WPA_ENTERPRISE), y) - DK_DEFINES += -D WPA_ENTERPRISE +DK_DEFINES += -D WPA_ENTERPRISE endif ifeq ($(BUILD_SUPPL), y) - DK_DEFINES += -D WPA_SUPPLICANT -D CONFIG_CTRL_IFACE -D CONFIG_CTRL_IFACE_UNIX - -include external/wpa_supplicant/.config - ifeq ($(CONFIG_WPS), y) - DK_DEFINES += -DCONFIG_WPS - endif +DK_DEFINES += -D WPA_SUPPLICANT -D CONFIG_CTRL_IFACE -D CONFIG_CTRL_IFACE_UNIX +-include $(WPA_SUPPL_DIR)/.config + ifeq ($(CONFIG_WPS), y) + DK_DEFINES += -DCONFIG_WPS + endif endif LOCAL_CFLAGS += \ @@ -42,29 +59,31 @@ LOCAL_SRC_FILES:= \ osapi.c ifeq ($(BUILD_SUPPL), y) -LOCAL_SRC_FILES += \ - $(TI_SUPP_LIB_DIR)/wpa_ctrl.c + ifeq ($(WPA_SUPPLICANT_VERSION),VER_0_5_X) + LOCAL_SRC_FILES += $(WPA_SUPPL_DIR)/wpa_ctrl.c + else + LOCAL_SRC_FILES += $(WPA_SUPPL_DIR)/common/src/wpa_ctrl.c + endif endif LOCAL_C_INCLUDES := \ - $(LOCAL_PATH)/../inc \ - $(LOCAL_PATH)/../../common/inc \ - $(LOCAL_PATH)/$(WILINK_ROOT)/stad/Export_Inc \ - $(LOCAL_PATH)/$(WILINK_ROOT)/stad/src/Sta_Management \ - $(LOCAL_PATH)/$(WILINK_ROOT)/stad/src/Application \ - $(LOCAL_PATH)/$(WILINK_ROOT)/utils \ - $(LOCAL_PATH)/$(WILINK_ROOT)/Txn \ - $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/TWDriver \ + $(LOCAL_PATH)/../inc \ + $(LOCAL_PATH)/../../common/inc \ + $(LOCAL_PATH)/$(WILINK_ROOT)/stad/Export_Inc \ + $(LOCAL_PATH)/$(WILINK_ROOT)/stad/src/Sta_Management \ + $(LOCAL_PATH)/$(WILINK_ROOT)/stad/src/Application \ + $(LOCAL_PATH)/$(WILINK_ROOT)/utils \ + $(LOCAL_PATH)/$(WILINK_ROOT)/Txn \ + $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/TWDriver \ $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/FirmwareApi \ $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/FW_Transfer/Export_Inc \ $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/TwIf \ - $(LOCAL_PATH)/$(WILINK_ROOT)/platforms/os/linux/inc \ - $(LOCAL_PATH)/$(WILINK_ROOT)/platforms/os/common/inc \ - $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/FirmwareApi \ - external/wpa_supplicant \ - $(LOCAL_PATH)/$(CUDK_ROOT)/configurationutility/inc + $(LOCAL_PATH)/$(WILINK_ROOT)/platforms/os/linux/inc \ + $(LOCAL_PATH)/$(WILINK_ROOT)/platforms/os/common/inc \ + $(LOCAL_PATH)/$(WILINK_ROOT)/TWD/FirmwareApi \ + $(LOCAL_PATH)/$(CUDK_ROOT)/configurationutility/inc \ + $(WPA_SUPPL_DIR_INCLUDE) LOCAL_MODULE := libtiOsLib include $(BUILD_STATIC_LIBRARY) - diff --git a/wl1271/CUDK/tiwlan_loader/Android.mk b/wl1271/CUDK/tiwlan_loader/Android.mk index 00b0476d..b7cfc930 100644 --- a/wl1271/CUDK/tiwlan_loader/Android.mk +++ b/wl1271/CUDK/tiwlan_loader/Android.mk @@ -9,15 +9,15 @@ WILINK_ROOT = ../.. CUDK_ROOT = $(WILINK_ROOT)/CUDK ifeq ($(DEBUG),y) - DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin # "-O" is needed to expand inlines +DEBUGFLAGS = -O2 -g -DDEBUG -DTI_DBG -fno-builtin # "-O" is needed to expand inlines # DEBUGFLAGS+= -DDEBUG_MESSAGES else - DEBUGFLAGS = -O2 +DEBUGFLAGS = -O2 endif -COMMON = $(WILINK_ROOT)/stad +COMMON = $(WILINK_ROOT)/stad -ARMFLAGS = -fno-common -g -fno-builtin -Wall #-pipe +ARMFLAGS = -fno-common -g -fno-builtin -Wall #-pipe LOCAL_C_INCLUDES = \ $(LOCAL_PATH)/$(CUDK_ROOT)/os/common/inc \ @@ -54,4 +54,3 @@ LOCAL_SHARED_LIBRARIES := \ LOCAL_MODULE:= wlan_loader include $(BUILD_EXECUTABLE) - diff --git a/wl1271/wpa_supplicant_lib/Android.mk b/wl1271/wpa_supplicant_lib/Android.mk index cd1d4c26..d0b756f6 100644 --- a/wl1271/wpa_supplicant_lib/Android.mk +++ b/wl1271/wpa_supplicant_lib/Android.mk @@ -15,11 +15,6 @@ # LOCAL_PATH := $(call my-dir) -# This makefile is only included if BOARD_WLAN_TI_STA_DK_ROOT is set, -# and if we're not building for the simulator. -ifndef BOARD_WLAN_TI_STA_DK_ROOT - $(error BOARD_WLAN_TI_STA_DK_ROOT must be defined when including this makefile) -endif ifeq ($(TARGET_SIMULATOR),true) $(error This makefile must not be included when building the simulator) endif @@ -43,7 +38,7 @@ WPA_SUPPL_DIR_INCLUDE += $(WPA_SUPPL_DIR)/src \ $(WPA_SUPPL_DIR)/src/wps endif -DK_ROOT = $(BOARD_WLAN_TI_STA_DK_ROOT) +DK_ROOT = hardware/ti/wlan/$(BOARD_WLAN_DEVICE) OS_ROOT = $(DK_ROOT)/platforms STAD = $(DK_ROOT)/stad UTILS = $(DK_ROOT)/utils |