diff options
author | russell <russell@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2004-09-26 03:34:29 +0000 |
---|---|---|
committer | russell <russell@5390a7c7-147a-4af0-8ec9-7488f05a26cb> | 2004-09-26 03:34:29 +0000 |
commit | 1d7d247ab9d612f392b8f812e2afe33c1204a43d (patch) | |
tree | e59fecc9bb591c39cf0f796305b71bfdc6905995 | |
parent | a5e23e7e1ac45b4dfaa741afdf1a4faacf072a25 (diff) |
make ztcfg respect INSTALL_PREFIX
git-svn-id: http://svn.digium.com/svn/zaptel/trunk@460 5390a7c7-147a-4af0-8ec9-7488f05a26cb
-rwxr-xr-x | Makefile | 5 | ||||
-rwxr-xr-x | ztcfg.h | 2 |
2 files changed, 5 insertions, 2 deletions
@@ -33,6 +33,9 @@ CFLAGS+=-DSTANDALONE_ZAPATA INSTALL_PREFIX= +CONFIG_FILE=$(INSTALL_PREFIX)/etc/zaptel.conf +CFLAGS+=-DZAPTEL_CONFIG=\"$(CONFIG_FILE)\" + BUILDVER=$(shell if uname -r | grep -q ^2.6; then echo "linux26"; else echo "linux24"; fi) MODCONF=$(shell if [ -d $(INSTALL_PREFIX)/etc/modprobe.d ]; then echo "$(INSTALL_PREFIX)/etc/modprobe.d/zaptel"; elif [ -d $(INSTALL_PREFIX)/etc/modutils ]; then echo "$(INSTALL_PREFIX)/etc/modutils/zaptel"; elif [ -f $(INSTALL_PREFIX)/etc/modprobe.conf ]; then echo "$(INSTALL_PREFIX)/etc/modprobe.conf"; elif [ -f $(INSTALL_PREFIX)/etc/modules.conf ]; then echo "$(INSTALL_PREFIX)/etc/modules.conf"; else echo $(INSTALL_PREFIX)/etc/conf.modules ; fi) @@ -310,7 +313,7 @@ install: all devices $(LIBTONEZONE) /sbin/update-modules ; \ fi -/sbin/depmod -a - [ -f $(INSTALL_PREFIX)/etc/zaptel.conf ] || install -m 644 zaptel.conf.sample $(INSTALL_PREFIX)/etc/zaptel.conf + [ -f $(CONFIG_FILE) ] || install -m 644 zaptel.conf.sample $(CONFIG_FILE) config: if [ -d $(INSTALL_PREFIX)/etc/rc.d/init.d ]; then \ @@ -22,6 +22,6 @@ #ifndef _ZTCFG_H #define _ZTCFG_H -#define CONFIG_FILENAME "/etc/zaptel.conf" +#define CONFIG_FILENAME ZAPTEL_CONFIG #define MASTER_DEVICE "/dev/zap/ctl" #endif |