Changeset 20479 for gli

Show
Ignore:
Timestamp:
02.09.2009 13:19:52 (10 years ago)
Author:
ak19
Message:

Changes to deal with a local APACHE web server: gli.bat assumes WebLib? mode only when it can't find either server.exe or gs2-server.bat. Also, it launches GLI with the path to the server.exe file if this exists or else with gs2-server.bat if in Local Library mode (else it defaults to Web Library mode).

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • gli/trunk/gli.bat

    r19390 r20479  
    129129:: if FLI is running, we don't want the local Greenstone library server running 
    130130if "%PROGABBR%" == "FLI" goto webLib 
    131     :: Else we're running GLI, so we want the local Greenstone library server (if server.exe exists, otherwise it will be webLib) 
    132     if exist "%GSDLHOME%\server.exe" goto localLib  
     131    :: Else we're running GLI, so we want the local Greenstone library server (if server.exe/gs2-server.bat exists, otherwise it will be webLib) 
     132    if not exist "%GSDLHOME%\server.exe" if not exist "%GSDLHOME%\gs2-server.bat" goto webLib  
     133 
     134:localLib 
     135    if exist "%GSDLHOME%\server.exe" ( 
     136    set locallib=%GSDLHOME%\server.exe 
     137    ) else ( 
     138    set locallib=%GSDLHOME%\gs2-server.bat 
     139    ) 
     140 
     141    "%JAVA_EXECUTABLE%" -Xmx128M -cp classes/;GLI.jar;lib/apache.jar;lib/qfslib.jar org.greenstone.gatherer.GathererProg -gsdl "%GSDLHOME%" -gsdlos %GSDLOS% -perl "%PERLPATH%" -local_library "%locallib%" %1 %2 %3 %4 %5 %6 %7 %8 %9 
     142    if ERRORLEVEL 2 ( 
     143        goto localLib 
     144    ) 
     145    goto finRun 
    133146 
    134147:webLib 
     
    137150        goto webLib 
    138151    ) 
    139     goto finRun  
    140  
    141 :localLib 
    142     "%JAVA_EXECUTABLE%" -Xmx128M -cp classes/;GLI.jar;lib/apache.jar;lib/qfslib.jar org.greenstone.gatherer.GathererProg -gsdl "%GSDLHOME%" -gsdlos %GSDLOS% -perl "%PERLPATH%" -local_library "%GSDLHOME%\server.exe" %1 %2 %3 %4 %5 %6 %7 %8 %9 
    143     if ERRORLEVEL 2 ( 
    144         goto localLib 
    145     ) 
    146152    goto finRun 
    147  
    148153 
    149154:finRun