UID/GID_OFFSET (Was: Re: WITH_GCC)

Mel Flynn rflynn at acsalaska.net
Wed Jun 13 19:31:06 UTC 2012


On 12-6-2012 2:38, Warren Block wrote:
> On Fri, 25 May 2012, Mel Flynn wrote:
> 
>> On 20-5-2012 14:06, Chris Rees wrote:
>>
>>> Usually.  Sometimes it's (ab)used to include the relevant bsd.*.mk
>>> file without adding dependencies (WANT_GNOME), but normally that's
>>> what WANT_ is used for.
>>>
>>> Definitely add a warning that if you want to use a WANT_ variable you
>>> should also check the relevant Mk/ files to check for syntax.
>>
>> What's also not consistent is the use of:
>> USE_FOO=    42+
>> which is shorthand for:
>> USE_FOO=    yes
>> WANT_FOO_VER=    42+
>>
>> Anyway, since Warren is on the job, on one of my travels through pmk, I
>> turned a corner and met these totally awesome user settable variables:
>> UID_OFFSET
>> GID_OFFSET
>>
>> No docs on them in pmk itself or share/examples/etc/make.conf. What they
>> do is add the specified number to the UID and GID that a port defines by
>> using /usr/ports/{UIDS,GIDS}. This is extremely useful if you are using
>> multiple jails on one machine and don't want the uid's to clash (shared
>> memory for example).
>> It's also useful, if you have different providers for uid/gid
>> information through the use of NSS modules. Knowing that ports won't
>> ever get into your "module range" makes you sleep better.
>> Example in /etc/make.conf
>> UID_OFFSET=    20000
>> GID_OFFSET=    ${UID_OFFSET} # best to keep them equal
>>
>> Installing for example postgresql, will now use uid/gid 20070 instead
>> of 70.
> 
> Okay, I've finally cleared some room to work on this; sorry about the
> delay.
> 
> My main question is where to add these descriptions.  Should they go in
> existing sections where possible?  Or are we talking about a new
> section, and if so, where?  At the end of the Dependencies section?

Ideally in man7/ports.7, but I see that is quite outdated. It shouldn't
be in the porters handbook. The variables are useful for end users. The
handbook maybe?

-- 
Mel


More information about the freebsd-ports mailing list