This is the mail archive of the cygwin mailing list for the Cygwin project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Cygwin programs doesn't support non-ASCII filenames

On 2009-5-9 23:44, Corinna Vinschen wrote:
On May 9 23:12, Lenik wrote:
(This mail is encoded in utf-8)

On 2009-5-9 18:02, Corinna Vinschen wrote:
[Repeated and additional question.  I accidentally sent this as PM.
   Sorry about that.  Let's keep this on the list, please]

On May 9 11:43, Lenik wrote:
(My system locale is zh_CN)
What ANSI codepage is that?

And what OEM codepage uses the console Window by default?
`chcp' shows codepage is 937

937?!? Per MSDN there's no 937 codepage, rather a 936 codepage
Sorry, it's 936.

Ok, but that's not Cygwin's problem, just the d tool would need an
update at one point, perhaps.  OTOH, what you're doing is a bit
borderline.  When you start this stuff from cmd, you will have to enter
the filename in the notation valid for the locale in which the
application works.  For d, which only works in the C locale, you would
have to give the pathname using the SO/UTF-8 sequences.  Right now I
have no idea if there's a workaround for that, but keep in mind that
we're at the beginning of real native language support.  Unfortunately
it's all a bit more complicated than on non-Windows systems, given the
UTF-16-ness of the underlying system.

d is an example, there's more. so I guess it should be resolved in cygwin maybe better...

Though I maybe able to use UTF-8 sequences to invoke d tool, but I can't do anything about cwd, for example:
bash-3.2$ pwd

	bash-3.2$ ls
	Gears Shortcut Sample.lnk  hello      setup.xj  worker.js
	e-3.4.lnk                  reply.txt  sms.xls

	bash-3.2$ d
	---------  :  0  Jan 01  1970  æé

The default lcoale is "C", as demanded by POSIX.  Everything else is
in responsibility of the application.  Please read
But set LANG=C will get a different result,

	C:\Profiles\Shecti> set LANG=& bash -c "cat äå"
	cat: äå: No such file or directory

	C:\Profiles\Shecti> set LANG=C& bash -c "cat äå"

So I guess the default locale isn't C.


-- Unsubscribe info: Problem reports: Documentation: FAQ:

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]