Changeset 23949

Show
Ignore:
Timestamp:
23.04.2011 18:04:57 (9 years ago)
Author:
davidb
Message:

In hand-crafted Greenstones configured with multi-OS binaries there needs to be separate folders for OS in cgi-bin. In the near future, the SVN configuration to Greenstone will also be changed to use this out-of-the-box. This change makes it easier to switch between the two structures.

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • main/trunk/greenstone2/gsicontrol.bat

    r23945 r23949  
    33setlocal 
    44::set testdone=0 
     5 
     6set cgibin=cgi-bin 
     7::set cgibin=cgi-bin\windows 
     8 
    59set target=%1 
    610set configfile=%2 
     
    4549echo    configure-cgi 
    4650echo    reset-gsdlhome [config-filename] 
    47 echo        (Save a copy of cgi-bin/gsdlsite.cfg to preserve any customisations) 
     51echo        (Save a copy of %cgibin%\gsdlsite.cfg to preserve any customisations) 
    4852echo    set-port 
    4953echo    test-gsdlhome 
     
    167171:resethome 
    168172echo. 
    169 if exist "%GSDLHOME%\cgi-bin\gsdlsite.cfg" ( 
    170     echo **** WARNING. Local changes made to %GSDLHOME%\cgi-bin\gsdlsite.cfg will be lost. 
    171     del "%GSDLHOME%\cgi-bin\gsdlsite.cfg" 
     173if exist "%GSDLHOME%\%cgibin%\gsdlsite.cfg" ( 
     174    echo **** WARNING. Local changes made to %GSDLHOME%\%cgibin%\gsdlsite.cfg will be lost. 
     175    del "%GSDLHOME%\%cgibin%\gsdlsite.cfg" 
    172176) 
    173177goto cfgweb 
     
    177181:cfgweb 
    178182:cfgcgi 
    179 if exist "%GSDLHOME%\cgi-bin\gsdlsite.cfg" goto cgimsg 
    180 echo Configuring cgi-bin\gsdlsite.cfg 
     183if exist "%GSDLHOME%\%cgibin%\gsdlsite.cfg" goto cgimsg 
     184echo Configuring %cgibin%\gsdlsite.cfg 
    181185for /F "delims=*" %%T in ('"echo %GSDLHOME%| bin\windows\sed.exe s@\\@\\\\@g"') do set safepath=%%T 
    182 bin\windows\sed.exe "s@\*\*GSDLHOME\*\*@\"%safepath%\"@g" cgi-bin/gsdlsite.cfg.in > cgi-bin/gsdlsite.cfg     
     186bin\windows\sed.exe "s@\*\*GSDLHOME\*\*@\"%safepath%\"@g" %cgibin%\gsdlsite.cfg.in > %cgibin%\gsdlsite.cfg   
    183187set safepath= 
    184188goto cgifin 
     
    187191echo WARNING: Nothing done for configure-cgi. 
    188192echo    If you wish to regenerate the file 
    189 echo    %GSDLHOME%\cgi-bin\gsdlsite.cfg 
     193echo    %GSDLHOME%\%cgibin%\gsdlsite.cfg 
    190194echo    from scratch, delete the existing file first. 
    191195echo. 
     
    247251for /F "delims=*" %%T in ('"echo %GSDLHOME%| bin\windows\sed.exe s@\\@\/@g"') do set safepath=%%T 
    248252 
    249 if exist "%GSDLHOME%\cgi-bin\gsdlsite.cfg" FOR /F "tokens=2" %%G IN ('findstr /R ^collecthome "%GSDLHOME%\cgi-bin\gsdlsite.cfg"') do set COLLECTHOME=%%G 
     253if exist "%GSDLHOME%\%cgibin%\gsdlsite.cfg" FOR /F "tokens=2" %%G IN ('findstr /R ^collecthome "%GSDLHOME%\%cgibin%\gsdlsite.cfg"') do set COLLECTHOME=%%G 
    250254if "%COLLECTHOME%" == "" set COLLECTHOME=%GSDLHOME%\collect 
    251255for /F "delims=*" %%T in ('"echo %COLLECTHOME%| bin\windows\sed.exe s@\\@\/@g"') do set safecollectpath=%%T