summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorTzafrir Cohen <tzafrir.cohen@xorcom.com>2014-07-03 14:08:02 +0000
committerTzafrir Cohen <tzafrir.cohen@xorcom.com>2014-07-03 14:08:02 +0000
commitda469fd9f67bcb3424102e1503894387071d84aa (patch)
tree31be49f75dcf51bccf9df14b937738a438510ec4 /Makefile
parenteaee92198d89f7feb4206b412104f439bc80754f (diff)
dahdi_span_config_hook: automatically register new dahdi channels
Install a hook script for DAHDI to register new spans with Asterisk automatically by running: asterisk -rx 'dahdi create channel FIRST LAST' Review: https://reviewboard.asterisk.org/r/3157/ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@417863 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile4
1 files changed, 4 insertions, 0 deletions
diff --git a/Makefile b/Makefile
index 09bcb5b03..6a517889d 100644
--- a/Makefile
+++ b/Makefile
@@ -157,6 +157,8 @@ LINKER_SYMBOL_PREFIX=
# The file /etc/asterisk.makeopts will also be included but can be overridden
# by the file in your home directory.
+DAHDI_UDEV_HOOK_DIR = /usr/share/dahdi/span_config.d
+
GLOBAL_MAKEOPTS=$(wildcard /etc/asterisk.makeopts)
USER_MAKEOPTS=$(wildcard ~/.asterisk.makeopts)
@@ -589,6 +591,8 @@ bininstall: _all installdirs $(SUBDIRS_INSTALL) main-bininstall
if [ -f contrib/firmware/iax/iaxy.bin ] ; then \
$(INSTALL) -m 644 contrib/firmware/iax/iaxy.bin "$(DESTDIR)$(ASTDATADIR)/firmware/iax/iaxy.bin"; \
fi
+ $(INSTALL) -d $(DESTDIR)/$(DAHDI_UDEV_HOOK_DIR)
+ $(INSTALL) -m 644 contrib/scripts/dahdi_span_config_hook $(DESTDIR)$(DAHDI_UDEV_HOOK_DIR)/40-asterisk
$(SUBDIRS_INSTALL):
+@DESTDIR="$(DESTDIR)" ASTSBINDIR="$(ASTSBINDIR)" $(SUBMAKE) -C $(@:-install=) install