tech-pkg archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: Moving mk.conf



What I've always done for multiple pkgsrc trees is:

in /etc/mk.conf

.ifdef BSD_PKG_MK
.  if exists(${.CURDIR}/../../pkgsrc.conf)
.    include "${.CURDIR}/../../pkgsrc.conf"
.  elif exists(${.CURDIR}/../pkgsrc.conf)
.    include "${.CURDIR}/../pkgsrc.conf"
.  elif exists(${.CURDIR}/pkgsrc.conf)
.    include "${.CURDIR}/pkgsrc.conf"
.  endif
.endif

To explain further, there's a file called pkgsrc.conf file in the
top-level pkgsrc instance which includes definitions specific to that
tree, like PKG_DBDIR, LOCALBASE, etc.  It's automatically called from
a central /etc/mk.conf.

I'm sorry if this is "the wrong way to do it", since no-one told me.

Regards,
Alistair


Home | Main Index | Thread Index | Old Index