12

I'm using Windows 8 with Japanese language. I installed the JDK SE8, and the javac compiler messages are all in Japanese.

I tried changing the non-unicode system locale setting to English, restarted, and reinstalled the JDK, as suggested in similar questions, but now javac just displays a bunch of question marks in the command prompt. How can I change the output to English?

Agargara
  • 902
  • 11
  • 24

1 Answers1

14

Try passing this argument: -J-Duser.language=en. See this post: Passing "-J-Duser.language" into javac through ant to ensure compilation errors are reported in the correct language

Community
  • 1
  • 1
ajbee
  • 3,511
  • 3
  • 29
  • 56
  • 1
    Thank you, although it would be nice to have a permanent solution, that works great as a workaround! – Agargara May 20 '14 at 05:19
  • 6
    To set it permanently for all users: REG ADD "HKLM\SYSTEM\CurrentControlSet\Control\Session Manager\Environment" /v JAVA_TOOL_OPTIONS /d -Duser.language=en /t REG_SZ /f – ajbee May 20 '14 at 05:25
  • 5
    If anyone wants to set manually and permanently on Windows, try setting an environment variable `JAVA_TOOL_OPTIONS` whose value is `-Duser.language=en`. (To do so, `Win + R` to run `sysdm.cpl`, then `advanced`, then `environment variables`.) It works on my side. On command line,`javac` displays `Picked up JAVA_TOOL_OPTIONS: -Duser.language=en` every time it runs. – aafulei Dec 28 '18 at 06:56