639ed1e6b1a4e32a4b95e659d456596fb7405a78
[openwrt.git] / package / network / config / ltq-adsl-app / Makefile
1 #
2 # Copyright (C) 2011-2012 OpenWrt.org
3 #
4 # This is free software, licensed under the GNU General Public License v2.
5 # See /LICENSE for more information.
6 #
7
8 include $(TOPDIR)/rules.mk
9 include $(INCLUDE_DIR)/kernel.mk
10
11 PKG_NAME:=dsl_cpe_control_danube
12 PKG_VERSION:=3.24.4.4
13 PKG_RELEASE:=2
14 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
15 PKG_BUILD_DIR:=$(BUILD_DIR)/dsl_cpe_control-$(PKG_VERSION)
16 PKG_SOURCE_URL:=http://mirror2.openwrt.org/sources/
17 PKG_MD5SUM:=ee315306626b68794d3d3636dabfe161
18 PKG_MAINTAINER:=John Crispin <blogic@openwrt.org>
19
20 PKG_FIXUP:=autoreconf
21
22 PKG_CONFIG_DEPENDS:=\
23         CONFIG_LTQ_DSL_ENABLE_SOAP \
24         CONFIG_LTQ_DSL_ENABLE_DSL_EVENT_POLLING
25
26 PKG_BUILD_DEPENDS:=TARGET_lantiq_xway:kmod-ltq-adsl-danube TARGET_lantiq_ase:kmod-ltq-adsl-ase
27
28 include $(INCLUDE_DIR)/package.mk
29
30 define Package/ltq-adsl-app
31   SECTION:=net
32   CATEGORY:=Network
33   TITLE:=Lantiq DSL userland tool
34   URL:=http://www.lantiq.com/
35   DEPENDS:=@(TARGET_lantiq_xway||TARGET_lantiq_ase) +libpthread
36   MENU:=1
37 endef
38
39 define Package/ltq-adsl-app/description
40         Infineon DSL CPE API for Amazon SE, Danube and Vinax.
41 endef
42
43 LTQ_DSL_MAX_DEVICE=1
44 LTQ_DSL_LINES_PER_DEVICE=1
45 LTQ_DSL_CHANNELS_PER_LINE=1
46
47 CONFIGURE_ARGS += \
48         --with-max-device="$(LTQ_DSL_MAX_DEVICE)" \
49         --with-lines-per-device="$(LTQ_DSL_LINES_PER_DEVICE)" \
50         --with-channels-per-line="$(LTQ_DSL_CHANNELS_PER_LINE)" \
51         --enable-danube \
52         --enable-driver-include="-I$(STAGING_DIR)/usr/include/adsl/" \
53         --enable-debug-prints \
54         --enable-add-appl-cflags="-DMAX_CLI_PIPES=2" \
55         --enable-cli-support \
56         --enable-cmv-scripts \
57         --enable-debug-tool-interface \
58         --enable-adsl-led \
59         --enable-dsl-ceoc \
60         --enable-script-notification \
61         --enable-dsl-pm \
62         --enable-dsl-pm-total \
63         --enable-dsl-pm-history \
64         --enable-dsl-pm-showtime \
65         --enable-dsl-pm-channel-counters \
66         --enable-dsl-pm-datapath-counters \
67         --enable-dsl-pm-line-counters \
68         --enable-dsl-pm-channel-thresholds \
69         --enable-dsl-pm-datapath-thresholds \
70         --enable-dsl-pm-line-thresholds \
71         --enable-dsl-pm-optional-parameters
72
73 TARGET_CFLAGS += -I$(LINUX_DIR)/include
74
75 define Package/ltq-adsl-app/install
76         $(INSTALL_DIR) $(1)/etc/init.d
77         $(INSTALL_BIN) ./files/dsl_control $(1)/etc/init.d/
78
79         $(INSTALL_DIR) $(1)/sbin
80         $(INSTALL_BIN) $(PKG_BUILD_DIR)/src/dsl_cpe_control $(1)/sbin
81 endef
82
83 $(eval $(call BuildPackage,ltq-adsl-app))