RFR: 8263028: Windows build fails due to several treat-warning-as-errors

Yi Yang yyang at openjdk.java.net
Fri Apr 2 07:38:32 UTC 2021


On Mon, 29 Mar 2021 14:42:00 GMT, Yi Yang <yyang at openjdk.org> wrote:

>> I searched the net once more for setting the locale, and this time I found some creative workarounds on superuser. The suggestion is to create a *secondary* user account, and set US English as locale for that account. Then you can go back to your main account, and us the "Run as..." functionality to execute an arbitrary command as that user. 
>> 
>> This could be done by: `%comspec% runas /profile /user:yourotheruser "the_application_you_want_ to_run_in_english"` or using the GUI (shift+right click on the icon, select `Run as different user`).
>> 
>> I assume you would be able to start a cygwin shell like this, and have all processes started in that shell belonging to this US English user.
>> 
>> @kelthuzadx Can you please verify if this method works? If so, I believe it is convenient enough for us to be able to require US English locale for building on Windows.
>
> Hi Magnus,
> 
>> I searched the net once more for setting the locale, and this time I found some creative workarounds on superuser. The suggestion is to create a secondary user account, and set US English as locale for that account. Then you can go back to your main account, and us the "Run as..." functionality to execute an arbitrary command as that user.
> 
>> This could be done by: %comspec% runas /profile /user:yourotheruser "the_application_you_want_ to_run_in_english" or using the GUI (shift+right click on the icon, select Run as different user).
> 
> Thanks for your investigations and kind suggestions. It is more troublesome to add new a user to the Chinese system and set its system locale to English. Instead of doing this, I prefer to directly change the system locale to English. 
> 
> When I set the system locale to English(`Control Panel->Change date, time,...->Administrative->Change System locale->English`), and it indeed works for building! No warnings were generated. All works fine.
> 
>> a) it does not occur in what is at least the "recommended" locale, and
> 
>> b) more issues are likely to creep up in the future (in fact, there might already be testing issues as Jorn says)
> 
>> On the other hand, I am not really comfortable either with just stating in the build document that US English is the only supported Windows locale, since it has such far-reaching consequences for the individual developers.
> 
> You convinced me, I agree with you that stating these has far-reaching consequences and your internal test matrix will become incredibly heavy. However, I think we can add a section in the FAQ or other places in the building document to give a solution for such problems as much as possible, e.g.
> 
> Q: Why I can not build JDK on a non-English system? What should I do next?
> A: Maybe you can change your system locale to English and try again
> 
> Just IMHO, :-)
> 
> Best Regards,
> Yang

In order to avoid disturbing others, I will comment on the https://bugs.openjdk.java.net/browse/JDK-8264425

-------------

PR: https://git.openjdk.java.net/jdk/pull/3107


More information about the hotspot-runtime-dev mailing list