make distribution and cap_mkdb -l from 5 to 6

Ruslan Ermilov ru at
Sat Aug 13 08:54:18 GMT 2005


On Sat, Aug 13, 2005 at 12:33:08AM +0200, Jeremie Le Hen wrote:
> I was giving a try to the sysutils/etcmerge port in order to ease the
> upgrade of /etc from RELENG_5 to RELENG_6.  This revealed me that the
> ``distribution'' target in RELENG_6's src/etc/Makefile calls cap_mkdb(8)
> with either "-l" or "-L" flag, depending on endianess.  Unfortunately
> RELENG_5's cap_mkdb(8) doesn't have this flag and this resulted.
> I understand that using RELENG_6 sources on RELENG_5 is something quite
> unusual but it's quite disconcerting and prevents me from using
> etcmerge.  I would really like to avoid merging /etc manually since I
> have number of changes in my /etc and number of changes between 5's /etc
> and 6's one are both huge.  Yes, I know mergemaster(8), that's what I
> call ``manually'' :-).
I don't remember exactly how etcmerge works, but if it calls "make
distribution" from src/etc/, it's in trouble, please go on reading...

> Can this issue be resolved in a way or another ?  I'm not sure using
> ${.OBJDIR}'s cap_mkdb(8) is an option.
You should be running "make distribution" from under top of the src/
tree, not src/etc/.  This takes care of properly setting the runtime
environment up so that a bootstrapped version of cap_mkdb(8) is used,
besides many other useful things.  We bootstrap cap_mkdb(8) if (this
was copied from Makefile.inc1):

.if ${BOOTSTRAPPING} < 600015
_cap_mkdb=	usr.bin/cap_mkdb

It may also be that for some reason your /usr/include/osreldate.h is
lying about the currently installed version.

To make the long story short...

You can check all of this easily; assuming your sources are in the
kosher location /usr/src, the bootstrapped version of cap_mkdb(8)
capable of running on your host should be sitting ready in:


(Extrapolate this appropriately to your environment.)

Ruslan Ermilov
ru at
FreeBSD committer
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url :

More information about the freebsd-current mailing list