Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(534)

Side by Side Diff: build/android/gyp/process_resources.py

Issue 13473017: CheckCallDie: add option to suppress successful output (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: :/ Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « build/android/gyp/javac.py ('k') | build/android/gyp/push_libraries.py » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 #!/usr/bin/env python 1 #!/usr/bin/env python
2 # 2 #
3 # Copyright (c) 2012 The Chromium Authors. All rights reserved. 3 # Copyright (c) 2012 The Chromium Authors. All rights reserved.
4 # Use of this source code is governed by a BSD-style license that can be 4 # Use of this source code is governed by a BSD-style license that can be
5 # found in the LICENSE file. 5 # found in the LICENSE file.
6 6
7 """Process Android library resources to generate R.java and crunched images.""" 7 """Process Android library resources to generate R.java and crunched images."""
8 8
9 import optparse 9 import optparse
10 import os 10 import os
11 import shlex 11 import shlex
12 12
13 from pylib import build_utils 13 from util import build_utils
14 14
15 def ParseArgs(): 15 def ParseArgs():
16 """Parses command line options. 16 """Parses command line options.
17 17
18 Returns: 18 Returns:
19 An options object as from optparse.OptionsParser.parse_args() 19 An options object as from optparse.OptionsParser.parse_args()
20 """ 20 """
21 parser = optparse.OptionParser() 21 parser = optparse.OptionParser()
22 parser.add_option('--android-sdk', help='path to the Android SDK folder') 22 parser.add_option('--android-sdk', help='path to the Android SDK folder')
23 parser.add_option('--android-sdk-tools', 23 parser.add_option('--android-sdk-tools',
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 build_utils.CheckCallDie(package_command) 80 build_utils.CheckCallDie(package_command)
81 81
82 # Crunch image resources. This shrinks png files and is necessary for 9-patch 82 # Crunch image resources. This shrinks png files and is necessary for 9-patch
83 # images to display correctly. 83 # images to display correctly.
84 build_utils.MakeDirectory(options.crunch_output_dir) 84 build_utils.MakeDirectory(options.crunch_output_dir)
85 85
86 aapt_cmd = [aapt, 86 aapt_cmd = [aapt,
87 'crunch', 87 'crunch',
88 '-S', options.crunch_input_dir, 88 '-S', options.crunch_input_dir,
89 '-C', options.crunch_output_dir] 89 '-C', options.crunch_output_dir]
90 build_utils.CheckCallDie(aapt_cmd) 90 build_utils.CheckCallDie(aapt_cmd, suppress_output=True)
91 91
92 if options.stamp: 92 if options.stamp:
93 build_utils.Touch(options.stamp) 93 build_utils.Touch(options.stamp)
94 94
95 95
96 if __name__ == '__main__': 96 if __name__ == '__main__':
97 main() 97 main()
OLDNEW
« no previous file with comments | « build/android/gyp/javac.py ('k') | build/android/gyp/push_libraries.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698