Hi Maciej,
Am 22.09.2009 um 10:42 schrieb Maciej (Matchek) Blizinski:
On Tue, Sep 22, 2009 at 9:09 AM, Dagobert Michelsen
<[email protected]> wrote:
What do you think about my proposal I sent some time ago?
Am 06.09.2009 um 22:14 schrieb Dagobert Michelsen:
Am 05.09.2009 um 18:21 schrieb Maciej (Matchek) Blizinski:
My day-to-day environment has umask set to 027; but many packages,
when built with this umask, end up with binaries having permissions
0750. Perhaps it would be a good idea to do a GAR sanity check:
bail
out if umask is set to anything else than 022 when building a
package?
The standard user:group are already set in cswproto, as are the
permissions
for directories:
# Prototype defaults
$StdOwn = 'root';
$StdGrp = 'bin';
$StdDirPerm = '0755';
I could imagine setting a default for files. Or changing the umask
to 022
automatically on GAR invocation.
I would suggest having something like this in the ~/.garrc file:
STOP_ON_WRONG_UMASK = 1
If the umask is not 022, the build would stop.
BTW, we still a way of easily tweaking
the prototype as PROTOTYPE_FILTERs are still too complex.
Something like this could be useful:
PROTOTYPE_FILES_mytweaks = $(bindir)/.*\.conf
PROTOTYPE_PERMS_mytweaks = 0644
PROTOTYPE_CLASS_mytweaks = cswconffile
PROTOTYPE_MODIFIERS = mytweaks
Here, PROTOTYPE_MODIFIERS is a list of modifiers to apply where
for each
modifier one or more fields can be changed.
And
PROTOTYPE_USER_mytweaks = myuser
which would trigger the addition of 'ugfiles' to classes.
Sounds good?
From the user's perspective, it's easier to think in terms of
accomplishing a specific task. If I want to set user/group/permissions
for a specific file, I'd find it more intuitive to use "USERGROUP"
prefix rather than "PROTOTYPE", even though it's where the tweaking
takes place under the hood. How about the following?
USERGROUP_PASSWD = /etc/opt/csw/pkg/CSWfoo/cswusergroup
USERGROUP_MODIFIERS = mytweaks
USERGROUP_mytweaks_USER = mysql
USERGROUP_mytweaks_GROUP = mysql
USERGROUP_mytweaks_PERMS = 0700
USERGROUP_mytweaks_FILES = /var/opt/csw/mysql5
The point is that you can modify all fields from the prototype here,
ftype, class, major, minor, owner, mode, link-destinations, just
everything. It is meant to replace the PROTOTYPE_FILTER, not just as
a shortcut to cswusergroup. So fixating only on USERGROUP seems wrong
to me.
Best regards
-- Dago
_______________________________________________
maintainers mailing list
[email protected]
https://lists.opencsw.org/mailman/listinfo/maintainers