Add .MAKE.ALWAYS_PASS_JOB_QUEUE knob (default yes)
for backwards compatability.
This commit is contained in:
parent
a6822ce859
commit
9a4bc556be
@ -171,6 +171,14 @@ __RCSID("$NetBSD: job.c,v 1.175 2013/07/30 19:09:57 sjg Exp $");
|
|||||||
#include "trace.h"
|
#include "trace.h"
|
||||||
# define STATIC static
|
# define STATIC static
|
||||||
|
|
||||||
|
/*
|
||||||
|
* FreeBSD: traditionally .MAKE is not required to
|
||||||
|
* pass jobs queue to sub-makes.
|
||||||
|
* Use .MAKE.ALWAYS_PASS_JOB_QUEUE=no to disable.
|
||||||
|
*/
|
||||||
|
#define MAKE_ALWAYS_PASS_JOB_QUEUE ".MAKE.ALWAYS_PASS_JOB_QUEUE"
|
||||||
|
static int Always_pass_job_queue = TRUE;
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* error handling variables
|
* error handling variables
|
||||||
*/
|
*/
|
||||||
@ -1360,7 +1368,7 @@ JobExec(Job *job, char **argv)
|
|||||||
(void)fcntl(0, F_SETFD, 0);
|
(void)fcntl(0, F_SETFD, 0);
|
||||||
(void)lseek(0, (off_t)0, SEEK_SET);
|
(void)lseek(0, (off_t)0, SEEK_SET);
|
||||||
|
|
||||||
if (job->node->type & OP_MAKE) {
|
if (Always_pass_job_queue || (job->node->type & OP_MAKE)) {
|
||||||
/*
|
/*
|
||||||
* Pass job token pipe to submakes.
|
* Pass job token pipe to submakes.
|
||||||
*/
|
*/
|
||||||
@ -2226,6 +2234,9 @@ Job_Init(void)
|
|||||||
|
|
||||||
lastNode = NULL;
|
lastNode = NULL;
|
||||||
|
|
||||||
|
Always_pass_job_queue = getBoolean(MAKE_ALWAYS_PASS_JOB_QUEUE,
|
||||||
|
Always_pass_job_queue);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* There is a non-zero chance that we already have children.
|
* There is a non-zero chance that we already have children.
|
||||||
* eg after 'make -f- <<EOF'
|
* eg after 'make -f- <<EOF'
|
||||||
|
@ -721,6 +721,17 @@ The preferred variable to use is the environment variable
|
|||||||
because it is more compatible with other versions of
|
because it is more compatible with other versions of
|
||||||
.Nm
|
.Nm
|
||||||
and cannot be confused with the special target with the same name.
|
and cannot be confused with the special target with the same name.
|
||||||
|
.It Va .MAKE.ALWAYS_PASS_JOB_QUEUE
|
||||||
|
Tells
|
||||||
|
.Nm
|
||||||
|
whether to pass the descriptors of the job token queue
|
||||||
|
even if the target is not tagged with
|
||||||
|
.Ic .MAKE
|
||||||
|
The default is
|
||||||
|
.Ql Pa yes
|
||||||
|
for backwards compatability with
|
||||||
|
.Fx 9
|
||||||
|
and earlier.
|
||||||
.It Va .MAKE.DEPENDFILE
|
.It Va .MAKE.DEPENDFILE
|
||||||
Names the makefile (default
|
Names the makefile (default
|
||||||
.Ql Pa .depend )
|
.Ql Pa .depend )
|
||||||
|
Loading…
x
Reference in New Issue
Block a user