MAKE_JOBS_UNSAFE (some more ports)

David Naylor naylor.b.david at gmail.com
Tue May 26 16:16:40 UTC 2009


On Tuesday 26 May 2009 10:48:25 Pav Lucistnik wrote:
> David Naylor píše v út 26. 05. 2009 v 08:19 +0200:
> > pav: ${_MAKE_JOBS:C/-j//} won't work with DISABLE_MAKE_JOBS (or
> > MAKE_JOBS_UNSAFE) since it needs to always be a positive number, secondly
> > it still cannot be used for conditional code (since it is defined in the
> > post section, but the whole code could always be moved to the pre
> > section).
>
> I'm hesitant to modify bsd.port.mk for benefit of just four ports.
> Also, I think having MAKE_JOBS_NUMBER set to 1 when the feature is in
> fact disable, is counter-intuitive (because -j1 is very different to no
> -j at all).

I understand, I see the light.  By the way it is two ports requiring the 
below.  

What about the change that exposes MAKE_JOBS_NUMBER when MAKE_JOBS_SAFE or 
FORCE_MAKE_JOBS are defined (to avoid using ${_MAKE_JOBS:C/-j//}, not sure 
what the policy is of ports using *.mk internals).  I think that is a 
reasonable change??? 

> So how about just having
>
> .if defined(DISABLE_MAKE_JOBS)
> MAKE_JOBS_NUMBER=	1
> .else
+.if !defined(MAKE_JOBS_NUMBER)
> MAKE_JOBS_NUMBER!=	echo `${SYSCTL} -n kern.smp.cpus`
+.endif
> .endif
>
> in ooo makefile?

This will work in OOo2*, the OOo3 will also need a check for DISABLE_MAKE_JOBS 
since they rely on MKAE_JOBS_NUMBER always being set (just the way they do 
things).  

Will fix and send another patch.  
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 195 bytes
Desc: This is a digitally signed message part.
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20090526/b478377f/attachment.pgp


More information about the freebsd-ports mailing list