aboutsummaryrefslogtreecommitdiff
path: root/sync_chromium.py
diff options
context:
space:
mode:
authorkjellander@webrtc.org <kjellander@webrtc.org>2014-09-18 13:47:23 +0000
committerkjellander@webrtc.org <kjellander@webrtc.org>2014-09-18 13:47:23 +0000
commite94f83a1919120deb48e97bc91955d0ca12e43fe (patch)
tree75ea120e0ee6975d7b043bc797ecb26e2b54642e /sync_chromium.py
parent205c15a2244967329377d5c28b2a07ea6d64a8c9 (diff)
downloadwebrtc-e94f83a1919120deb48e97bc91955d0ca12e43fe.tar.gz
Cleanup .gclient_entries to avoid sync problems.
The .gclient_entries file is written after a successful gclient sync operation and contains paths mapped to URLs for all DEPS entries that have been synced. This has been causing problems for users when switching from the legacy Subversion based checkouts to the new DEPS approach using a Chromium Git checkout combined with symlinks. Also it has been discovered that when entries have been removed from the Chromium DEPS file, subsequent gclient sync operations fail when it's trying to process those directories. This CL changes so that .gclient_entries is wiped for the WebRTC checkout when moving from the legacy SVN to Git. It also wipes the chromium/.gclient_entries file when a new Chromium revision is about to be synced, to avoid problems when DEPS entries have been removed. BUG=415219 R=agable@chromium.org Review URL: https://webrtc-codereview.appspot.com/28509004 git-svn-id: http://webrtc.googlecode.com/svn/trunk@7222 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'sync_chromium.py')
-rwxr-xr-xsync_chromium.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/sync_chromium.py b/sync_chromium.py
index d02346c97a..db6fb98ef0 100755
--- a/sync_chromium.py
+++ b/sync_chromium.py
@@ -59,6 +59,12 @@ def main():
return 0
os.unlink(flag_file)
+ # To avoid gclient sync problems when DEPS entries have been removed we must
+ # wipe the .gclient_entries file that contains cached URLs for all DEPS.
+ entries_file = os.path.join(opts.chromium_dir, '.gclient_entries')
+ if os.path.exists(entries_file):
+ os.unlink(entries_file)
+
env = os.environ.copy()
env['GYP_CHROMIUM_NO_ACTION'] = '1'
gclient_cmd = 'gclient.bat' if sys.platform.startswith('win') else 'gclient'