3 include $(TOPDIR
)/rules.mk
7 PKG_VERSION
:=r1486-20060329
9 PKG_MD5SUM
:=71f1c654531ca8516bf7cdb5e80eb10f
11 PKG_SOURCE_URL
:=http
://snapshots.madwifi.org
/$(PKG_NAME
)
12 PKG_SOURCE
:=$(PKG_NAME
)-$(PKG_VERSION
).
tar.gz
15 PKG_BUILD_DIR
:=$(BUILD_DIR
)/$(PKG_NAME
)-$(PKG_VERSION
)
18 HAL_TARGET
:=mips-be-elf
21 HAL_TARGET
:=mips-le-elf
29 ifneq ($(CONFIG_LINUX_2_4_AR531X
),)
32 ifneq ($(CONFIG_LINUX_2_6_ARUBA
),)
33 BUS
:= PCI AHB
# no suitable HAL for AHB yet.
37 ifeq ($(findstring AHB
,$(BUS
)),AHB
)
38 BUS_MODULES
+=$(PKG_BUILD_DIR
)/ath
/ath_ahb.
$(LINUX_KMOD_SUFFIX
)
40 ifeq ($(findstring PCI
,$(BUS
)),PCI
)
41 BUS_MODULES
+=$(PKG_BUILD_DIR
)/ath
/ath_pci.
$(LINUX_KMOD_SUFFIX
)
45 include $(TOPDIR
)/package
/rules.mk
47 $(eval
$(call PKG_template
,KMOD_MADWIFI
,kmod-madwifi
,$(LINUX_VERSION
)+$(PKG_VERSION
)-$(BOARD
)-$(PKG_RELEASE
),$(ARCH
),kernel
($(LINUX_VERSION
)-$(BOARD
)-$(LINUX_RELEASE
))))
49 $(PKG_BUILD_DIR
)/.configured
:
52 MADWIFI_MAKEOPTS
= -C
$(PKG_BUILD_DIR
) \
53 PATH
="$(TARGET_PATH)" \
54 ARCH
="$(LINUX_KARCH)" \
55 CROSS_COMPILE
="$(TARGET_CROSS)" \
56 TARGET
="$(HAL_TARGET)" \
57 TOOLPREFIX
="$(KERNEL_CROSS)" \
58 TOOLPATH
="$(KERNEL_CROSS)" \
59 KERNELPATH
="$(LINUX_DIR)" \
63 $(PKG_BUILD_DIR
)/.built
:
64 ifeq ($(findstring AHB
,$(BUS
)),AHB
)
65 $(MAKE
) $(MADWIFI_MAKEOPTS
) BUS
="AHB" all
67 ifeq ($(findstring PCI
,$(BUS
)),PCI
)
68 $(MAKE
) $(MADWIFI_MAKEOPTS
) BUS
="PCI" all
70 $(RSTRIP
) $(PKG_BUILD_DIR
)/tools
/madwifi_multi
74 mkdir
-p
$(IDIR_KMOD_MADWIFI
)/etc
/modules.d
75 mkdir
-p
$(IDIR_KMOD_MADWIFI
)/etc
/init.d
76 mkdir
-p
$(IDIR_KMOD_MADWIFI
)/lib
/modules
/$(LINUX_VERSION
)
77 mkdir
-p
$(IDIR_KMOD_MADWIFI
)/usr
/sbin
78 install -m0644 .
/files
/madwifi.modules
$(IDIR_KMOD_MADWIFI
)/etc
/modules.d
/20-madwifi
79 install -m0755 .
/files
/madwifi.init
$(IDIR_KMOD_MADWIFI
)/etc
/init.d
/S20madwifi
80 $(CP
) $(PKG_BUILD_DIR
)/net80211
/wlan
*.
$(LINUX_KMOD_SUFFIX
) \
81 $(PKG_BUILD_DIR
)/ath_hal
/ath_hal.
$(LINUX_KMOD_SUFFIX
) \
83 $(PKG_BUILD_DIR
)/ath_rate
/sample
/ath_rate_sample.
$(LINUX_KMOD_SUFFIX
) \
84 $(PKG_BUILD_DIR
)/net80211
/*.
$(LINUX_KMOD_SUFFIX
) \
85 $(IDIR_KMOD_MADWIFI
)/lib
/modules
/$(LINUX_VERSION
)/
86 $(CP
) $(PKG_BUILD_DIR
)/tools
/{madwifi_multi
,80211debug
,80211stats
,athchans
,athctrl
,athdebug
,athkey
,athstats
,wlanconfig
} $(IDIR_KMOD_MADWIFI
)/usr
/sbin
/
87 $(IPKG_BUILD
) $(IDIR_KMOD_MADWIFI
) $(PACKAGE_DIR
)
89 $(STAGING_DIR
)/usr
/include/madwifi
/net80211
/ieee80211.h
: $(PKG_BUILD_DIR
)/.built
90 mkdir
-p
$(STAGING_DIR
)/usr
/include/madwifi
91 $(CP
) $(PKG_BUILD_DIR
)/include $(STAGING_DIR
)/usr
/include/madwifi
/
92 mkdir
-p
$(STAGING_DIR
)/usr
/include/madwifi
/net80211
93 $(CP
) $(PKG_BUILD_DIR
)/net80211
/*.h
$(STAGING_DIR
)/usr
/include/madwifi
/net80211
/
96 install-dev
: $(STAGING_DIR
)/usr
/include/madwifi
/net80211
/ieee80211.h
99 rm -rf
$(STAGING_DIR
)/usr
/include/madwifi
101 compile-targets
: install-dev
102 clean-targets
: uninstall-dev