[
https://issues.apache.org/jira/browse/OPENNLP-361?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13146880#comment-13146880
]
Aliaksandr Autayeu commented on OPENNLP-361:
--------------------------------------------
Please, see 0007-handling-spaces-in-JAVA_HOME-quote-on-use-for-succes.patch.
There is another possible inconvenience in the script: the use of -Xmx4096m. On
PCs with smaller amounts of memory this will prevent the java from allocating
the heap. I usually use another variable as a workaround. Something like this:
REM Use OPENNLP-JVMOPTIONS to add your options to JVM (such as memory)
if "%OPENNLP-JVMOPTIONS%" EQU "" (
java -Xmx512M -jar %OPENNLP_HOME%\lib\opennlp-tools-*.jar %*
) else (
java %OPENNLP-JVMOPTIONS% -jar %OPENNLP_HOME%\lib\opennlp-tools-*.jar %*
)
Here in the first branch default options are set by default, and in the else
supplied options are used instead. This might be useful also for setting other
options, like -Dlog4j.configuration.
> handling spaces in JAVA_HOME
> ----------------------------
>
> Key: OPENNLP-361
> URL: https://issues.apache.org/jira/browse/OPENNLP-361
> Project: OpenNLP
> Issue Type: Bug
> Components: Command Line Interface
> Affects Versions: tools-1.5.3-incubating
> Environment: Windows 7
> Reporter: Aliaksandr Autayeu
> Assignee: James Kosin
> Labels: patch
> Fix For: tools-1.5.3-incubating
>
> Attachments: 0001-handling-spaces-in-JAVA_HOME.patch,
> 0007-handling-spaces-in-JAVA_HOME-quote-on-use-for-succes.patch
>
> Original Estimate: 5m
> Remaining Estimate: 5m
>
> If JAVA_HOME contains spaces, opennlp.bat fails to execute java.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira