#!/bin/bash LIC="# # astcrm - General purpose CRM # # General purpose CRM software for asterisk # # Copyright (C) 2007, GnuDialer Project # # Heath Schultz # Richard Lyman # # This program is free software, distributed under the terms of # # the GNU General Public License. # " if [ $# -ne "2" ] then echo echo echo "Usage: ./configure (remember the slash after each)" echo echo fi if [ $# -eq "2" ] then echo "${LIC}" > Makefile echo "all:" >> Makefile echo " g++ crm.cpp -o crm.cgi" >> Makefile echo " g++ submitinfo.cpp -o submitinfo.cgi" >> Makefile echo " echo" >> Makefile echo " echo" >> Makefile echo " echo \"If you get a compile error on AstMonitor.java, ignore it.\"" >> Makefile echo " echo" >> Makefile echo " echo" >> Makefile echo " javac AstMonitor.java" >> Makefile echo "" >> Makefile echo "clean:" >> Makefile echo " rm *.cgi" >> Makefile echo "" >> Makefile echo "install:" >> Makefile echo " chmod a+w ${2}" >> Makefile echo " cp crm.cgi ${2}" >> Makefile echo " cp submitinfo.cgi ${2}" >> Makefile echo " cp astcrm.conf ${2}" >> Makefile echo " chmod a+r ${2}astcrm.conf" >> Makefile echo " mkdir -p ${1}crm" >> Makefile echo " cp *.html ${1}crm/" >> Makefile echo " cp *.class ${1}crm/" >> Makefile echo " cp *.properties ${1}crm/" >> Makefile echo " cp *.gif ${1}crm/" >> Makefile echo "" >> Makefile echo "uninstall:" >> Makefile echo " rm -rf ${1}crm/" >> Makefile echo " rm ${2}crm.cgi" >> Makefile echo " rm ${2}submitinfo.cgi" >> Makefile echo "" >> Makefile echo "distclean:" >> Makefile echo " make clean" >> Makefile echo " rm Makefile" >> Makefile echo echo echo "Now type \"make && make install\"." echo echo fi