Use the KernelPackage template instead of kmod-foo
[openwrt.git] / package / zd1211 / Makefile
1 #
2 # Copyright (C) 2006 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 3297 2006-03-02 23:42:52Z florian $
8
9 include $(TOPDIR)/rules.mk
10 include $(INCLUDE_DIR)/kernel.mk
11
12 PKG_NAME:=zd1211
13 PKG_VERSION:=r83
14 PKG_RELEASE:=1
15
16 PKG_SOURCE:=$(PKG_NAME)-driver-$(PKG_VERSION).tgz
17 PKG_SOURCE_URL:=http://zd1211.ath.cx/download/
18 PKG_MD5SUM:=a5751f0e6f1f368689077fa7758a4932
19 PKG_CAT:=zcat
20
21 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/$(PKG_NAME)-driver-$(PKG_VERSION)
22
23 include $(INCLUDE_DIR)/package.mk
24
25 #FIXME: add proper dependency handling on kmod-usb-core packages
26 define KernelPackage/zd1211
27 SUBMENU:=Wireless Drivers
28 DEPENDS:=@LINUX_2_6&&!LINUX_2_6_UML
29 TITLE:=Driver for Zydas 1211 based USB devices
30 DESCRIPTION:=\
31 This package contains a Linux driver for the ZyDAS ZD1211 802.11b/g \\\
32 USB-WLAN-Chip.\\\
33 Initially contributed by ZyDAS, this driver is actively maintained by the \\\
34 open source community.
35 VERSION:=$(LINUX_VERSION)+$(PKG_VERSION)-$(BOARD)-$(PKG_RELEASE)
36 FILES:=$(PKG_BUILD_DIR)/zd1211.$(LINUX_KMOD_SUFFIX)
37 AUTOLOAD:=$(call AutoLoad,60,zd1211)
38 endef
39
40 define Package/zd1211-utils
41 SECTION:=utils
42 CATEGORY:=Utilities
43 TITLE:=zd1211 user-space utilities
44 DESCRIPTION:=zd1211 user-space utilities : apdbg, zd1211-sta
45 endef
46
47 define Build/Compile
48 $(MAKE) -C $(PKG_BUILD_DIR) \
49 ARCH="$(LINUX_KARCH)" \
50 CROSS_COMPILE="$(TARGET_CROSS)" \
51 CC="$(TARGET_CC)" \
52 CPP="$(TARGET_CC)" \
53 LD="$(TARGET_CROSS)ld" \
54 KERNELVERSION="$(KERNEL)" \
55 KERNEL_SOURCE="$(LINUX_DIR)" \
56 KDIR="$(LINUX_DIR)" \
57 all
58 $(TARGET_CC) $(PKG_BUILD_DIR)/apdbg.c -o $(PKG_BUILD_DIR)/apdbg
59 endef
60
61 define Package/zd1211-utils/install
62 $(INSTALL_DIR) $(1)/usr/sbin
63 $(CP) $(PKG_BUILD_DIR)/apdbg $(1)/usr/sbin/
64 $(CP) $(PKG_BUILD_DIR)/sta $(1)/usr/sbin/$(PKG_NAME)-sta
65 endef
66
67 $(eval $(call Package,zd1211-utils))
68 $(eval $(call KernelPackage,zd1211))
This page took 0.047873 seconds and 5 git commands to generate.