All users were logged out of Bugzilla on October 13th, 2018

I can't build on VisualStudio 2015 on Japanese locale after landing bug 1260626.

RESOLVED FIXED

Status

()

RESOLVED FIXED
2 years ago
2 years ago

People

(Reporter: mantaroh, Unassigned)

Tracking

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

2 years ago
+++ This bug was initially created as a clone of Bug #1260626 +++

I faced the build failure due to file encoding.
The change of bug 1260626 contained the multi-byte code.[1] 
In Japanese environment, The VisualStudio will identify as CP932.

[1] https://hg.mozilla.org/mozilla-central/rev/851d4bd145a4#l1.74
(Reporter)

Updated

2 years ago
Flags: needinfo?(cykesiopka.bmo)
(Reporter)

Updated

2 years ago
Summary: I can't build on VisualStudio 2015 on Japanese locale. → I can't build on VisualStudio 2015 on Japanese locale after landing bug 1260626.
The patch in bug1260626 results in build failure under Traditional Chinese environment, too

We can workaround it by deleting the multibyte char here.
https://dxr.mozilla.org/mozilla-central/rev/3b80868f7a8fe0361918a814fbbbfb9308ae0c0a/security/manager/ssl/tests/unit/pkcs11testmodule/pkcs11testmodule.cpp#104

It seems that this patch affects language environment with multibyte char.
Bug 1313280 will fix this.
Depends on: 1313280
Or we can fix this by using UTF-8 string literals:
> static const char TestSlot2Description[] = u8"Test PKCS11 Slot 二";
(In reply to Masatoshi Kimura [:emk] from comment #3)
> Or we can fix this by using UTF-8 string literals:
> > static const char TestSlot2Description[] = u8"Test PKCS11 Slot 二";

Ah, this will not work because it will not change the execution character set.
s/execution character set/source character set/

Sorry for the bugspam.

Comment 6

2 years ago
Sorry about that.

Anyways, here's my plan:
1. I will attach a patch containing a workaround that should unbreak non-Western environments and keep PSM tests passing as well.
2. I will wait to see if Bug 1313280 gets fixed in a reasonable time, since that is the proper fix, and we do want to keep the multibyte char to test PKCS #11 UTF-8 handling.
3. If Bug 1313280 doesn't progress quickly enough, I'll get the workaround patch reviewed and landed.
No longer blocks: 1311601
Flags: needinfo?(cykesiopka.bmo)

Comment 7

2 years ago
Created attachment 8807626 [details] [diff] [review]
bug1315152_workaround-msvc-source-charset-issue_v1.patch

Workaround patch.
Fixed by bug 1315152.

For the record, a better workaround would be use utf-8 literals *and* universal character name (UCN):
   static const char TestSlot2Description[] = u8"Test PKCS11 Slot \u4E8C";
Status: NEW → RESOLVED
Last Resolved: 2 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.