clobber.py sometimes nukes arg.gn files |
|||
Issue descriptionIf a landmine causes the output directory to be clobbered then clobber.py:clobber is run. This attempts to gently delete directories, without losing the args.gn files. However if delete_dir hits an exception (perhaps because a previously built version of Chrome is running) then the code to restore the args.gn (and build.ninja) files will be skipped. This is not extremely common but I did hit this and it caused some wasted time as I tried to remember what gn settings I had settled on. This is especially likely on Windows where running binaries cannot be deleted.
,
May 18 2016
fixing this shouldn't block the migration, though (IMO) ...
,
May 18 2016
Agreed that it shouldn't block migration. Thanks for fixing the tag.
,
May 18 2016
Allow me to lobby as usual for only having outputs in the output dir. :/
,
May 20 2016
The following revision refers to this bug: https://chromium.googlesource.com/chromium/src.git/+/562df4f33e0a29669b83d451d33c81648a9e023e commit 562df4f33e0a29669b83d451d33c81648a9e023e Author: brucedawson <brucedawson@chromium.org> Date: Fri May 20 22:00:46 2016 Fix clobber.py to restore args.gn on failure If delete_dir or os.mkdir throw an exception then the code to restore args.gn, build.ninja, and build.ninja.d will not run. This breaks a design goal of gn which is that the args.gn files should not be deleted. The fix is to catch the exception and raise it after the files have been restored. To test the code leave chrome.exe or base_unittests.exe running in one window and run this in another: python build\clobber.py d:\src\chromium\src\out Note that if you do this without the patch applied then all args.gn files may be deleted, so consider backing them up. Also note that args.gn files won't be restored unless build.ninja and build.ninja.d files are also present, so back them up. Just apply the patch first - it's easier. BUG= 612940 Review-Url: https://codereview.chromium.org/1996833002 Cr-Commit-Position: refs/heads/master@{#395177} [modify] https://crrev.com/562df4f33e0a29669b83d451d33c81648a9e023e/build/clobber.py
,
May 20 2016
|
|||
►
Sign in to add a comment |
|||
Comment 1 by dpranke@chromium.org
, May 18 2016