[Asterisk-cvs] zaptel Makefile,1.88,1.89
kpfleming
kpfleming
Fri Sep 30 12:00:36 CDT 2005
Update of /usr/cvsroot/zaptel
In directory mongoose.digium.com:/tmp/cvs-serv20927
Modified Files:
Makefile
Log Message:
don't try to mess with module configuration file if it's not found (issue #5337)
Index: Makefile
===================================================================
RCS file: /usr/cvsroot/zaptel/Makefile,v
retrieving revision 1.88
retrieving revision 1.89
diff -u -d -r1.88 -r1.89
--- Makefile 15 Sep 2005 00:17:23 -0000 1.88
+++ Makefile 30 Sep 2005 15:57:03 -0000 1.89
@@ -332,34 +332,36 @@
install -D -m 644 tonezone.h $(INSTALL_PREFIX)/usr/include/tonezone.h
install -m 644 doc/ztcfg.8 $(INSTALL_PREFIX)/usr/share/man/man8
install -m 644 doc/zttool.8 $(INSTALL_PREFIX)/usr/share/man/man8
- if [ -f $(MODCONF) ]; then mv -f $(MODCONF) $(MODCONF).bak ; fi
- cat $(MODCONF).bak | grep -v "alias char-major-250" | \
- grep -v "post-install torisa /sbin/ztcfg" | \
- grep -v "post-install wcfxsusb /sbin/ztcfg" | \
- grep -v "alias wctdm" | \
- grep -v "post-install wctdm /sbin/ztcfg" > $(MODCONF) || true
- if ! grep "options torisa" $(MODCONF); then \
- echo "options torisa base=$(BASEADDR)" >> $(MODCONF); \
- fi
- if ! grep "alias char-major-196" $(MODCONF); then \
- echo "alias char-major-196 $(PRIMARY)" >> $(MODCONF); \
- fi
- for x in $(MODULES); do \
- if ! grep -q "post-install $$x" $(MODCONF); then \
- if ! grep -q "install $$x " $(MODCONF); then \
- if [ "$$x" != "zaptel" ] ; then \
- if [ -f zaptel.ko ]; then echo "install $$x /sbin/modprobe --ignore-install $$x && /sbin/ztcfg" >> $(MODCONF); \
- else echo "post-install $$x /sbin/ztcfg" >> $(MODCONF); \
+ if [ -n "$(MODCONF)" ]; then \
+ if [ -f $(MODCONF) ]; then mv -f $(MODCONF) $(MODCONF).bak ; fi; \
+ cat $(MODCONF).bak | grep -v "alias char-major-250" | \
+ grep -v "post-install torisa /sbin/ztcfg" | \
+ grep -v "post-install wcfxsusb /sbin/ztcfg" | \
+ grep -v "alias wctdm" | \
+ grep -v "post-install wctdm /sbin/ztcfg" > $(MODCONF); \
+ if ! grep "options torisa" $(MODCONF); then \
+ echo "options torisa base=$(BASEADDR)" >> $(MODCONF); \
+ fi; \
+ if ! grep "alias char-major-196" $(MODCONF); then \
+ echo "alias char-major-196 $(PRIMARY)" >> $(MODCONF); \
+ fi; \
+ for x in $(MODULES); do \
+ if ! grep -q "post-install $$x" $(MODCONF); then \
+ if ! grep -q "install $$x " $(MODCONF); then \
+ if [ "$$x" != "zaptel" ] ; then \
+ if [ -f zaptel.ko ]; then echo "install $$x /sbin/modprobe --ignore-install $$x && /sbin/ztcfg" >> $(MODCONF); \
+ else echo "post-install $$x /sbin/ztcfg" >> $(MODCONF); \
+ fi; \
fi; \
fi; \
fi; \
+ done; \
+ if ! grep "ias wcfxs" $(MODCONF); then \
+ echo "alias wcfxs wctdm" >> $(MODCONF); \
+ fi; \
+ if ! grep "alias wct2xxp" $(MODCONF); then \
+ echo "alias wct2xxp wct4xxp" >> $(MODCONF); \
fi; \
- done
- if ! grep "alias wcfxs" $(MODCONF); then \
- echo "alias wcfxs wctdm" >> $(MODCONF); \
- fi
- if ! grep "alias wct2xxp" $(MODCONF); then \
- echo "alias wct2xxp wct4xxp" >> $(MODCONF); \
fi
if [ -d /etc/modutils ]; then \
/sbin/update-modules ; \
More information about the svn-commits
mailing list