mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Merge revision 1203 changes:
- Fix ninja build on all platforms (issue #922). - Update make_distrib.py to support ninja builds via a new "ninja-build" flag (issue #922). - Improvements to automate.py: -- Allow specification of the depot_tools directory via a "depot-tools" flag (issue #592). -- Add ninja build support via a "ninja-build" flag (issue #922). -- Allow relative paths for download directories (issue #942). -- Add the ability to print commands without executing them via a "dry-run" flag. -- Specifying the "force-clean" flag will also remove the build output directory. -- Add support for a minimal distribution mode where only release binaries and resources are packaged. git-svn-id: https://chromiumembedded.googlecode.com/svn/branches/1453@1204 5089003a-bbd8-11dd-ad1f-f1f9622dbc98
This commit is contained in:
@ -73,6 +73,17 @@ def copy_files(src_glob, dst_folder, quiet = True):
|
||||
else:
|
||||
copy_file(fname, dst, quiet)
|
||||
|
||||
def remove_file(name, quiet = True):
|
||||
""" Remove the specified file. """
|
||||
try:
|
||||
if path_exists(name):
|
||||
os.remove(name)
|
||||
if not quiet:
|
||||
sys.stdout.write('Removing '+name+' file.\n')
|
||||
except IOError, (errno, strerror):
|
||||
sys.stderr.write('Failed to remove file '+name+': '+strerror)
|
||||
raise
|
||||
|
||||
def copy_dir(src, dst, quiet = True):
|
||||
""" Copy a directory tree. """
|
||||
try:
|
||||
@ -109,3 +120,11 @@ def make_dir(name, quiet = True):
|
||||
def get_files(search_glob):
|
||||
""" Returns all files matching the search glob. """
|
||||
return iglob(search_glob)
|
||||
|
||||
def read_version_file(file, args):
|
||||
""" Read and parse a version file (key=value pairs, one per line). """
|
||||
lines = read_file(file).split("\n")
|
||||
for line in lines:
|
||||
parts = line.split('=', 1)
|
||||
if len(parts) == 2:
|
||||
args[parts[0]] = parts[1]
|
||||
|
Reference in New Issue
Block a user