[packages] et131x: use in-kernel driver for 2.6.30+
[openwrt/svn-archive/archive.git] / net / et131x / Makefile
1 include $(TOPDIR)/rules.mk
2 include $(INCLUDE_DIR)/kernel.mk
3
4 PKG_NAME:=et131x
5 PKG_VERSION:=1.2.3-3
6 PKG_RELEASE:=1
7
8 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
9 PKG_SOURCE_URL:=@SF/et131x
10 PKG_MD5SUM:=9496422c7d218f27bae1be42a04d122e
11
12 include $(INCLUDE_DIR)/package.mk
13
14 ifneq ($(CONFIG_LINUX_2_6_25),)
15 MODULE:=$(PKG_BUILD_DIR)/et131x.$(LINUX_KMOD_SUFFIX)
16 else
17 MODULE:=$(LINUX_DIR)/drivers/staging/et131x/et131x.$(LINUX_KMOD_SUFFIX)
18 endif
19
20 define KernelPackage/et131x
21 SUBMENU:=Network Devices
22 TITLE:=Agere ET131x Gigabit Ethernet driver
23 URL:=http://sourceforge.net/projects/et131x
24 FILES:=$(MODULE)
25 KCONFIG:= \
26 CONFIG_ET131X=m \
27 CONFIG_ET131X_DEBUG=n
28 DEPENDS:=@LINUX_2_6 @PCI_SUPPORT
29 AUTOLOAD:=$(call AutoLoad,70,et131x)
30 endef
31
32 define KernelPackage/et131x/description
33 This package contains the et131x kernel module.
34 endef
35
36 ifneq ($(CONFIG_LINUX_2_6_25),)
37 define Build/Compile
38 $(MAKE) -C "$(LINUX_DIR)" \
39 ARCH="$(LINUX_KARCH)" \
40 CROSS_COMPILE="$(TARGET_CROSS)" \
41 SUBDIRS="$(PKG_BUILD_DIR)" \
42 $(PKG_EXTRA_KCONFIG) \
43 EXTRA_CFLAGS="$(PKG_EXTRA_CFLAGS)"
44 endef
45 else
46 define Build/Prepare
47 # nothing to do
48 endef
49 define Build/Configure
50 # nothing to do
51 endef
52 define Build/Compile
53 # nothing to do
54 endef
55 endif
56
57 $(eval $(call KernelPackage,et131x))
58