all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: Eli Zaretskii <eliz@gnu.org>
To: Klaus-Dieter Bauer <bauer.klaus.dieter@gmail.com>
Cc: emacs-devel@gnu.org
Subject: Re: Passing unicode filenames to start-process on Windows?
Date: Thu, 07 Jan 2016 18:00:11 +0200	[thread overview]
Message-ID: <83h9ip2xdg.fsf@gnu.org> (raw)
In-Reply-To: <CANtbJLFCsVkaiJXwpVS+FYJFk6bRggSCWqbdTEsegHvz7h8Qgg@mail.gmail.com> (message from Klaus-Dieter Bauer on Wed, 6 Jan 2016 22:19:39 +0100)

> From: Klaus-Dieter Bauer <bauer.klaus.dieter@gmail.com>
> Date: Wed, 6 Jan 2016 22:19:39 +0100
> Cc: emacs-devel@gnu.org
> 
> I thought up some workarounds, but they all run into limitations:
> 
> * w32-short-file-name: Doesn't work, because in modern Windows systems 8.3 file
>   names may not be generated, so it may just return the unchanged filename.
> * rename-file: Allows working with a name via a temporary supported file name.
>   Sadly there is no way to guarantee that such renaming is undone afterwards.
> * copy-file (to a temporary directory): Would work for the current application,
>   but unviable when larger amounts of data are involved. 
> 
> Would you happen to know any other possible workaround?

The only one that would work reliably is to pass arguments via a file
or a pipe.  (Some program support "response files" as a replacement
for command-line arguments, or can read the arguments from stdin.)

Do you really have programs that can support text outside of the
current system codepage?  If you don't, then passing arguments with
such strings is the least of your problems: once you do get these
strings into the program, the program won't be able to do anything
useful with them: all the library functions that receive C strings
will misbehave, you won't be able to open files with such names, etc.

IOW, I'm not sure I understand your use case in enough detail to
provide useful advice.  Perhaps describe what you want to do and the
program you want to invoke from Emacs in more detail.



  parent reply	other threads:[~2016-01-07 16:00 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-06 15:20 Passing unicode filenames to start-process on Windows? Klaus-Dieter Bauer
2016-01-06 16:13 ` Eli Zaretskii
2016-01-06 21:19   ` Klaus-Dieter Bauer
2016-01-06 23:05     ` Davis Herring
2016-01-07  3:36       ` Eli Zaretskii
2016-01-07 16:00     ` Eli Zaretskii [this message]
2016-01-07 23:31       ` Klaus-Dieter Bauer
2016-01-08  9:17         ` Eli Zaretskii
2016-01-08 20:01           ` Klaus-Dieter Bauer

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=83h9ip2xdg.fsf@gnu.org \
    --to=eliz@gnu.org \
    --cc=bauer.klaus.dieter@gmail.com \
    --cc=emacs-devel@gnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.