Distribuce programu je ulozena v souboru
saczechUj.tar.gzDistribuci je treba rozbalit pouzitim prikazu
gunzip < saczechUj.tar.gz | tar xvf -Soubory budou rozbaleny do podadresare saczechUj. Pote nasleduje faze prizpusobeni vasim konkretnim podminkam. Veskere zasahy se tykaji souboru make, ktery je soucasti distribuce. Je treba jednak zkontrolovat jeho prvni radek (zacinajici znaky #!), zda obsahuje platny prikaz pro spusteni interpretu jazyka Perl. Dale v tomto souboru nasleduji promenne, jejichz hodnoty mozna uznate za vhodne zmenit. Jsou to:
Necht napr. login adresar uzivatele je /home/group/USER,
WWW koren tohoto uzivatele je /home/group/USER/www
a teto UNIXove ceste odpovida virtualni URL cesta http://www.kdesi.ca/~USER/
(tj., vsechny soubory, ktere uzivatel umisti do jakeholiv podadresare pod /home/group/USER/www jsou k dispozici celemu svetu - pokud to uzivatel dovoli vhodnym nastavenim modu jejich pristupu - vetvenim z tohoto URL). Necht uzivatel umisti sve CGI skripty do
/home/group/USER/www/cgi-bin,
vnejsi svet je pak muze vyvolavat jako
http://www.kdesi.ca/~USER/cgi-bin/toASCII.cgi/..., etc.
V tomto pripade je nutno tri vyse uvedene promenne nastavit takto:$homedir="/home/group/USER";(uvadejte bez zaverecnych zpetnych lomitek).
$user="/~USER";
$cgipath="/~USER/cgi-bin";Pokud je mozno skripty instalovat na serveru globalne (implicitne do /www/cgi-bin), coz je situace odpovidajici puvodnimu SaCzechu, budou volany jako http://www.kdesi.ca/cgi-bin/toASCII.cgi/~USER/..., etc.
a nastaveni prislusnych promennych je:$homedir="";
$user="";
$cgipath="/cgi-bin";
SaCzech-Uj definuje tyto promenne a pole nasledove:if ( $names eq "WWWdia" ) { $cgiprefix="to"; # nadpisy kodu ve whichcode $codename{"ASCII"}="ASCII"; $codename{"CP1250"}="MS Win"; $codename{"CP852"}="PC Latin 2"; $codename{"ISO-8859-2"}="ISO Latin 2"; $codename{"ISO-8859-1"}="ISO Latin 1"; $codename{"KEYBCS2"}="KEYBCS2"; $codename{"KOI8-CS"}="KOI8-CS"; $codename{"MAC"}="Mac"; @codes= ("ASCII","CP1250","MAC","ISO-8859-2","ISO-8859-1","CP852","KEYBCS2","KOI8-CS"); %abcNames=("ASCII","ASCII","CP1250","CP1250","MAC","MAC", "ISO-8859-2","ISO-8859-2","ISO-8859-1","ISO-8859-1","CP852","CP852", "KEYBCS2","KEYBCS2","KOI8-CS","KOI8-CS"); %altCodes=("ASCII","ascii","CP1250","1250","MAC","mac","ISO-8859-2","iso", "ISO-8859-1","iso1","CP852","852","KEYBCS2","kam","KOI8-CS","koi8-cs"); } elsif ( $names eq "EUnet") { $cgiprefix=""; # nadpisy kodu ve whichcode $codename{"ascii"}="Ascii"; $codename{"1250"}="CP1250"; $codename{"852"}="PC Latin 2"; $codename{"iso"}="ISO Latin 2"; $codename{"iso1"}="ISO Latin 1"; $codename{"kam"}="Kamenicti"; $codename{"koi8-cs"}="KOI8-CS"; $codename{"mac"}="Mac"; @codes=("ascii","1250","mac","iso","iso1","852","kam","koi8-cs"); %abcNames=("ascii","ASCII","1250","CP1250","mac","MAC","iso","ISO-8859-2", "iso1","ISO-8859-1","852","CP852","kam","KEYBCS2","koi8-cs","KOI8-CS"); %altCodes=%abcNames; } else { die '$names'." v 'make' se musi rovnat bud \"WWWdia\" nebo \"EUnet\"\n"; }
Volba je urcena predevsim pro operacni systemy jine nez Unix, ve kterem by funkce stat mela fungovat bez problemu. U odlisnych systemu je treba vec vyzkouset.
Tim je ukoncena konfiguracni faze. Jako dalsi krok spustte
./makeJeho vysledkem by mela byt skupina souboru (toXXX[.cgi] nebo yyy[.cgi] a soubor whichcode[.cgi]. Tyto soubory presunte do adresare s CGI skripty tak, aby jejich umisteni vyhovovalo identifikaci, uvedene ve vyse zminovanych promennych $cgipath a $homedir - napriklad
mv *.cgi ~/www/cgi-bin/Doporucuji navic pro skript whichcode zavest synonyma to__CHARSET__ (__CHARSET__) a to, protoze SaCzech-Uj neprovadi zadnou substituci za __CHARSET__. Dotycna synonyma zajisti prikazy
cd ~/www/cgi-binpripadne
ln -s whichcode to__CHARSET__
ln -s whichcode to
ln -s whichcode.cgi __CHARSET__.cgiTim je instalace ukoncena.
ln -s whichcode.cgi to.cgi
a podobne.