Index: Makefile =================================================================== RCS file: /usr/cvsroot/astcc/Makefile,v retrieving revision 1.5 diff -u -r1.5 Makefile --- Makefile 2 Oct 2004 02:48:25 -0000 1.5 +++ Makefile 18 Dec 2004 09:29:42 -0000 @@ -1,49 +1,51 @@ -HTTPDIR=$(shell if [ -d /var/www ]; then echo "/var/www"; else echo "/home/httpd"; fi) -EXTENSIONS=/etc/asterisk/extensions.conf -SOUNDSDIR=/var/lib/asterisk/sounds + AGIDIR=/var/lib/asterisk/agi-bin ASTCC=/var/lib/astcc +CONFDIR=/etc/asterisk +EXTENSIONS=$(CONFDIR)/extensions.conf +HTTPDIR=$(shell if [ -d /var/www ]; then echo "/var/www"; else echo "/home/httpd"; fi) +SOUNDSDIR=/usr/share/asterisk/sounds USER=apache all: install: all - @[ -d $(DESTDIR)$(HTTPDIR) ] || ( echo "No HTTP directory" && exit 1 ) - @[ -d $(DESTDIR)$(HTTPDIR)/html ] || ( echo "No http directory" && exit 1 ) - @[ -d $(DESTDIR)$(HTTPDIR)/cgi-bin ] || ( echo "No cgi-bin directory" && exit 1 ) - mkdir -p $(DESTDIR)$(HTTPDIR)/html/_astcc - mkdir -p $(DESTDIR)$(HTTPDIR)/cgi-bin/astcc-admin - chmod 755 ./astcc.agi - chmod 755 ./astcc-admin.cgi - echo | ./astcc.agi >/dev/null - ./astcc-admin.cgi >/dev/null - install -m 755 -o $(USER) -g root astcc-admin.cgi $(DESTDIR)$(HTTPDIR)/cgi-bin/astcc-admin/astcc-admin.cgi - install -m 644 -o $(USER) -g root astcc.png $(DESTDIR)$(HTTPDIR)/html/_astcc/astcc.png - install -m 755 -o root -g root astcc.agi $(DESTDIR)$(AGIDIR)/astcc.agi - if ! grep -q "#include $(ASTCC)/astcc-exten.conf" $(EXTENSIONS); then \ - echo ";" >> $(DESTDIR)$(EXTENSIONS); \ - echo "; Include entries for Asterisk Calling Card" >> $(DESTDIR)$(EXTENSIONS); \ - echo ";" >>$(DESTDIR)$(EXTENSIONS); \ - echo '#include $(ASTCC)/astcc-exten.conf' >> $(EXTENSIONS); \ - fi - mkdir -p $(DESTDIR)$(ASTCC) - touch $(DESTDIR)$(ASTCC)/astcc-exten.conf - chown $(USER) $(DESTDIR)$(ASTCC)/astcc-exten.conf - touch $(DESTDIR)$(ASTCC)/astcc-config.conf - chown $(USER) $(DESTDIR)$(ASTCC)/astcc-config.conf - touch $(DESTDIR)$(ASTCC)/users-astcc-config.conf - chown $(USER) $(DESTDIR)$(ASTCC)/users-astcc-config.conf + mkdir -p $(DESTDIR)$(HTTPDIR) + mkdir -p $(DESTDIR)$(HTTPDIR)/html/_astcc + mkdir -p $(DESTDIR)$(HTTPDIR)/cgi-bin/astcc-admin + chmod 755 ./astcc.agi + chmod 755 ./astcc-admin.cgi + echo | ./astcc.agi >/dev/null + ./astcc-admin.cgi >/dev/null + install -m 755 -o $(USER) -g root astcc-admin.cgi $(DESTDIR)$(HTTPDIR)/cgi-bin/astcc-admin/astcc-admin.cgi + install -m 644 -o $(USER) -g root astcc.png $(DESTDIR)$(HTTPDIR)/html/_astcc/astcc.png + mkdir -p $(DESTDIR)$(AGIDIR) + install -m 755 -o root -g root astcc.agi $(DESTDIR)$(AGIDIR)/astcc.agi + mkdir -p $(DESTDIR)$(CONFDIR) + touch $(DESTDIR)$(EXTENSIONS) + if ! grep -q "#include $(ASTCC)/astcc-exten.conf" $(DESTDIR)$(EXTENSIONS); then \ + echo ";" >> $(DESTDIR)$(EXTENSIONS); \ + echo "; Include entries for Asterisk Calling Card" >> $(DESTDIR)$(EXTENSIONS); \ + echo ";" >>$(DESTDIR)$(EXTENSIONS); \ + echo '#include $(ASTCC)/astcc-exten.conf' >> $(DESTDIR)$(EXTENSIONS); \ + fi + mkdir -p $(DESTDIR)$(ASTCC) + touch $(DESTDIR)$(ASTCC)/astcc-exten.conf + chown $(USER) $(DESTDIR)$(ASTCC)/astcc-exten.conf + touch $(DESTDIR)$(ASTCC)/astcc-config.conf + chown $(USER) $(DESTDIR)$(ASTCC)/astcc-config.conf + touch $(DESTDIR)$(ASTCC)/users-astcc-config.conf + chown $(USER) $(DESTDIR)$(ASTCC)/users-astcc-config.conf - for x in sounds/*.gsm; do \ - install -m 644 $$x $(DESTDIR)$(SOUNDSDIR); \ - done + mkdir -p $(DESTDIR)$(SOUNDSDIR) + for x in sounds/*.gsm; do \ + install -m 644 $$x $(DESTDIR)$(SOUNDSDIR); \ + done - @echo "/" - @echo "*" - @echo "* Please point your browser to:" - @echo "*" - @echo "* http://`hostname`/cgi-bin/astcc-admin/astcc-admin.cgi" - @echo "*" - @echo "* to get started..." - @echo "*" - @echo "\\" + @echo "/*" + @echo "* Please point your browser to:" + @echo "*" + @echo "* http://`hostname`/cgi-bin/astcc-admin/astcc-admin.cgi" + @echo "*" + @echo "* to get started..." + @echo "*/" Index: astcc-admin.cgi =================================================================== RCS file: /usr/cvsroot/astcc/astcc-admin.cgi,v retrieving revision 1.11 diff -u -r1.11 astcc-admin.cgi --- astcc-admin.cgi 2 Oct 2004 02:48:25 -0000 1.11 +++ astcc-admin.cgi 18 Dec 2004 09:30:03 -0000 @@ -142,7 +142,7 @@ $fgcolor = "#999999"; } $body .= "
![]() | Asterisk™ Calling Card Admin: $mode" .
- " $msg |
$menu | $body |
$copyright | |
![]() | Asterisk™ Calling Card Admin: $mode" .
+ " $msg |
$menu | $body |
$copyright |
![]() | Asterisk™ Calling Card Info Sheet" .
- " $msg |
$menu | $body |
$copyright | |
![]() | Asterisk™ Calling Card Info Sheet" .
+ " $msg |
$menu | $body |
$copyright |