public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* cannot run setup64.exe without admin privileges (even if renamed foo.exe)
@ 2013-09-12 11:47 Frédéric Bron
  2013-09-12 15:26 ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-12 17:00 ` Yaakov (Cygwin/X)
  0 siblings, 2 replies; 30+ messages in thread
From: Frédéric Bron @ 2013-09-12 11:47 UTC (permalink / raw)
  To: cygwin

I would like to run setup64.exe on Windows 7 without asking for admin
rights but the computer asks me for admin credentials.
I read this: http://cygwin.com/ml/cygwin/2011-06/msg00286.html where
Corinna suggested to rename the .exe to foo.exe but this did not work.
I also do not have the rights to modify the Local Security Policy.

Is there any workaround? Would it be possible to supply a setup that
do not need admin privileges?

Regards,

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 11:47 cannot run setup64.exe without admin privileges (even if renamed foo.exe) Frédéric Bron
@ 2013-09-12 15:26 ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-12 15:31   ` Frédéric Bron
  2013-09-12 17:00 ` Yaakov (Cygwin/X)
  1 sibling, 1 reply; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-12 15:26 UTC (permalink / raw)
  To: cygwin; +Cc: Frédéric Bron

Frédéric Bron sent the following at Thursday, September 12, 2013 5:07 AM
>I would like to run setup64.exe on Windows 7 without asking for admin
>rights but the computer asks me for admin credentials. I read this:
>http://cygwin.com/ml/cygwin/2011-06/msg00286.html where Corinna
>suggested to rename the .exe to foo.exe but this did not work. I also do
>not have the rights to modify the Local Security Policy.
>
>Is there any workaround? Would it be possible to supply a setup that do
>not need admin privileges?

Try *copying* setup64.exe to foo.exe.  Or download it again but save it
with the name foo.exe.

Windows may be remembering that the file used to be called setup*.exe.
That memory might not get copied.

For what it's worth, I think that setup should be renamed to something like
getcygwin just to avoid this issue.

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 15:26 ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-12 15:31   ` Frédéric Bron
  2013-09-12 15:44     ` Ryan Johnson
  0 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-12 15:31 UTC (permalink / raw)
  To: Buchbinder, Barry (NIH/NIAID) [E]; +Cc: cygwin

> Try *copying* setup64.exe to foo.exe.  Or download it again but save it
> with the name foo.exe.
> Windows may be remembering that the file used to be called setup*.exe.
> That memory might not get copied.

Doesn't work: "the requested operation requires elevation".


I am packaging a program with NSIS and I had to explicitly set the
required execution level with:
"RequestExecutionLevel user"
Would it be possible to do something similar for cygwin setup?

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 15:31   ` Frédéric Bron
@ 2013-09-12 15:44     ` Ryan Johnson
  2013-09-12 15:52       ` LRN
                         ` (2 more replies)
  0 siblings, 3 replies; 30+ messages in thread
From: Ryan Johnson @ 2013-09-12 15:44 UTC (permalink / raw)
  To: cygwin

On 12/09/2013 11:26 AM, Frédéric Bron wrote:
>> Try *copying* setup64.exe to foo.exe.  Or download it again but save it
>> with the name foo.exe.
>> Windows may be remembering that the file used to be called setup*.exe.
>> That memory might not get copied.
> Doesn't work: "the requested operation requires elevation".
I have vague memories that someone (Corinna?) suggested copying the file 
to a USB key and back: the FAT filesystem can't track the permissions 
that cause this behavior. Never tested it myself, though (maybe I 
should, it would be nice to lose the UAC prompt).

Ryan


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 15:44     ` Ryan Johnson
  2013-09-12 15:52       ` LRN
@ 2013-09-12 15:52       ` Frédéric Bron
  2013-09-12 16:42       ` Buchbinder, Barry (NIH/NIAID) [E]
  2 siblings, 0 replies; 30+ messages in thread
From: Frédéric Bron @ 2013-09-12 15:52 UTC (permalink / raw)
  To: cygwin

> I have vague memories that someone (Corinna?) suggested copying the file to
> a USB key and back: the FAT filesystem can't track the permissions that
> cause this behavior. Never tested it myself, though (maybe I should, it
> would be nice to lose the UAC prompt).

doesn't work.

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 15:44     ` Ryan Johnson
@ 2013-09-12 15:52       ` LRN
  2013-09-12 15:52       ` Frédéric Bron
  2013-09-12 16:42       ` Buchbinder, Barry (NIH/NIAID) [E]
  2 siblings, 0 replies; 30+ messages in thread
From: LRN @ 2013-09-12 15:52 UTC (permalink / raw)
  To: cygwin

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 12.09.2013 19:31, Ryan Johnson wrote:
> On 12/09/2013 11:26 AM, Frédéric Bron wrote:
>>> Try *copying* setup64.exe to foo.exe.  Or download it again but save it
>>> with the name foo.exe.
>>> Windows may be remembering that the file used to be called setup*.exe.
>>> That memory might not get copied.
>> Doesn't work: "the requested operation requires elevation".
> I have vague memories that someone (Corinna?) suggested copying the file 
> to a USB key and back: the FAT filesystem can't track the permissions 
> that cause this behavior. Never tested it myself, though (maybe I 
> should, it would be nice to lose the UAC prompt).

You can graft manifests into exe files. Such manifest could be written
to tell W32 that the executable does NOT need to be run as Administrator.

I used that in my MSYS2 releases to fix /usr/bin/install,
/usr/bin/patch, /usr/bin/install-info and some git utils.

- -- 
O< ascii ribbon - stop html email! - www.asciiribbon.org
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.11 (MingW32)

iQEcBAEBAgAGBQJSMeFUAAoJEOs4Jb6SI2Cw0twH/1zJIWHvd/CI5P17qk7T611U
GNgwCvMvHAuimfKG1LZsK1d2GqWozWlCi/iNkfXZ1GUMekE7jlY1n+ZgUj1dBg/M
o344spHeTJWd8NqX5kScLz0xoR85CRN5W76eEHaaSy70FuvU8e/CpN/x7fuacRBU
IQWkt0JULRTOX0qWTSjy82Gy+tczCf+mI3TaSd2F36Rc1oXIPVCzEsqD8g3Mja70
DABBWo50hHVyO1+LWMjomoM8dEek3tQqP+hcWjBwlc3kluZr+TkgMAwu3j1PQxPy
WTcsTZANmbAM3sKXJoygHCEz+0CBu5Mmg6HZfyhpCDG4nwZCz3djOU/dPj1tuvU=
=lFIl
-----END PGP SIGNATURE-----

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 15:44     ` Ryan Johnson
  2013-09-12 15:52       ` LRN
  2013-09-12 15:52       ` Frédéric Bron
@ 2013-09-12 16:42       ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-12 17:02         ` Ryan Johnson
  2 siblings, 1 reply; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-12 16:42 UTC (permalink / raw)
  To: cygwin

Ryan Johnson sent the following at Thursday, September 12, 2013 11:31 AM
>>> Try *copying* setup64.exe to foo.exe.  Or download it again but save it
>>> with the name foo.exe.
>>> Windows may be remembering that the file used to be called setup*.exe.
>>> That memory might not get copied.
>> Doesn't work: "the requested operation requires elevation".
>
>On 12/09/2013 11:26 AM, Frédéric Bron wrote: I have vague memories that
>someone (Corinna?) suggested copying the file to a USB key and back: the
>FAT filesystem can't track the permissions that cause this behavior.
>Never tested it myself, though (maybe I should, it would be nice to lose
>the UAC prompt).

Try this.

In a cmd.exe shell:

type setup64.exe > foo.exe

I did a cmp and the two files were identical (using 32 bit setup.exe).

I also tried in bash:

$ cat setup.exe > foo2.exe

Again the files were identical.  However, ls showed permission for foo.exe
(made under cmd) as rwx while foo2.exe made under bash was rw-.  Both open
fine from Windows Explorer.

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 11:47 cannot run setup64.exe without admin privileges (even if renamed foo.exe) Frédéric Bron
  2013-09-12 15:26 ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-12 17:00 ` Yaakov (Cygwin/X)
  2013-09-13  0:09   ` Christopher Faylor
                     ` (2 more replies)
  1 sibling, 3 replies; 30+ messages in thread
From: Yaakov (Cygwin/X) @ 2013-09-12 17:00 UTC (permalink / raw)
  To: cygwin

On 2013-09-12 04:07, Frédéric Bron wrote:
> I would like to run setup64.exe on Windows 7 without asking for admin
> rights but the computer asks me for admin credentials.
> I read this: http://cygwin.com/ml/cygwin/2011-06/msg00286.html where
> Corinna suggested to rename the .exe to foo.exe but this did not work.
> I also do not have the rights to modify the Local Security Policy.

UAC Installer Detection only affects x86 binaries, so that only helps 
with setup-x86.exe. As for setup-x86_64.exe, its builtin manifest 
requires Admin privileges because otherwise it won't promote itself 
automatically, and most people install Cygwin for All Users.

> Is there any workaround? Would it be possible to supply a setup that
> do not need admin privileges?

You can build setup.exe yourself for x86_64-w64-mingw32 with the 
requestedExecutionLevel entry removed from the manifest.  The sources 
are in cygwin-apps CVS.


Yaakov


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 16:42       ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-12 17:02         ` Ryan Johnson
  0 siblings, 0 replies; 30+ messages in thread
From: Ryan Johnson @ 2013-09-12 17:02 UTC (permalink / raw)
  To: cygwin

On 12/09/2013 11:52 AM, Buchbinder, Barry (NIH/NIAID) [E] wrote:
> Ryan Johnson sent the following at Thursday, September 12, 2013 11:31 AM
>>>> Try *copying* setup64.exe to foo.exe.  Or download it again but save it
>>>> with the name foo.exe.
>>>> Windows may be remembering that the file used to be called setup*.exe.
>>>> That memory might not get copied.
>>> Doesn't work: "the requested operation requires elevation".
>> On 12/09/2013 11:26 AM, Frédéric Bron wrote: I have vague memories that
>> someone (Corinna?) suggested copying the file to a USB key and back: the
>> FAT filesystem can't track the permissions that cause this behavior.
>> Never tested it myself, though (maybe I should, it would be nice to lose
>> the UAC prompt).
> Try this.
>
> In a cmd.exe shell:
>
> type setup64.exe > foo.exe
>
> I did a cmp and the two files were identical (using 32 bit setup.exe).
>
> I also tried in bash:
>
> $ cat setup.exe > foo2.exe
>
> Again the files were identical.  However, ls showed permission for foo.exe
> (made under cmd) as rwx while foo2.exe made under bash was rw-.  Both open
> fine from Windows Explorer.
The problem isn't rw-, it's Windows insisting that the executable run 
with admin rights even though it doesn't actually need them.

Ryan


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 17:00 ` Yaakov (Cygwin/X)
@ 2013-09-13  0:09   ` Christopher Faylor
  2013-09-18 15:26   ` Frédéric Bron
  2013-09-18 17:40   ` Frédéric Bron
  2 siblings, 0 replies; 30+ messages in thread
From: Christopher Faylor @ 2013-09-13  0:09 UTC (permalink / raw)
  To: cygwin

On Thu, Sep 12, 2013 at 11:42:28AM -0500, Yaakov (Cygwin/X) wrote:
>On 2013-09-12 04:07, Fr?d?ric Bron wrote:
>> I would like to run setup64.exe on Windows 7 without asking for admin
>> rights but the computer asks me for admin credentials.
>> I read this: http://cygwin.com/ml/cygwin/2011-06/msg00286.html where
>> Corinna suggested to rename the .exe to foo.exe but this did not work.
>> I also do not have the rights to modify the Local Security Policy.
>
>UAC Installer Detection only affects x86 binaries, so that only helps 
>with setup-x86.exe. As for setup-x86_64.exe, its builtin manifest 
>requires Admin privileges because otherwise it won't promote itself 
>automatically, and most people install Cygwin for All Users.
>
>> Is there any workaround? Would it be possible to supply a setup that
>> do not need admin privileges?
>
>You can build setup.exe yourself for x86_64-w64-mingw32 with the 
>requestedExecutionLevel entry removed from the manifest.  The sources 
>are in cygwin-apps CVS.

A definitive, non-speculative answer that even gets the name of the
executable right.  Thanks, Yaakov.

cgf

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 17:00 ` Yaakov (Cygwin/X)
  2013-09-13  0:09   ` Christopher Faylor
@ 2013-09-18 15:26   ` Frédéric Bron
  2013-09-18 15:35     ` Frédéric Bron
  2013-09-18 17:40   ` Frédéric Bron
  2 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-18 15:26 UTC (permalink / raw)
  To: cygwin

> You can build setup.exe yourself for x86_64-w64-mingw32 with the
> requestedExecutionLevel entry removed from the manifest.  The sources are in
> cygwin-apps CVS.

do I need a password to get the sources?
I get this message:
CVS password file /home/xxx/.cvspass does not exist - creating a new
file cvs [checkout aborted]: end of file from server (consult above
messages if any)

But this may be just due to our proxy server.

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 15:26   ` Frédéric Bron
@ 2013-09-18 15:35     ` Frédéric Bron
  2013-09-18 17:20       ` Frédéric Bron
  0 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-18 15:35 UTC (permalink / raw)
  To: cygwin

> do I need a password to get the sources?
> I get this message:
> CVS password file /home/xxx/.cvspass does not exist - creating a new
> file cvs [checkout aborted]: end of file from server (consult above
> messages if any)
>
> But this may be just due to our proxy server.

And without a proxy server:
$ cvs -z3 -d :pserver:anoncvs@sourceware.org:/cvs/cygwin-apps co cygwin-setup
cvs checkout: CVS password file /cygdrive/d/Documents/.cvspass does
not exist - creating a new file
cvs server: cannot find module `cygwin-setup' - ignored
cvs [checkout aborted]: cannot expand modules

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 15:35     ` Frédéric Bron
@ 2013-09-18 17:20       ` Frédéric Bron
  0 siblings, 0 replies; 30+ messages in thread
From: Frédéric Bron @ 2013-09-18 17:20 UTC (permalink / raw)
  To: cygwin

> And without a proxy server:
> $ cvs -z3 -d :pserver:anoncvs@sourceware.org:/cvs/cygwin-apps co cygwin-setup
> cvs checkout: CVS password file /cygdrive/d/Documents/.cvspass does
> not exist - creating a new file
> cvs server: cannot find module `cygwin-setup' - ignored
> cvs [checkout aborted]: cannot expand modules

sorry for the noise, it works fine, I just wanted to change the
destination directory but did it wrongly.

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-12 17:00 ` Yaakov (Cygwin/X)
  2013-09-13  0:09   ` Christopher Faylor
  2013-09-18 15:26   ` Frédéric Bron
@ 2013-09-18 17:40   ` Frédéric Bron
  2013-09-18 17:54     ` Christopher Faylor
  2 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-18 17:40 UTC (permalink / raw)
  To: cygwin

> You can build setup.exe yourself for x86_64-w64-mingw32 with the
> requestedExecutionLevel entry removed from the manifest.  The sources are in
> cygwin-apps CVS.

I got the sources and ran bootstrap.sh
I got setup.exe but not setup64.exe

Is it possible to build setup64.exe from a 32bit cygwin?

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 17:40   ` Frédéric Bron
@ 2013-09-18 17:54     ` Christopher Faylor
  2013-09-18 18:09       ` Frédéric Bron
  0 siblings, 1 reply; 30+ messages in thread
From: Christopher Faylor @ 2013-09-18 17:54 UTC (permalink / raw)
  To: cygwin

On Wed, Sep 18, 2013 at 07:30:35PM +0200, Fr?d?ric Bron wrote:
>> You can build setup.exe yourself for x86_64-w64-mingw32 with the
>> requestedExecutionLevel entry removed from the manifest.  The sources are in
>> cygwin-apps CVS.
>
>I got the sources and ran bootstrap.sh
>I got setup.exe but not setup64.exe
>
>Is it possible to build setup64.exe from a 32bit cygwin?

As previously mentioned, despite the subject, there is no such thing as
setup64.exe.  The makefile creates setup.exe.  The filename gets changed
when it gets uploaded to cygwin.com to either setup-x86.exe or
setup-x86_64.exe.

cgf

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 17:54     ` Christopher Faylor
@ 2013-09-18 18:09       ` Frédéric Bron
  2013-09-18 18:39         ` Charles Wilson
  0 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-18 18:09 UTC (permalink / raw)
  To: cygwin

>>Is it possible to build setup64.exe from a 32bit cygwin?
>
> As previously mentioned, despite the subject, there is no such thing as
> setup64.exe.  The makefile creates setup.exe.  The filename gets changed
> when it gets uploaded to cygwin.com to either setup-x86.exe or
> setup-x86_64.exe.

do you mean I can only build the 32bit version on i686 bits and the
64bit version on x86_64 and in both case the binary is called
setup.exe after running make?
This means I cannot build the x86_64 version from a i686 cygwin. Is
that correct?
Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 18:09       ` Frédéric Bron
@ 2013-09-18 18:39         ` Charles Wilson
  2013-09-19 11:17           ` Frédéric Bron
  0 siblings, 1 reply; 30+ messages in thread
From: Charles Wilson @ 2013-09-18 18:39 UTC (permalink / raw)
  To: The Cygwin Mailing List

On 9/18/2013 1:53 PM, Frédéric Bron wrote:
>>> Is it possible to build setup64.exe from a 32bit cygwin?
>>
>> As previously mentioned, despite the subject, there is no such thing as
>> setup64.exe.  The makefile creates setup.exe.  The filename gets changed
>> when it gets uploaded to cygwin.com to either setup-x86.exe or
>> setup-x86_64.exe.
>
> do you mean I can only build the 32bit version on i686 bits and the
> 64bit version on x86_64 and in both case the binary is called
> setup.exe after running make?
> This means I cannot build the x86_64 version from a i686 cygwin. Is
> that correct?

No. setup.exe (either 32bit or 64bit) is a native windows application, 
and if you're trying to build it within cygwin, then you MUST use a 
cross compiler -- either i686-w64-mingw32 or x86_64-w64-mingw32. when 
configuring the build, just do:

configure --host=i686-w64-mingw32 --build=i686-pc-cygwin ....
to build 32bit setup.exe from 32bit cygwin

configure --host=x86_64-w64-mingw32 --build=x86_64-pc-cygwin ....
to build 64bit setup.exe from 64bit cygwin

...but you can always mix and match the --build and --host settings; 
32setup from 64cygwin, or 64setup from 32cygwin.

--
Chuck



--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-18 18:39         ` Charles Wilson
@ 2013-09-19 11:17           ` Frédéric Bron
  2013-09-25 14:13             ` Frédéric Bron
  0 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-19 11:17 UTC (permalink / raw)
  To: cygwin

> No. setup.exe (either 32bit or 64bit) is a native windows application, and
> if you're trying to build it within cygwin, then you MUST use a cross
> compiler -- either i686-w64-mingw32 or x86_64-w64-mingw32. when configuring
> the build, just do:
>
> configure --host=i686-w64-mingw32 --build=i686-pc-cygwin ....
> to build 32bit setup.exe from 32bit cygwin
>
> configure --host=x86_64-w64-mingw32 --build=x86_64-pc-cygwin ....
> to build 64bit setup.exe from 64bit cygwin
>
> ...but you can always mix and match the --build and --host settings; 32setup
> from 64cygwin, or 64setup from 32cygwin.

It works very nicely. I have managed to build setup.exe for x86_64
from my old cygwin on i686 and I can now run setup on Windows 7 64
bits without administrator privileges. Wonderful!

I just modified this:
Index: bootstrap.sh
===================================================================
RCS file: /cvs/cygwin-apps/setup/bootstrap.sh,v
retrieving revision 2.9
diff -r2.9 bootstrap.sh
63a64
> host=x86_64-w64-mingw32
Index: setup64.exe.manifest
===================================================================
RCS file: /cvs/cygwin-apps/setup/setup64.exe.manifest,v
retrieving revision 2.1
diff -r2.1 setup64.exe.manifest
25c25
<         <requestedExecutionLevel level="requireAdministrator"
uiAccess="false"/>
---
>         <requestedExecutionLevel level="asInvoker" uiAccess="false"/>

Thanks a lot to everybody for the help,

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-19 11:17           ` Frédéric Bron
@ 2013-09-25 14:13             ` Frédéric Bron
  2013-09-25 15:04               ` Larry Hall (Cygwin)
  0 siblings, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-25 14:13 UTC (permalink / raw)
  To: cygwin

> I just modified this:
> Index: setup64.exe.manifest
> ===================================================================
> RCS file: /cvs/cygwin-apps/setup/setup64.exe.manifest,v
> retrieving revision 2.1
> diff -r2.1 setup64.exe.manifest
> 25c25
> <         <requestedExecutionLevel level="requireAdministrator"
> uiAccess="false"/>
> ---
>>         <requestedExecutionLevel level="asInvoker" uiAccess="false"/>

In fact, what would be the issue to set the requested execution level
to "asInvoker" for the official setup-x86_64.exe?
People with admin rights will still be able to install for all users
and people without admin rights will be able to install for
them-selves.

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 14:13             ` Frédéric Bron
@ 2013-09-25 15:04               ` Larry Hall (Cygwin)
  2013-09-25 15:29                 ` Frédéric Bron
  2013-09-25 17:05                 ` Andrey Repin
  0 siblings, 2 replies; 30+ messages in thread
From: Larry Hall (Cygwin) @ 2013-09-25 15:04 UTC (permalink / raw)
  To: cygwin

On 9/25/2013 10:11 AM, Frédéric Bron wrote:

<snip>

> In fact, what would be the issue to set the requested execution level
> to "asInvoker" for the official setup-x86_64.exe?
> People with admin rights will still be able to install for all users
> and people without admin rights will be able to install for
> them-selves.

Doesn't that mean that "setup-x86_64.exe" needs to be "Run as Administrator"
to be installed for "All Users"?  If so, I wouldn't be in favor of the
change because it changes the default install behavior (= more confusion/
list traffic).

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 15:04               ` Larry Hall (Cygwin)
@ 2013-09-25 15:29                 ` Frédéric Bron
  2013-09-25 16:00                   ` Larry Hall (Cygwin)
  2013-09-25 17:05                 ` Andrey Repin
  1 sibling, 1 reply; 30+ messages in thread
From: Frédéric Bron @ 2013-09-25 15:29 UTC (permalink / raw)
  To: cygwin

>> In fact, what would be the issue to set the requested execution level
>> to "asInvoker" for the official setup-x86_64.exe?
>> People with admin rights will still be able to install for all users
>> and people without admin rights will be able to install for
>> them-selves.
>
>
> Doesn't that mean that "setup-x86_64.exe" needs to be "Run as Administrator"
> to be installed for "All Users"?  If so, I wouldn't be in favor of the
> change because it changes the default install behavior (= more confusion/
> list traffic).


I understand. Halas, I cannot try this my-self.
Can somebody with admin rights try to install cygwin 64 for all users
using the following setup: http://www.casalibus.fr/cygwin

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 15:29                 ` Frédéric Bron
@ 2013-09-25 16:00                   ` Larry Hall (Cygwin)
  2013-09-25 17:05                     ` Buchbinder, Barry (NIH/NIAID) [E]
  0 siblings, 1 reply; 30+ messages in thread
From: Larry Hall (Cygwin) @ 2013-09-25 16:00 UTC (permalink / raw)
  To: cygwin

On 9/25/2013 11:21 AM, Frédéric Bron wrote:
>>> In fact, what would be the issue to set the requested execution level
>>> to "asInvoker" for the official setup-x86_64.exe?
>>> People with admin rights will still be able to install for all users
>>> and people without admin rights will be able to install for
>>> them-selves.
>>
>>
>> Doesn't that mean that "setup-x86_64.exe" needs to be "Run as Administrator"
>> to be installed for "All Users"?  If so, I wouldn't be in favor of the
>> change because it changes the default install behavior (= more confusion/
>> list traffic).
>
>
> I understand. Halas, I cannot try this my-self.
> Can somebody with admin rights try to install cygwin 64 for all users
> using the following setup: http://www.casalibus.fr/cygwin

A quick check shows that yours definitely doesn't ask to elevate.
I can't check to see how that affects the downstream installation
and services ATM.

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 15:04               ` Larry Hall (Cygwin)
  2013-09-25 15:29                 ` Frédéric Bron
@ 2013-09-25 17:05                 ` Andrey Repin
  1 sibling, 0 replies; 30+ messages in thread
From: Andrey Repin @ 2013-09-25 17:05 UTC (permalink / raw)
  To: Larry Hall (Cygwin)

Greetings, Larry Hall (Cygwin)!

>> In fact, what would be the issue to set the requested execution level
>> to "asInvoker" for the official setup-x86_64.exe?
>> People with admin rights will still be able to install for all users
>> and people without admin rights will be able to install for
>> them-selves.

> Doesn't that mean that "setup-x86_64.exe" needs to be "Run as Administrator"
> to be installed for "All Users"?  If so, I wouldn't be in favor of the
> change because it changes the default install behavior (= more confusion/
> list traffic).

No, this means that it will need to request privilege elevation when
appropriate, instead of running with elevated privileges from the start.
Or we would need a tool to run postinstall scripts with elevated privileges,
where necessary. run/run2 are likely candidates for such functionality.


--
WBR,
Andrey Repin (anrdaemon@yandex.ru) 25.09.2013, <20:55>

Sorry for my terrible english...


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 16:00                   ` Larry Hall (Cygwin)
@ 2013-09-25 17:05                     ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-25 17:18                       ` Christopher Faylor
  0 siblings, 1 reply; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-25 17:05 UTC (permalink / raw)
  To: cygwin

Does setup for 64 bit cygwin need to be 64 bit?  Might all this
be avoided if setup-x86_64.exe were itself 32 bit application?

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 17:05                     ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-25 17:18                       ` Christopher Faylor
  2013-09-25 21:25                         ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-26 18:35                         ` Frédéric Bron
  0 siblings, 2 replies; 30+ messages in thread
From: Christopher Faylor @ 2013-09-25 17:18 UTC (permalink / raw)
  To: cygwin

On Wed, Sep 25, 2013 at 04:59:57PM +0000, Buchbinder, Barry (NIH/NIAID) [E] wrote:
>Does setup for 64 bit cygwin need to be 64 bit?  Might all this
>be avoided if setup-x86_64.exe were itself 32 bit application?

I lost that argument.  Apparently some 64-bit systems can't run 32-bit
applications.  I wanted to just have one setup with a check box
determining which version to install.  That idea was vehemently
rejected.

However, this should work (I haven't tried lately):

.\setup-x86 --arch=x86_64

Assuming you aren't part of the .001% who can't run x86 executables.

cgf

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 17:18                       ` Christopher Faylor
@ 2013-09-25 21:25                         ` Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-26 18:35                         ` Frédéric Bron
  1 sibling, 0 replies; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-25 21:25 UTC (permalink / raw)
  To: cygwin

Christopher Faylor sent the following at Wednesday, September 25, 2013 1:06 PM
>On Wed, Sep 25, 2013 at 04:59:57PM +0000, Buchbinder, Barry (NIH/NIAID)
>[E] wrote:
>>>Does setup for 64 bit cygwin need to be 64 bit?  Might all this
>>be avoided if setup-x86_64.exe were itself 32 bit application?
>
>I lost that argument. Apparently some 64-bit systems can't run 32-bit
>applications. I wanted to just have one setup with a check box
>determining which version to install. That idea was vehemently rejected.
>
>However, this should work (I haven't tried lately):
>
>.\setup-x86 --arch=x86_64
>
>Assuming you aren't part of the .001% who can't run x86 executables.

Still works!

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-25 17:18                       ` Christopher Faylor
  2013-09-25 21:25                         ` Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-26 18:35                         ` Frédéric Bron
  1 sibling, 0 replies; 30+ messages in thread
From: Frédéric Bron @ 2013-09-26 18:35 UTC (permalink / raw)
  To: cygwin

> However, this should work (I haven't tried lately):
>
> .\setup-x86 --arch=x86_64
> Assuming you aren't part of the .001% who can't run x86 executables.

That works, as soon as I have renamed setup-x86.exe to foo.exe!
That's an easy and simple solution.
Thanks,

Frédéric

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-23  1:53 ` Larry Hall (Cygwin)
@ 2013-09-23 14:27   ` Buchbinder, Barry (NIH/NIAID) [E]
  0 siblings, 0 replies; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-23 14:27 UTC (permalink / raw)
  To: cygwin

Larry Hall (Cygwin) sent the following at Sunday, September 22, 2013 9:42 PM
>No, "All Users" is also required to set up services (like sshd, crond,
>etc.) to work for all users (i.e. switch user context). This is the
>recommended way to install so that these subsequent facilities can be
>used with a minimum of fuss or trouble.

Thank you for the explanation.

Still, I'd like to urge the setup-meisters to keep those of us without
admin rights in mind.  If we have to compile setup ourselves, many of
us will be staying with 32 bit for a long time.

Thanks again to everyone,

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
  2013-09-22 19:43 Buchbinder, Barry (NIH/NIAID) [E]
@ 2013-09-23  1:53 ` Larry Hall (Cygwin)
  2013-09-23 14:27   ` Buchbinder, Barry (NIH/NIAID) [E]
  0 siblings, 1 reply; 30+ messages in thread
From: Larry Hall (Cygwin) @ 2013-09-23  1:53 UTC (permalink / raw)
  To: cygwin

On 9/22/2013 2:18 PM, Buchbinder, Barry (NIH/NIAID) [E] wrote:
> Correct me if I'm wrong (like I need to ask!), but my impression is that the
> only thing for which setup for 'Cygwin for All Users' currently needs admin
> privileges is to create shortcuts in "C:\Users\All Users\Desktop" and
> "C:\Users\All Users\Start Menu" (or wherever they point to).

No, "All Users" is also required to set up services (like sshd, crond, etc.)
to work for all users (i.e. switch user context).  This is the recommended
way to install so that these subsequent facilities can be used with a
minimum of fuss or trouble.

-- 
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

* RE: cannot run setup64.exe without admin privileges (even if renamed foo.exe)
@ 2013-09-22 19:43 Buchbinder, Barry (NIH/NIAID) [E]
  2013-09-23  1:53 ` Larry Hall (Cygwin)
  0 siblings, 1 reply; 30+ messages in thread
From: Buchbinder, Barry (NIH/NIAID) [E] @ 2013-09-22 19:43 UTC (permalink / raw)
  To: cygwin

Yaakov (Cygwin/X) sent the following at Thursday, September 12, 2013 12:42 PM
>UAC Installer Detection only affects x86 binaries, so that only helps
>with setup-x86.exe.  As for setup-x86_64.exe, its builtin manifest
>requires Admin privileges because otherwise it won't promote itself
>automatically, and most people install Cygwin for All Users.

Correct me if I'm wrong (like I need to ask!), but my impression is that the
only thing for which setup for 'Cygwin for All Users' currently needs admin
privileges is to create shortcuts in "C:\Users\All Users\Desktop" and
"C:\Users\All Users\Start Menu" (or wherever they point to).

It seems to me that what people who want to install 64bit Cygwin must do is
to install 32 bit first, then compile setup, then install 64 bit.  If that's
what I'll have to do, I'll probably stick with 32 bit for as long as possible

That seems like a lot more bother than creating some shortcuts.
(Where "bother" = "bother_to_an_individual" X "number_of_individuals".)

(As for "most people install Cygwin for All Users", how could one possibly
know?  And there's a difference between installing for all users and needing
to do so.  I don't have admin privileges, but if I did I would have
installed for all users.  And no one else uses my machine and no one in my
office has any idea how to use my scripts, let alone use Cygwin to do
something by themselves.)

So this is a plea* that the setup process be designed to be as friendly as
possible for those without admin privileges.  Change setup.exe's name to not
have "setup" or "install".  (I nominate "getcygwin".)  Would providing two
versions of setup-x86_64.exe that differ only in the manifest be burdensome
to the maintainers?  Etc.

* not a request

Thanks for considering this.

And thanks to everyone for their contributions to Cygwin.

Best wishes,

- Barry
  Disclaimer: Statements made herein are not made on behalf of NIAID.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2013-09-26 15:57 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-09-12 11:47 cannot run setup64.exe without admin privileges (even if renamed foo.exe) Frédéric Bron
2013-09-12 15:26 ` Buchbinder, Barry (NIH/NIAID) [E]
2013-09-12 15:31   ` Frédéric Bron
2013-09-12 15:44     ` Ryan Johnson
2013-09-12 15:52       ` LRN
2013-09-12 15:52       ` Frédéric Bron
2013-09-12 16:42       ` Buchbinder, Barry (NIH/NIAID) [E]
2013-09-12 17:02         ` Ryan Johnson
2013-09-12 17:00 ` Yaakov (Cygwin/X)
2013-09-13  0:09   ` Christopher Faylor
2013-09-18 15:26   ` Frédéric Bron
2013-09-18 15:35     ` Frédéric Bron
2013-09-18 17:20       ` Frédéric Bron
2013-09-18 17:40   ` Frédéric Bron
2013-09-18 17:54     ` Christopher Faylor
2013-09-18 18:09       ` Frédéric Bron
2013-09-18 18:39         ` Charles Wilson
2013-09-19 11:17           ` Frédéric Bron
2013-09-25 14:13             ` Frédéric Bron
2013-09-25 15:04               ` Larry Hall (Cygwin)
2013-09-25 15:29                 ` Frédéric Bron
2013-09-25 16:00                   ` Larry Hall (Cygwin)
2013-09-25 17:05                     ` Buchbinder, Barry (NIH/NIAID) [E]
2013-09-25 17:18                       ` Christopher Faylor
2013-09-25 21:25                         ` Buchbinder, Barry (NIH/NIAID) [E]
2013-09-26 18:35                         ` Frédéric Bron
2013-09-25 17:05                 ` Andrey Repin
2013-09-22 19:43 Buchbinder, Barry (NIH/NIAID) [E]
2013-09-23  1:53 ` Larry Hall (Cygwin)
2013-09-23 14:27   ` Buchbinder, Barry (NIH/NIAID) [E]

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).