tech-pkg archive

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

Re: per-package MAKE_JOBS



* On 2018-01-07 at 23:10 GMT, David Holland wrote:

> I got tired of having to build qemu by hand to keep it from OOMing, so
> the following patch allows MAKE_JOBS.pkg to override the global
> MAKE_JOBS setting.
> 
> It uses PKGBASE as the key; is that right? Prior art is surprisingly
> hard to find given how many ${FOO.bar} things we have.
> 
> Also, should it set some variable (say, PKG_MAKE_JOBS) to the resolved
> jobs count for this package, so it can be interrogated elsewhere?

I do it based on PKGPATH with a small mk.conf addition, e.g.:

  PKG_MAKE_JOBS.lang/perl5=	4
  PKG_MAKE_JOBS.lang/gcc49=	8
  MAKE_JOBS_DEFAULT=		2
  MAKE_JOBS=		${PKG_MAKE_JOBS.${PKGPATH}:U${MAKE_JOBS_DEFAULT}}

PKGPATH is set early, PKGBASE is set late, which is why I use PKGPATH
for this implementation.  I can't recall the exact issues I had with
using PKGBASE (or whether I had any at all).

I don't have any strong opinions either way on the proposed patch.

-- 
Jonathan Perkin  -  Joyent, Inc.  -  www.joyent.com


Home | Main Index | Thread Index | Old Index