Changeset 15363

Show
Ignore:
Timestamp:
08.05.2008 10:07:31 (11 years ago)
Author:
oranfry
Message:

gs3-setup.bat now sets the CLASSPATH to points to single jar files with a Class-Path manifest field set, rather than listing jars individually. Also, gs3-setup.bat now checks if the PATH has already been modified before modifying it. Also, commented gs3-setup.bat.

Location:
greenstone3/trunk
Files:
2 added
1 modified

Legend:

Unmodified
Added
Removed
  • greenstone3/trunk/gs3-setup.bat

    r15355 r15363  
    88 
    99:start 
    10 :: ---- Set the GSDL3HOME variable to the current directory ---- 
     10:: ---- Set some relevant environment variables ---- 
     11 
     12:: this is the default 
     13:: greenstone3 (%GSDL3SRCHOME%) 
     14:: +-- web (%GSDLHOME%) 
     15:: +-- packages 
     16::      +-- tomcat (%TOMCAT_HOME%) 
     17::      +-- ant (%ANT_HOME%) 
     18 
     19:: set GSDLSRCHOME to the current directory 
    1120cd | winutil\setvar.exe GSDL3SRCHOME > %TMP%\setgsdl3.bat 
    1221call %TMP%\setgsdl3.bat 
    1322del %TMP%\setgsdl3.bat 
     23 
     24:: set GSDLHOME to the 'web' subdirectory 
    1425set GSDL3HOME=%GSDL3SRCHOME%\web 
    1526 
    16 :: change if using external tomcat 
     27:: change if using external tomcat or ant 
    1728set TOMCAT_HOME=%GSDL3SRCHOME%\packages\tomcat 
     29set ANT_HOME=%GSDL3SRCHOME%\packages\ant 
    1830 
    19 :: ---- Set other important environment variables ---- 
     31:: other important environment variables 
    2032set GSDLOS=windows 
    21 set ANT_HOME=%GSDL3SRCHOME%\packages\ant 
     33 
     34:: ---- Set the CLASSPATH and PATH environment variables ---- 
     35if "%GS_CP_SET%" == "yes" goto skipSetCp 
     36set CLASSPATH=%CLASSPATH%;.;%GSDL3HOME%\WEB-INF\classes;%GSDL3SRCHOME%\resources\java;%GSDL3SRCHOME%\server.jar;%GSDL3HOME%\WEB-INF\lib\cp.jar;%GSDL3SRCHOME%\lib\jni\cp.jar;%GSDL3SRCHOME%\build\cp.jar 
    2237set PATH=%PATH%;%GSDL3SRCHOME%\bin;%GSDL3SRCHOME%\bin\script;%GSDL3SRCHOME%\lib\jni;%ANT_HOME%\bin 
    2338 
    24 :: ---- Set the CLASSPATH environment variable ---- 
    25 if "%GS_CP_SET%" == "yes" goto skipSetCp 
    26 set CLASSPATH=.;%GSDL3HOME%\WEB-INF\classes;%GSDL3SRCHOME%\resources\java;%CLASSPATH% 
     39:: a little dynamic set cp stuff 
    2740if exist %TMP%\setcp.bat del %TMP%\setcp.bat 
    28 for %%j in ("%GSDL3SRCHOME%"\*.jar) do echo set CLASSPATH=%%CLASSPATH%%;%%j>> %TMP%\setcp.bat 
    29 for %%j in ("%GSDL3HOME%"\WEB-INF\lib\*.jar) do echo set CLASSPATH=%%CLASSPATH%%;%%j>> %TMP%\setcp.bat 
    30 for %%j in ("%GSDL3SRCHOME%"\lib\jni\*.jar) do echo set CLASSPATH=%%CLASSPATH%%;%%j>> %TMP%\setcp.bat 
    3141for %%j in ("%TOMCAT_HOME%"\common\endorsed\*.jar) do echo set CLASSPATH=%%CLASSPATH%%;%%j>> %TMP%\setcp.bat 
    32 for %%j in ("%GSDL3SRCHOME%"\build\*.jar) do echo set CLASSPATH=%%CLASSPATH%%;%%j>> %TMP%\setcp.bat 
    33 echo set GS_CP_SET=yes >> %TMP%\setcp.bat 
    34 call %TMP%\setcp.bat 
    35 del %TMP%\setcp.bat 
     42if exist %TMP%\setcp.bat call %TMP%\setcp.bat 
     43if exist %TMP%\setcp.bat del %TMP%\setcp.bat 
     44 
     45set GS_CP_SET=yes 
    3646:skipSetCp 
    3747 
     48:: ---- Search for java ---- 
    3849winutil\search4j.exe -m %java_min_version% | winutil\setvar.exe _JRE_HOME > %TMP%\set_jre_home.bat 
    3950call %TMP%\set_jre_home.bat