Commit 0ed63380 authored by Daniel Bevenius's avatar Daniel Bevenius
Browse files

build: fix config.gypi target

The config.gypi target has a recipe that uses the control function error
to report if the config.gypi file is missing or if it is stale (the
configure file was updated which is a prerequisite of this rule).

GNU make has two phases, immediate and deferred. During the first phase
 it will expand any variables or functions as the makefile is parsed.
The recipe in this case is a shell if statement, which is a deferred
construct. But the control function $(error) is an immediate construct
which will cause the makefile processing to stop during the first phase
of the Make process.

If I understand this correctly the only possible outcome of this rule is
the "Stale config.gypi, please re-run ./configure"  message which will
be done in the first phase and then exit. The shell condition will not
be considered. So it will never report that the config.gypi is missing.

bnoordhuis suggested that we simply change this into a single error
message:
"Missing or stale config.gypi, please run configure"

PR-URL: https://github.com/nodejs/node/pull/9053


Reviewed-By: default avatarBen Noordhuis <info@bnoordhuis.nl>
Reviewed-By: default avatarGibson Fahnestock <gibfahn@gmail.com>
parent fcee4d4a
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment