public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Jon Turney <jon.turney@dronecode.org.uk>
To: The Cygwin Mailing List <cygwin@cygwin.com>
Subject: Re: Forcing setup.exe not to create WSL symlinks
Date: Sun, 6 Sep 2020 15:44:02 +0100	[thread overview]
Message-ID: <cbeb8d61-e725-dabf-7883-352649adeb28@dronecode.org.uk> (raw)
In-Reply-To: <CAALQ5rn5=oqGOge7mTFGoDeJCxD6H4=cFN3Mww+My4DMxNPsEQ@mail.gmail.com>

On 27/08/2020 13:48, Michael Wild via Cygwin wrote:
> Hmm, OK, changing script.cc to not strip out CYGWIN is trivial. But the
> harder part is that main.cc uses ShellExecuteEx() with
> SHELLEXECUTEINFO.verb set to "runas" in order to re-run setup elevated.
> This resets all environment variables back to default. In my instance I can
> circumvent this by passing --no-admin and running from an elevated shell
> where CYGWIN is set already. And indeed, this works and resolves my Docker
> problem. I attached this fix as a patch. But on the other hand, I find this
> behavior to be a bit confusing. However, I don't see an easy way of
> resolving the "runas" issue, because it is by design. An option would be
> that the calling process passes the CYGWIN variable as a command line
> argument to the elevated process. But that is also ugly. What do you guys
> think?

I think an option which explicitly specifies the symlink style would be 
best (rather than option to specify the CYGWIN env var).

You'd also need to teach setup to create syminks in these different 
ways, and set the CYGWIN env var for scripts appropriately.

  parent reply	other threads:[~2020-09-06 14:44 UTC|newest]

Thread overview: 17+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-08-26 12:14 Michael Wild
2020-08-26 15:19 ` Andrey Repin
2020-08-26 15:24   ` Michael Wild
2020-08-26 18:29 ` Achim Gratz
2020-08-26 19:06   ` Michael Wild
2020-08-26 20:15     ` Michael Wild
2020-08-26 20:55   ` Jon Turney
2020-08-27  5:48     ` Michael Wild
2020-08-27  9:00       ` Corinna Vinschen
2020-08-27  9:38         ` Andrey Repin
2020-08-27  9:44         ` Michael Wild
2020-08-27 12:48           ` Michael Wild
2020-08-27 12:49             ` Michael Wild
2020-08-30 20:24               ` Jon Turney
2020-09-06 14:44             ` Jon Turney [this message]
2020-08-30 20:24       ` Jon Turney
2020-08-31  4:51         ` Michael Wild

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=cbeb8d61-e725-dabf-7883-352649adeb28@dronecode.org.uk \
    --to=jon.turney@dronecode.org.uk \
    --cc=cygwin@cygwin.com \
    /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.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).