Changeset 31461 for main/trunk
- Timestamp:
- 2017-03-06T17:08:44+13:00 (7 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/trunk/greenstone3/gs3-setup.bat
r31460 r31461 196 196 if !ERRORLEVEL! equ 1 echo *** The detected system JDK java is an incompatible bit architecture& goto testjre 197 197 if !ERRORLEVEL! equ 0 ( 198 echo *** The detected system JDK java is a matching %bitness% bit 199 echo *** Using the system JAVA_HOME detected 200 set JAVA_HOME=!FOUNDJAVAHOME! 201 set PATH=!FOUNDJAVAHOME!\bin;!PATH! 202 set RUNJAVA=!FOUNDJAVAHOME!\bin\java.exe 203 goto summaryThenEnd 198 echo *** The detected system JDK java is a matching %bitness% bit 199 goto setupjavahome 204 200 ) 205 201 ) … … 213 209 rem The JRE_HOME found by search4j may be the bundled JRE, overriding any system JRE_HOME, 214 210 rem because the bundled JRE_HOME was provided as HINT to search4j. 215 echo *** The detected JRE java is a matching %bitness% bit 216 echo *** Using the JRE_HOME detected 217 set JRE_HOME=!FOUNDJREHOME! 218 set PATH=!FOUNDJREHOME!\bin;!PATH! 219 set RUNJAVA=!FOUNDJREHOME!\bin\java.exe 220 goto summaryThenEnd 211 echo *** The detected JRE java is a matching %bitness% bit 212 goto setupjrehome 221 213 ) 222 214 ) … … 228 220 if exist "!HINT!\bin\java.exe" ( 229 221 echo *** Changing to use the GS bundled 32-bit jre. 230 set J AVA_HOME=!HINT!222 set JRE_HOME=!HINT! 231 223 set PATH=!JAVA_HOME!\bin;!PATH! 232 224 set RUNJAVA=!JAVA_HOME!\bin\java.exe … … 234 226 ) 235 227 236 :: 4. Last ditch effort: search4j couldn't find any java, but check any Java env vars set anyway 228 :: 4. If no bundled JRE exists either, we'd still need to check if search4j found a JAVA_HOME or JRE_HOME 229 :: and use that even if there was a bitness mismatch btw GS3 and the Java found. 230 :: Label summaryThenEnd will print out warnings on any mismatch 231 :setupjavahome 232 if DEFINED FOUNDJAVAHOME ( 233 echo *** Using the system JAVA_HOME detected at !FOUNDJAVAHOME! 234 set JAVA_HOME=!FOUNDJAVAHOME! 235 set PATH=!FOUNDJAVAHOME!\bin;!PATH! 236 set RUNJAVA=!FOUNDJAVAHOME!\bin\java.exe 237 goto summaryThenEnd 238 ) 239 240 :setupjrehome 241 if DEFINED FOUNDJREHOME ( 242 echo *** Using the JRE_HOME detected at !FOUNDJREHOME! 243 set JRE_HOME=!FOUNDJREHOME! 244 set PATH=!FOUNDJREHOME!\bin;!PATH! 245 set RUNJAVA=!FOUNDJREHOME!\bin\java.exe 246 goto summaryThenEnd 247 ) 248 249 :: 5. Last ditch effort: search4j couldn't find any java, but check any Java env vars set anyway 237 250 echo *** Search4j could not find an appropriate JAVA or JRE. 238 251 echo *** Attempting to use any JAVA_HOME else JRE_HOME in the environment... … … 265 278 266 279 :summaryThenEnd 267 :: Check that the bitness of any Java found is appropriate and warn if it is not.280 :: 6. Check that the bitness of any Java found is appropriate and warn if it is not. 268 281 "!RUNJAVA!" -d%bitness% -version 2> nul 269 282 if !ERRORLEVEL! equ 1 ( 270 echo *** WARNING: Detected mismatch between the bit-ness of your Greenstone installation ^(%bitness% bit^) and the Java found. 283 echo *** WARNING: Detected mismatch between the bit-ness of your Greenstone installation ^(%bitness% bit^) 284 echo *** and the Java found at %RUNJAVA%. 271 285 echo *** Continuing with this Java anyway: 272 286 echo *** This will only affect MG/MGPP collections for searching, and GDBM database collections
Note:
See TracChangeset
for help on using the changeset viewer.