2 # Copyright (C) 2006 OpenWrt.org
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
9 include $(TOPDIR
)/rules.mk
10 include $(INCLUDE_DIR
)/kernel.mk
12 PKG_NAME
:=kmod-wlcompat
15 PKG_BUILD_DIR
:=$(KERNEL_BUILD_DIR
)/$(PKG_NAME
)
17 include $(INCLUDE_DIR
)/package.mk
19 define Package
/kmod-wlcompat
/Default
21 CATEGORY
:=Kernel drivers
22 DEPENDS
:=@PACKAGE_kmod-brcm-wl||PACKAGE_kmod-brcm-wl-mimo
+wireless-tools
24 TITLE
:=Broadcom wl wrapper module
26 This package contains a wrapper module
, that provides Wireless Extension
\\\
27 support for the proprietary Broadcom wl module.
28 VERSION
:=$(LINUX_VERSION
)+$(BOARD
)-$(PKG_RELEASE
)
31 define Package
/kmod-wlcompat
32 $(call Package
/kmod-wlcompat
/Default
)
35 define Package
/kmod-wlcompat-debug
36 $(call Package
/kmod-wlcompat
/Default
)
40 This is a debugging version.
44 mkdir
-p
$(PKG_BUILD_DIR
)
45 $(CP
) .
/src
/* $(PKG_BUILD_DIR
)/
49 $(MAKE
) -C
"$(LINUX_DIR)" \
50 CROSS_COMPILE
="$(TARGET_CROSS)" \
51 ARCH
="$(LINUX_KARCH)" \
52 SUBDIRS
="$(PKG_BUILD_DIR)" \
53 EXTRA_CFLAGS
="-DDEBUG -I$(LINUX_DIR)/arch/mips/bcm947xx/include -I$(PKG_BUILD_DIR)/include" \
55 mv
$(PKG_BUILD_DIR
)/wlcompat.o
$(PKG_BUILD_DIR
)/wlcompat-debug.o
56 $(MAKE
) -C
"$(LINUX_DIR)" \
57 CROSS_COMPILE
="$(TARGET_CROSS)" \
58 ARCH
="$(LINUX_KARCH)" \
59 SUBDIRS
="$(PKG_BUILD_DIR)" \
60 EXTRA_CFLAGS
="-I$(LINUX_DIR)/arch/mips/bcm947xx/include -I$(PKG_BUILD_DIR)/include" \
64 define Package
/kmod-wlcompat
/install
65 $(INSTALL_DIR
) $(1)/lib
/modules
/$(LINUX_VERSION
)
66 $(CP
) $(PKG_BUILD_DIR
)/wlcompat.o
$(1)/lib
/modules
/$(LINUX_VERSION
)/
67 $(INSTALL_DIR
) $(1)/etc
/modules.d
68 echo
"wlcompat" > $(1)/etc
/modules.d
/30-wlcompat
71 define Package
/kmod-wlcompat-debug
/install
72 $(INSTALL_DIR
) $(1)/lib
/modules
/$(LINUX_VERSION
)
73 $(CP
) $(PKG_BUILD_DIR
)/wlcompat-debug.o
$(1)/lib
/modules
/$(LINUX_VERSION
)/
76 $(eval
$(call BuildPackage
,kmod-wlcompat
))
77 $(eval
$(call BuildPackage
,kmod-wlcompat-debug
))