4 ## File lists and locations
9 # DK_ROOT must be set prior to including common.inc
14 # Includes common definitions and source file list
16 ifneq ($(KERNELRELEASE),)
17 include $(M)/common.inc
18 include $(M)/drv_sources.inc
21 include drv_sources.inc
25 # Include directory for Odyssey supplicant files
27 ifeq ($(BUILD_SUPPL),y)
28 ODD_INC = $(DK_ROOT)/CUDK/Supplicant/odyssey/odSupp/linux/inc
34 # OS include paths required for compilation.
36 OS_INCS = $(DK_ROOT)/platforms/os/linux/inc $(DK_ROOT)/platforms/os/common/inc
37 #OS_INCS += $(DK_ROOT)/stad/src/core/EvHandler $(DK_ROOT)/Test $(DK_ROOT)/platforms/hw/host_platform_$(HOST_PLATFORM)/linux
38 OS_INCS += $(DK_ROOT)/stad/src/core/EvHandler $(DK_ROOT)/Test $(DK_ROOT)/platforms/hw/linux
41 # Location and filename of the driver .lib file created by this makefile.
43 OUTPUT_DIR = $(DK_ROOT)/stad/build/linux
44 OUTPUT_FILE = $(OUTPUT_DIR)/libestadrv.a
56 ifneq ($(KERNELRELEASE),)
61 ## This is the kernel build phase - set the appropriate arguments
66 # Adds the current directory as a prefix to all include directories.
68 EXTRA_CFLAGS += $(addprefix -I$(M)/, $(DK_INCS) $(OS_INCS) $(ODD_INC))
71 # Intermediate object name - this should be converted to the appropriate library file
72 # after the kernel makefile finishes its work.
77 # List of object files the kernel makefile needs to compile.
79 tiwlan_drv-y = $(DK_OBJS)
82 else # ifneq ($(KERNELRELEASE),)
87 ## This is the regular build phase - act according to the make actions
92 # The location of the kernel makefile
98 # Build the driver lib file
101 all: .depend $(OUTPUT_FILE)
109 @echo Default Compilation: PLATFORM=$(PLATFORM) DEBUG=$(DEBUG) INTR=$(INTR) WSPI=$(WSPI) XCC=$(XCC) EXTRA CFLAGS: $(EXTRA_CFLAGS)
111 # Recursively cleans the driver files.
115 $(MAKE) -C $(KERNEL_DIR) M=`pwd` ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) clean
116 @rm -f *.o *.a .*.o.cmd *~ *.~* core .depend dep $(DK_OBJS) $(DEPS)
120 # Causes the library file to get rebuilt.
125 # Recursively builds the library file.
128 $(MAKE) -C $(KERNEL_DIR) M=`pwd` ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) modules
129 @$(CROSS_COMPILE)$(AR) rcs $@ $(DK_OBJS)
132 endif # ifneq ($(KERNELRELEASE),)