version 1.62, 2020/01/13 14:15:21 |
version 1.63, 2020/01/13 14:51:50 |
|
|
_exit(1); |
_exit(1); |
} |
} |
|
|
static Job myjob; |
|
|
|
void |
void |
job_attach_node(Job *job, GNode *node) |
job_attach_node(Job *job, GNode *node) |
{ |
{ |
|
|
* JOB_IS_EXPENSIVE, perform the computation for |
* JOB_IS_EXPENSIVE, perform the computation for |
* sequential make to figure out whether to display the |
* sequential make to figure out whether to display the |
* command or not. */ |
* command or not. */ |
if ((job->flags & JOB_SILENT) && job == &myjob) |
if ((job->flags & JOB_SILENT) && sequential) |
determine_expensive_job(job); |
determine_expensive_job(job); |
if ((job->flags & (JOB_SILENT | JOB_IS_EXPENSIVE)) |
if ((job->flags & (JOB_SILENT | JOB_IS_EXPENSIVE)) |
== JOB_SILENT) |
== JOB_SILENT) |
|
|
int |
int |
run_gnode(GNode *gn) |
run_gnode(GNode *gn) |
{ |
{ |
|
Job *j; |
if (!gn || (gn->type & OP_DUMMY)) |
if (!gn || (gn->type & OP_DUMMY)) |
return NOSUCHNODE; |
return NOSUCHNODE; |
|
|
job_attach_node(&myjob, gn); |
assert(availableJobs != NULL); |
while (myjob.exit_type == JOB_EXIT_OKAY) { |
j = availableJobs; |
bool finished = job_run_next(&myjob); |
availableJobs = availableJobs->next; |
|
job_attach_node(j, gn); |
|
while (j->exit_type == JOB_EXIT_OKAY) { |
|
bool finished = job_run_next(j); |
if (finished) |
if (finished) |
break; |
break; |
handle_one_job(&myjob); |
handle_one_job(j); |
} |
} |
|
|
|
j->next = availableJobs; |
|
availableJobs = j; |
return gn->built_status; |
return gn->built_status; |
} |
} |
|
|