The default bug view has changed. See this FAQ.

XPConnect is rebuilt unnecessarily

RESOLVED FIXED in mozilla15

Status

()

Core
Build Config
RESOLVED FIXED
5 years ago
5 years ago

People

(Reporter: khuey, Assigned: khuey)

Tracking

unspecified
mozilla15
Points:
---
Bug Flags:
in-testsuite -

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

Created attachment 619545 [details] [diff] [review]
Patch

This was ... fun.

js/xpconnect/src/Makefile.in has the following lines

nsXPConnect.$(OBJ_SUFFIX): dom_quickstubs.h

...

dom_quickstubs.h: dom_quickstubs.cpp

qsgen.py writes the .h after the .cpp.  Thus, the mtime of the .h is later than the mtime of the .cpp.  When we rebuild, pymake recognizes that dom_quickstubs.h needs to be rebuilt and "executes" the empty rule (but prints no logging information!).  It then rebuilds nsXPConnect.$(OBJ_SUFFIX) because its dependency was just rebuilt.
Attachment #619545 - Flags: review?(ted.mielczarek)
Comment on attachment 619545 [details] [diff] [review]
Patch

Review of attachment 619545 [details] [diff] [review]:
-----------------------------------------------------------------

Is this a pymake bug that we should file? Obviously the logic here was bad, so the dependency checking was doing the right thing, but gmake doesn't seem to exhibit this behavior.
Attachment #619545 - Flags: review?(ted.mielczarek) → review+
After some testing, it looks like gmake is a little more lenient here, running "make -d" on a testcase prints:
      No need to remake target `blah.cpp'.
     Finished prerequisites of target file `blah.h'.
     Prerequisite `blah.cpp' is newer than target `blah.h'.
    No commands for `blah.h' and no prerequisites actually changed.
    No need to remake target `blah.h'.

If you had an actual command (even an empty one) in the blah.h: blah.cpp rule, it'd get run every time.
https://hg.mozilla.org/integration/mozilla-inbound/rev/5bc5a841856e
Flags: in-testsuite-
Target Milestone: --- → mozilla15
https://hg.mozilla.org/mozilla-central/rev/5bc5a841856e
Status: NEW → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.