###################################### # Makefile for SWAB -- # # Simple Web-based Address Book V1.1 # # # # Ju Li, Apr. 14, 1999 # # # ###################################### SHELL = /bin/tcsh OBJ = register.cgi list.cgi search.cgi full.cgi pic.cgi SRC = $(addsuffix .pl, OBJ) # you want to backup everything under this directory: # better to a remote machine in case of your machine failure BACKUPDIR = /asm/home/Moon/Bak /Home/Sun/Bak # the following should be modified accordingly title = "USTC-Boston Alumni Directory" # for database files: make sure it is not web-accessible datadir = "Data/" # page background color bgcolor = "\#ddddd7" # title logo gif file title_logo_gif = "ustc.gif" # user comments will be sent to the following sysadmin = "Ju Li (9000)" sysadmin_email = "liju99@mit.edu" # automatic mailer daemon: try `where sendmail` mailcmd = '/usr/sbin/sendmail -n -t -oi' email_subject = "Your ${title} Registration" # "yes" enable automatic mailer; "no" disables it automatic_mailer = "no" all: $(OBJ) @chmod 755 *; chmod 777 ${datadir}; %.cgi: %.pl Makefile @echo \#!`which perl`\\n \ \$$title = \'${title}\'\; \ \$$datadir = \'${datadir}\'\; \ \$$bgcolor = \'${bgcolor}\'\; \ \$$title_logo_gif = \'${title_logo_gif}\'\; \ \$$sysadmin = \'${sysadmin}\'\; \ \$$sysadmin_email = \'${sysadmin_email}\'\; \ \$$mailcmd = \'`which sendmail` -n -t -oi\'\; \ \$$email_subject = \'${email_subject}\'\; \ \$$automatic_mailer = \'${automatic_mailer}\'\; > $@; \ cat $< >> $@; c: clean clean: rm -f *~; echo cdata: rm -f Data/.*; echo b: backup backup: clean @./but ${BACKUPDIR} ########################################################## # FYI, database file format: # filename: "Family_name..Given_name..Class_number" # 0: password\n # 1: e-mail address\n # 2: office phone\n # 3: home phone\n # 4: office address\n # 5: home address\n # 6: URL\n # 7: html enabled comment paragraph ##########################################################