From b5fd5726709aa3da3ca391454f5e3b6c4f9b48b2 Mon Sep 17 00:00:00 2001 From: Marshall Greenblatt Date: Tue, 25 Nov 2014 23:45:13 +0000 Subject: [PATCH] Remove the check_revision.py script since it only works with SVN checkouts and SVN checkouts are no longer supported. git-svn-id: https://chromiumembedded.googlecode.com/svn/trunk@1938 5089003a-bbd8-11dd-ad1f-f1f9622dbc98 --- tools/check_revision.py | 92 ----------------------------------------- tools/gclient_hook.py | 4 -- 2 files changed, 96 deletions(-) delete mode 100644 tools/check_revision.py diff --git a/tools/check_revision.py b/tools/check_revision.py deleted file mode 100644 index ba4d495d4..000000000 --- a/tools/check_revision.py +++ /dev/null @@ -1,92 +0,0 @@ -# Copyright (c) 2011 The Chromium Embedded Framework Authors. All rights -# reserved. Use of this source code is governed by a BSD-style license that -# can be found in the LICENSE file. - -from file_util import * -from optparse import OptionParser -from svn_util import * -import sys - -# cannot be loaded as a module -if __name__ != "__main__": - sys.stderr.write('This file cannot be loaded as a module!') - sys.exit() - - -# parse command-line options -disc = """ -This utility checks that the correct Chromium revision is being used. -""" - -parser = OptionParser(description=disc) -parser.add_option('-q', '--quiet', - action='store_true', dest='quiet', default=False, - help='do not output detailed status information') -(options, args) = parser.parse_args() - -# The CEF root directory is the parent directory of _this_ script. -cef_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), os.pardir)) -src_dir = os.path.join(cef_dir, os.pardir) - -if not os.path.exists(os.path.join(cef_dir, '.svn')) or \ - not os.path.exists(os.path.join(src_dir, '.svn')): - sys.stdout.write("Not an SVN checkout.\n") - sys.exit(0) - -# Retrieve the CEF SVN info. -cef_info = get_svn_info(cef_dir) -if not options.quiet: - sys.stdout.write('Using CEF revision '+cef_info['revision']+' @ '+\ - cef_info['url']+"\n") - -# Retrieve the Chromium SVN info. -chromium_info = get_svn_info(src_dir) -if not options.quiet: - sys.stdout.write('Using Chromium revision '+chromium_info['revision']+' @ '+\ - chromium_info['url']+"\n") - -# Parse the compatibility file contents. -compat_file = os.path.join(cef_dir, 'CHROMIUM_BUILD_COMPATIBILITY.txt') -config = eval(read_file(compat_file), {'__builtins__': None}, None) - -error = False - -if 'release_url' in config: - current_release_url = None - path = os.path.join(os.path.join(src_dir, os.pardir), '.gclient') - if os.path.exists(path): - # read the .gclient file - fp = open(path, 'r') - data = fp.read() - fp.close() - - # Parse the contents - config_dict = {} - try: - exec(data, config_dict) - current_release_url = config_dict['solutions'][0]['url'] - except Exception, e: - sys.stderr.write('Failed to parse existing .glient file.\n') - raise - - if not options.quiet: - sys.stdout.write('Using Chromium release '+current_release_url+"\n") - - if current_release_url != config['release_url']: - error = True - sys.stderr.write("\nWARNING: Incorrect Chromium release URL; found "+\ - current_release_url+', expected '+config['release_url']+"\n") -else: - if chromium_info['url'] != config['chromium_url']: - error = True - sys.stderr.write("\nWARNING: Incorrect Chromium URL; found "+\ - chromium_info['url']+', expected '+config['chromium_url']+"\n") - - if chromium_info['revision'] != config['chromium_revision']: - error = True - sys.stderr.write("\nWARNING: Incorrect Chromium revision; found "+\ - chromium_info['revision']+', expected '+config['chromium_revision']+"\n") - -if error: - sys.stderr.write("\nPlease see CHROMIUM_BUILD_COMPATIBILITY.txt for "\ - "instructions.\n") diff --git a/tools/gclient_hook.py b/tools/gclient_hook.py index e62300ec6..ee288c990 100644 --- a/tools/gclient_hook.py +++ b/tools/gclient_hook.py @@ -9,10 +9,6 @@ import os, sys # The CEF root directory is the parent directory of _this_ script. cef_dir = os.path.abspath(os.path.join(os.path.dirname(__file__), os.pardir)) -print "\nChecking CEF and Chromium revisions..." -gyper = [ 'python', 'tools/check_revision.py' ] -RunAction(cef_dir, gyper) - print "\nGenerating CEF version header file..." gyper = [ 'python', 'tools/make_version_header.py', '--header', 'include/cef_version.h',