MantisBT - CMake
View Issue Details
0012074CMakeCMakepublic2011-04-13 02:482015-06-01 08:38
zouguangxian 
Clinton Stimpson 
highmajoralways
closedfixed 
Windows
 
CMake 3.2 
0012074: "Could not copy from" On Windows 7 (Simplified Chinese)
When run cmake on Windows 7 (Simplified Chinese), cmake always report "Could not copy from" if the current user name include chinese characteres.

This problem will be fixed via add "std::locale::global(std::locale(""));", for example, in cmake.cxx, change the main function to

int main(int ac, char** av)
{
  std::locale::global(std::locale(""));
  cmSystemTools::EnableMSVCDebugHook();
  ....
}
No tags attached.
related to 0010180closed Clinton Stimpson CMake won't generate Visual Studio projects with working paths that have Unicode charactors 
related to 0012075closed Clinton Stimpson generated .vcproj with wrong encoding 
Issue History
2011-04-13 02:48zouguangxianNew Issue
2012-02-23 21:27zouguangxianNote Added: 0028706
2012-02-24 08:29Brad KingRelationship addedrelated to 0010180
2012-02-24 08:30Brad KingRelationship addedrelated to 0012075
2012-02-24 08:40Brad KingNote Added: 0028710
2012-02-24 08:40Brad KingStatusnew => backlog
2012-03-07 02:43zouguangxianNote Added: 0028852
2012-03-07 02:46zouguangxianNote Added: 0028853
2015-01-15 23:41Clinton StimpsonAssigned To => Clinton Stimpson
2015-01-15 23:41Clinton StimpsonStatusbacklog => assigned
2015-01-16 10:12Clinton StimpsonNote Added: 0037716
2015-01-16 10:12Clinton StimpsonStatusassigned => resolved
2015-01-16 10:12Clinton StimpsonFixed in Version => CMake 3.2
2015-01-16 10:12Clinton StimpsonResolutionopen => fixed
2015-06-01 08:38Robert MaynardNote Added: 0038842
2015-06-01 08:38Robert MaynardStatusresolved => closed

Notes
(0028706)
zouguangxian   
2012-02-23 21:27   
It is duplication of 0010180.
(0028710)
Brad King   
2012-02-24 08:40   
The proposed fix will set the locale for all streams including those that are used to read and copy the content of files. However CMake currently does not define or understand character encoding for its input files and is not able to handle files containing anything except 7-bit ASCII characters. (CTest knows how to handle UTF-8 encoded test output, but that is separate.)

I'm not prepared to make this change without a full patch for internationalization along with tests and documentation. It will probably have to be discussed on the developer's list:

  http://www.cmake.org/mailman/listinfo/cmake-developers [^]

(0028852)
zouguangxian   
2012-03-07 02:43   
There is a article title with "
Using UTF-8 as the internal representation for strings in C and C++ with Visual Studio"

http://www.nubaria.com/en/blog/?p=289 [^]
(0028853)
zouguangxian   
2012-03-07 02:46   
Please refer to http://www.joelonsoftware.com/articles/Unicode.html [^] also
"The Absolute Minimum Every Software Developer Absolutely, Positively Must Know About Unicode and Character Sets (No Excuses!)
by Joel Spolsky"
(0037716)
Clinton Stimpson   
2015-01-16 10:12   
Fixed by switching to utf-8 internally.
http://www.cmake.org/gitweb?p=cmake.git;a=commit;h=cdc29c3 [^]
(0038842)
Robert Maynard   
2015-06-01 08:38   
Closing resolved issues that have not been updated in more than 4 months.