Switch to compat-wireless
[openwrt.git] / package / mac80211 / Makefile
1 #
2 # Copyright (C) 2007 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7 # $Id: Makefile 7440 2007-06-02 02:22:01Z nbd $
8
9 include $(TOPDIR)/rules.mk
10 include $(INCLUDE_DIR)/kernel.mk
11
12 PKG_NAME:=mac80211
13 PKG_RELEASE:=1
14
15 PKG_VERSION:=2008-04-06
16 PKG_SOURCE:=compat-wireless-$(PKG_VERSION).tar.bz2
17 PKG_SOURCE_URL:=http://linuxwireless.org/download/compat-wireless-2.6/
18 PKG_BUILD_DIR:=$(BUILD_DIR)/compat-wireless-$(PKG_VERSION)
19
20 include $(INCLUDE_DIR)/package.mk
21
22 define KernelPackage/mac80211
23 SUBMENU:=Wireless Drivers
24 TITLE:=Linux 802.11 Wireless Networking Stack
25 DEPENDS:=@LINUX_2_6_23||@LINUX_2_6_24 +kmod-crypto-arc4 +kmod-crypto-aes +wireless-tools
26 FILES:= \
27 $(PKG_BUILD_DIR)/net/mac80211/mac80211.$(LINUX_KMOD_SUFFIX) \
28 $(PKG_BUILD_DIR)/net/wireless/cfg80211.$(LINUX_KMOD_SUFFIX)
29 AUTOLOAD:=$(call AutoLoad,20,cfg80211 mac80211)
30 endef
31
32 define KernelPackage/mac80211/description
33 Linux 802.11 Wireless Networking Stack
34 endef
35
36 CONFOPTS:=MAC80211 CFG80211 NL80211 MAC80211_RC_DEFAULT_PID MAC80211_RC_PID
37
38 BUILDFLAGS:= \
39 $(foreach opt,$(CONFOPTS),-DCONFIG_$(opt)) \
40 $(if $(CONFIG_LEDS_TRIGGERS), -DCONFIG_MAC80211_LEDS -DCONFIG_LEDS_TRIGGERS) \
41 -D__CONFIG_MAC80211_RC_DEFAULT=pid
42
43 MAKE_OPTS:= \
44 CROSS_COMPILE="$(TARGET_CROSS)" \
45 ARCH="$(LINUX_KARCH)" \
46 EXTRA_CFLAGS="$(BUILDFLAGS)" \
47 $(foreach opt,$(CONFOPTS),CONFIG_$(opt)=m) \
48 CONFIG_NL80211=y \
49 CONFIG_MAC80211_RC_PID=y \
50 CONFIG_MAC80211_LEDS=$(CONFIG_LEDS_TRIGGERS) \
51 LINUXINCLUDE="-I$(PKG_BUILD_DIR)/include -I$(LINUX_DIR)/include -include linux/autoconf.h" \
52 KLIB_BUILD="$(LINUX_DIR)" \
53
54 define Build/Prepare
55 rm -rf $(PKG_BUILD_DIR)
56 mkdir -p $(PKG_BUILD_DIR)
57 $(PKG_UNPACK)
58 $(if $(QUILT),touch $(PKG_BUILD_DIR)/.quilt_used)
59 endef
60
61 define Build/Compile
62 $(MAKE) -C "$(PKG_BUILD_DIR)" $(MAKE_OPTS) all
63 endef
64
65 define Build/InstallDev
66 mkdir -p $(1)/usr/include/mac80211
67 $(CP) $(PKG_BUILD_DIR)/net/mac80211/*.h $(PKG_BUILD_DIR)/include/* $(1)/usr/include/mac80211/
68 endef
69
70 define KernelPackage/mac80211/install
71 $(INSTALL_DIR) $(1)/lib/wifi
72 $(INSTALL_DATA) ./files/lib/wifi/mac80211.sh $(1)/lib/wifi
73 endef
74
75 $(eval $(call KernelPackage,mac80211))
This page took 0.058704 seconds and 5 git commands to generate.