[lantiq] add vdsl driver
[openwrt/svn-archive/archive.git] / package / platform / lantiq / ltq-vdsl / Makefile
1 # Copyright (C) 2012 OpenWrt.org
2 #
3 # This is free software, licensed under the GNU General Public License v2.
4 # See /LICENSE for more information.
5
6 include $(TOPDIR)/rules.mk
7 include $(INCLUDE_DIR)/kernel.mk
8
9 PKG_NAME:=ltq-vdsl-vr9
10 PKG_VERSION:=4.11.4
11 PKG_RELEASE:=1
12
13 PKG_BASE_NAME:=drv_dsl_cpe_api_vrx
14 PKG_SOURCE:=$(PKG_BASE_NAME)-$(PKG_VERSION).tar.gz
15 PKG_BUILD_DIR:=$(KERNEL_BUILD_DIR)/drv_dsl_cpe_api-$(PKG_VERSION)
16 PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources/
17 PKG_MD5SUM:=b6d9c1e3c5db1bfcd6e81bb2f582cadb
18
19 PKG_MAINTAINER:=John Crispin <blogic@openwrt.org>
20
21 include $(INCLUDE_DIR)/package.mk
22
23 define KernelPackage/ltq-vdsl-vr9
24 TITLE:=vdsl driver
25 SECTION:=sys
26 SUBMENU:=Network Devices
27 DEPENDS:=@TARGET_lantiq_xway +kmod-ltq-vdsl-vr9-mei
28 FILES:=$(PKG_BUILD_DIR)/src/drv_dsl_cpe_api.ko
29 AUTOLOAD:=$(call AutoLoad,51,drv_dsl_cpe_api)
30 endef
31
32 define Package/ltq-vdsl-vr9/description
33 This package contains the Lantiq DSL CPE API driver.
34
35 Supported Devices:
36 - VRX200 Family
37 endef
38
39 EXTRA_CFLAGS = -fno-pic -mno-abicalls -mlong-calls -G 0
40
41 CONFIGURE_ARGS += --enable-kernel-include="$(LINUX_DIR)/include" \
42 --with-max-device="1" \
43 --with-lines-per-device="1" \
44 --with-channels-per-line="1" \
45 --enable-vrx \
46 --enable-ifxos \
47 --enable-ifxos-include="-I$(STAGING_DIR)/usr/include/ifxos" \
48 --enable-driver-include="-I$(STAGING_DIR)/usr/include/vdsl" \
49 --enable-add-drv-cflags="-DMODULE -DINCLUDE_DSL_ATM_PTM_INTERFACE_SUPPORT -DDSL_DEBUG_DISABLE" \
50 --enable-adsl-led=no \
51 --enable-adsl-mib=no \
52 --enable-dsl-ceoc=no \
53 --enable-dsl-bonding=no \
54 --enable-linux-26 \
55 --enable-kernelbuild="$(LINUX_DIR)" \
56 KERNEL_ARCH=mips
57
58 CONFIGURE_ARGS += --enable-model=full
59 #CONFIGURE_ARGS += --enable-model=lite
60 #CONFIGURE_ARGS += --enable-model=footprint
61 #CONFIGURE_ARGS += --enable-model=typical
62 #CONFIGURE_ARGS += --enable-model=debug
63
64 define Build/InstallDev
65 $(INSTALL_DIR) $(1)/usr/include/drv_vdsl_cpe_api
66 $(CP) $(PKG_BUILD_DIR)/src/include/drv_dsl_cpe*.h $(1)/usr/include/drv_vdsl_cpe_api/
67 endef
68
69 $(eval $(call KernelPackage,ltq-vdsl-vr9))