Question: Desired owner/group when running setup-1.7.exe

Charles Wilson cygwin@cwilson.fastmail.fm
Sat Apr 18 14:14:00 GMT 2009


Corinna Vinschen wrote:
>   owner: Current user.
>   group: The primary group of the account running setup.
>   other: Everyone, as usual.

Although "current user" is Administrator if you launch setup on Vista as
an ordinary user, but you have UAC enabled.

> As the discussion in the aforementioned thread shows, this might not be
> feasible in all environments.  OTOH, whatever we do, somebody *will*
> complain.

Yep!

> I don't think it makes sense to have a setting in setup.exe to choose
> user and group explicitely.  We should make a default setting and
> everything else is up to the chown tool. 

I'm not so sure. Your solution would mean that *every* time I update, I
would need to do a full recursive chown -R.  But not *really* recursive:
I don't, for example, want to modify the ownership of stuff under /home
(or /c, /cygdrive/ //server/share/, etc). And probably I'd want to
exclude SOME stuff under /etc (such as the files owned by sshd).  And if
that weren't enough, I'm doing a giant recursive chown -R as a second
manual step, after running setup.exe to update "xrsi" -- a package that
contains 8 files.

It seems to make more sense to me to have setup.exe take additional
arguments, so that it can DTRT (as determined by me) on just those 8
files -- in one step.  Then I can simply change the shortcut target for
setup.exe...

However, you still need an answer to "what should setup do by default"...

> The question is, which default
> setting is the most feasible and will probably lead to the least
> complaints.
> 
> So, here's the multiple choice question:
> 
>   How should setup.exe choose the file ownership for extracted files?
> 
>   [X] I like it as it is.  Just keep it.
> 
>   [ ] If the current user is an administrative user, make "Administrators"
>       the group of the files:
> 
>         owner: Current user.
>         group: Administrators.
> 
>   [ ] If the current user is an administrative user, make "Administrators"
>       the owner of the files:
> 
>         owner: Administrators.
>         group: The primary group of the account running setup.
> 
>   Comment: 
I think setup should accept three new command-line arguments:
--change-owner=
--change-group=
--add-group-write-permission

The first two are self-explanatory. The last one is very specific, and
not the "general" solution of "change perms to" because I think the
packager will have more understanding -- and more fine-grained control
over -- the appropriate perms of each individual file in his package.
That is, different files may have different perms.  A setup.exe
cmd-line-arg is by definition a one-size-fits-all hammer. The *only*
reasonable use for such a hammer in this context is "I want to give a
particular group admin-like control over my entire cygwin installation".
That is,
  --change-group=wheel --add-group-write-permission

--
Chuck



More information about the Cygwin-apps mailing list