On upgrading to sbt 0.13.8:
[debug] Attempting to call com.sun.tools.javac.api.JavacTool@572e024c directly...
java.lang.IllegalArgumentException: invalid flag: -J-Xmx512m
at com.sun.tools.javac.api.JavacTool.processOptions(JavacTool.java:206)
We need to increase the memory for javac, so if it does fork, we need it to use that setting, but if it doesn't fork, then it fails. Some possibilities:
- Automatically exclude
-J options, possibly warning if present
- Make it possible to check whether javac will be forked or not
- Provide a separate set of options that only get used when javac is forked