summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authortzafrir <tzafrir@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2007-08-15 14:26:03 +0000
committertzafrir <tzafrir@5390a7c7-147a-4af0-8ec9-7488f05a26cb>2007-08-15 14:26:03 +0000
commit06104569e56c228e5430d5921296077d7bf3eb45 (patch)
treeeb0e1557de8c1c4088cb0e45f96bb6c33cc5266f
parent625b5ef831d58bc6c853700fd793c483e9a1c76c (diff)
* Allow setting the echo canceller from the Makefile or the environment
(needed for overriding the default EC in Debian m-a builds) * Allow specifiying extra modules in the make command line: MODULES_EXTRA and SUBDIRS_EXTRA Merged revisions 2838 via svnmerge from https://origsvn.digium.com/svn/zaptel/branches/1.2 git-svn-id: http://svn.digium.com/svn/zaptel/branches/1.4@2839 5390a7c7-147a-4af0-8ec9-7488f05a26cb
-rw-r--r--Makefile2
-rw-r--r--Makefile.kernel266
-rw-r--r--README23
-rw-r--r--zconfig.h5
4 files changed, 33 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index f0cbfdf..954b4c0 100644
--- a/Makefile
+++ b/Makefile
@@ -100,6 +100,8 @@ endif
TOPDIR_MODULES:=pciradio tor2 torisa wcfxo wct1xxp wctdm wcte11xp wcusb zaptel ztd-eth ztd-loc ztdummy ztdynamic zttranscode wcte12xp
SUBDIR_MODULES:=wct4xxp wctc4xxp xpp wctdm24xxp
+TOPDIR_MODULES+=$(MODULES_EXTRA)
+SUBDIR_MODULES+=$(SUBDIRS_EXTRA)
BUILD_TOPDIR_MODULES:=$(filter-out $(MENUSELECT_MODULES),$(TOPDIR_MODULES))
BUILD_SUBDIR_MODULES:=$(filter-out $(MENUSELECT_MODULES),$(SUBDIR_MODULES))
BUILD_MODULES:=$(BUILD_TOPDIR_MODULES) $(BUILD_SUBDIR_MODULES)
diff --git a/Makefile.kernel26 b/Makefile.kernel26
index aa023ed..9a4e1ea 100644
--- a/Makefile.kernel26
+++ b/Makefile.kernel26
@@ -1,4 +1,10 @@
+ifndef ECHO_CAN_NAME
+ ECHO_CAN_NAME := MG2
+endif
+ECHO_CAN_CFLAGS := -DECHO_CAN_FROMENV -DECHO_CAN_$(ECHO_CAN_NAME)
+
EXTRA_CFLAGS := -I$(src)
+EXTRA_CFLAGS += $(ECHO_CAN_CFLAGS)
# fix typo present in CentOS and RHEL 2.6.9 kernels
BAD_KERNELS_VERS := 22 34 34.0.1 34.0.2
diff --git a/README b/README
index fef47f4..f483eeb 100644
--- a/README
+++ b/README
@@ -169,6 +169,22 @@ make install
#make config
----------------------------------
+Selecting Modules
+^^^^^^^^^^^^^^^^^
+You can select the modules you wish to build by running
+`make menuselect` . The selection of modules that you build (or rather: not
+build) is saved in the file `menuselect.makeopts`.
+
+To build extra modules / modules directory not included in the Zaptel
+distribution, use the optional variables MODULES_EXTRA and
+SUBDIRS_EXTRA:
+
+ make MODULES_EXTRA="mod1 mod2"
+ make MODULES_EXTRA="mod1 mod2" SUBDIRS_EXTRA="subdir1/ subdir1/"
+
+Note that those names are not guaranteed to continue to work on newer
+versions. Hopefully there will be no need for such extra configuration.
+
zaptel.conf
~~~~~~~~~~~
@@ -286,8 +302,8 @@ with 1). The number of the channel is the lowest unused one when it is
generated, and ditto for spans.
-PROCFS Interface: /proc/zap
-~~~~~~~~~~~~~~~~~~~~~~~~~~~
+PROCFS Interface: /proc/zaptel
+~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
A simple way to get the current list of spans and channels each span
contains is the files under /proc/zaptel . /proc/zaptel is generated by
zaptel as it loads. As each span registers to Zaptel, a file under
@@ -303,6 +319,9 @@ The title line shows the number of the span, its name and title, and
The channel line for each channel shows its channel number, name and the
actual signalling assigned to it through ztcfg.
+If the channel is in use (typically opened by Asterisk) then you will
+see an extra '(In use)'.
+
What is the license for the zaptel driver?
------------------------------------------
diff --git a/zconfig.h b/zconfig.h
index 1fbc450..52eb829 100644
--- a/zconfig.h
+++ b/zconfig.h
@@ -52,6 +52,9 @@
*/
/* #define CONFIG_ZAPTEL_MMX */
+/** If defined: the user must define exactly one ECHO_CAN_ var: */
+#ifndef ECHO_CAN_FROMENV
+
/*
* Pick your echo canceller: MARK2, MARK3, STEVE, or STEVE2 :)
*
@@ -77,7 +80,7 @@
* MARK2, KB1, and MG2 echo canceler
*/
/* #define AGGRESSIVE_SUPPRESSOR */
-
+#endif /* ifndef ECHO_CAN_FROMENV */
/*
* Define to turn off the echo canceler disable tone detector,
* which will cause zaptel to ignore the 2100 Hz echo cancel disable