source: packages/libs/zaptel-1.4.x/Makefile @ 21792

Last change on this file since 21792 was 21792, checked in by claudio, 6 years ago

[package] zaptel: fix typo introduced in r21786

File size: 3.7 KB
Line 
1#
2# Copyright (C) 2006-2009 OpenWrt.org
3#
4# This is free software, licensed under the GNU General Public License v2.
5# See /LICENSE for more information.
6#
7
8include $(TOPDIR)/rules.mk
9include $(INCLUDE_DIR)/kernel.mk
10
11PKG_NAME:=zaptel
12PKG_VERSION:=1.4.12.1
13PKG_RELEASE:=2
14
15PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz
16PKG_SOURCE_URL:=http://downloads.asterisk.org/pub/telephony/zaptel/releases/ \
17        http://ftp.digium.com/pub/zaptel/releases/
18PKG_MD5SUM:=71e83a020b020fa60905edecf70e95a3
19
20include $(INCLUDE_DIR)/package.mk
21
22define Package/zaptel14/Default
23  TITLE:=Zaptel
24  URL:=http://ftp.digium.com/pub/zaptel/releases
25endef
26
27define KernelPackage/zaptel14/Default
28  TITLE:=Zaptel (kernel module)
29  SUBMENU:=Other modules
30endef
31
32define KernelPackage/zaptel14
33  $(call KernelPackage/zaptel14/Default)
34  KCONFIG:=CONFIG_FTRACE=y \
35                        CONFIG_TRACING=y \
36                        CONFIG_KMEMTRACE=y \
37                        CONFIG_BRANCH_PROFILE_NONE=y \
38                        CONFIG_RING_BUFFER_BENCHMARK=n \
39  FILES:=$(PKG_BUILD_DIR)/kernel/zaptel.$(LINUX_KMOD_SUFFIX) \
40        $(PKG_BUILD_DIR)/kernel/ztdummy.$(LINUX_KMOD_SUFFIX)
41  AUTOLOAD:=$(call AutoLoad,70,zaptel ztdummy)
42endef
43
44define KernelPackage/zaptel14/description
45 This package contains the Zaptel core module and ztdummy driver.
46endef
47
48define KernelPackage/zaptel14-wcusb
49  $(call KernelPackage/zaptel14/Default)
50  DEPENDS += +kmod-zaptel14
51  FILES:=$(PKG_BUILD_DIR)/kernel/wcusb.$(LINUX_KMOD_SUFFIX)
52  AUTOLOAD:=$(call AutoLoad,71,wcusb)
53endef
54
55define KernelPackage/zaptel14-wcusb/description
56 This package contains the Zaptel S100U usb driver.
57endef
58
59define KernelPackage/zaptel14-wctdm
60  $(call KernelPackage/zaptel14/Default)
61  DEPENDS += +kmod-zaptel14
62  FILES:=$(PKG_BUILD_DIR)/kernel/wctdm.$(LINUX_KMOD_SUFFIX)
63  AUTOLOAD:=$(call AutoLoad,71,wctdm)
64endef
65
66define KernelPackage/zaptel14-wctdm/description
67 This package contains the Zaptel wctdm driver.
68endef
69
70define Package/zaptel14-util
71  $(call Package/zaptel14/Default)
72  SECTION:=utils
73  CATEGORY:=Utilities
74  TITLE+= utils
75  DEPENDS += +kmod-zaptel14
76endef
77
78define Package/zaptel14-util/description
79 This package contains the zaptel utils.
80endef
81
82define Package/zaptel14-libtonezone
83  $(call Package/zaptel14/Default)
84  SECTION:=libs
85  CATEGORY:=Libraries
86  TITLE+= libtonezone (library)
87  DEPENDS += +kmod-zaptel14
88endef
89
90define Package/zaptel14-libtonezone/description
91 This package contains the libraries for accessing zaptel/dummy drivers.
92endef
93
94MAKE_FLAGS:= \
95        ARCH="$(LINUX_KARCH)" \
96        CC="$(TARGET_CC) $(TARGET_CFLAGS)" \
97        LD="$(TARGET_CROSS)ld" \
98        CROSS_COMPILE="$(TARGET_CROSS)" \
99        KVERS="$(LINUX_VERSION)" \
100        KSRC="$(LINUX_DIR)" \
101        TOPDIR_MODULES="zaptel ztdummy wcusb wctdm" \
102        SUBDIR_MODULES=""
103
104define Build/Compile/kmod
105        $(MAKE) -C $(PKG_BUILD_DIR) \
106                $(MAKE_FLAGS) \
107                modules
108endef
109
110define Build/Compile/user
111        $(MAKE) -C $(PKG_BUILD_DIR) \
112                ARCH="$(LINUX_KARCH)" \
113                DESTDIR="$(PKG_INSTALL_DIR)" \
114                install-libs install-include zttest
115endef
116
117define Build/Compile
118        $(call Build/Compile/kmod)
119        $(call Build/Compile/user)
120endef
121
122define Build/InstallDev
123        $(INSTALL_DIR)  $(STAGING_DIR)/usr/include
124        $(CP) $(PKG_INSTALL_DIR)/usr/include/zaptel $(STAGING_DIR)/usr/include/
125        $(INSTALL_DIR)  $(STAGING_DIR)/usr/lib
126        $(CP)  $(PKG_INSTALL_DIR)/usr/lib/libtonezone.* $(STAGING_DIR)/usr/lib/
127endef
128
129define Package/zaptel14-util/install
130        $(INSTALL_DIR) $(1)/usr/bin
131        $(INSTALL_BIN) $(PKG_BUILD_DIR)/zttest $(1)/usr/bin/
132endef
133
134define Package/zaptel14-libtonezone/install
135        $(INSTALL_DIR) $(1)/usr/lib
136        $(CP) $(PKG_INSTALL_DIR)/usr/lib/libtonezone.so.* $(1)/usr/lib/
137endef
138
139$(eval $(call KernelPackage,zaptel14))
140$(eval $(call KernelPackage,zaptel14-wcusb))
141$(eval $(call KernelPackage,zaptel14-wctdm))
142$(eval $(call BuildPackage,zaptel14-util))
143$(eval $(call BuildPackage,zaptel14-libtonezone))
Note: See TracBrowser for help on using the repository browser.