Open GoogleCodeExporter opened 9 years ago
The reason the problem goes away when the "inputs" field is empty is that
msvs.py contains this hack in _AddActions():
# Attach actions to the gyp file if nothing else is there.
inputs = a.get('inputs') or [relative_path_of_gyp_file]
So when "inputs" is empty, if the .gyp file is changed, it forces the action to
be re-run, even if the action command didn't change. This does not help if the
action command was changed as a result of a .gypi file changing, though (which
is the case for my change above, http://codereview.chromium.org/10221026/).
Original comment by mseaborn@chromium.org
on 2 May 2012 at 4:45
Commit: b5965b0c90a4c6baf306d57bd3bcefba26c7676d
Email: mseaborn@chromium.org@78cadc50-ecff-11dd-a971-7dbc132099af
MSVS 2008: Fix to ensure that actions are re-run when the command changes
There was some code to re-run an action, but it only worked if the
command change came from a change to a .gyp file, and only if the
"inputs" list was empty. It didn't work if the command change came
from a change to a .gypi file.
To fix this, we create "*.gypcmd" stamp files that contain the command
text, and when the command text changes we update these files'
timestamps.
If a Gyp target contains multiple actions, this should rerun only the
actions that changed.
BUG=http://code.google.com/p/gyp/issues/detail?id=262
TEST=test/actions-args-change
Review URL: https://chromiumcodereview.appspot.com/10375015
git-svn-id: http://gyp.googlecode.com/svn/trunk@1362
78cadc50-ecff-11dd-a971-7dbc132099af
M pylib/gyp/generator/msvs.py
A test/actions-args-change/gyptest-all.py
A test/actions-args-change/src/arg-action.gyp
A test/actions-args-change/src/arg-action.gypi
A test/actions-args-change/src/dummy-fixed-input.txt
A test/actions-args-change/src/write_file.py
Original comment by bugdroid1@chromium.org
on 8 May 2012 at 8:11
This is fixed and rolled into Chromium, and I was able to commit the change
that was broken by this bug.
Original comment by mseaborn@chromium.org
on 9 May 2012 at 12:33
Re-opening because I am reverting the change because the .gypcmd files get
deleted by the Chromium bots.
Original comment by mseaborn@chromium.org
on 16 May 2012 at 6:19
Commit: 18c2a16fdfd8b0aba4b691ceca6cabb839614abb
Email: mseaborn@chromium.org@78cadc50-ecff-11dd-a971-7dbc132099af
Revert r1362: MSVS 2008: Fix to ensure that actions are re-run when the command
changes
This change caused a performance regression in the Windows incremental
build on the Chromium bots, because the bots are deleting the new
.gypcmd files from the source tree between runs, which triggers a lot
of rebuilding.
It's not practical to add the .gypcmd files to all the svn:ignore
lists, so I'm reverting the change until we find a better solution.
BUG=http://code.google.com/p/gyp/issues/detail?id=262
TEST=trybots
Review URL: https://chromiumcodereview.appspot.com/10377171
git-svn-id: http://gyp.googlecode.com/svn/trunk@1383
78cadc50-ecff-11dd-a971-7dbc132099af
M pylib/gyp/generator/msvs.py
D test/actions-args-change/gyptest-all.py
D test/actions-args-change/src/arg-action.gyp
D test/actions-args-change/src/arg-action.gypi
D test/actions-args-change/src/dummy-fixed-input.txt
D test/actions-args-change/src/write_file.py
Original comment by bugdroid1@chromium.org
on 17 May 2012 at 4:06
Original issue reported on code.google.com by
mseaborn@chromium.org
on 2 May 2012 at 1:39