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

Side by Side Diff: third_party/android_platform/development/scripts/stack

Issue 1670223002: Android's stack script: Make --output-dir / CHROMIUM_OUTPUT_DIR mandatory (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@output-dir-stack
Patch Set: more freom prev cl Created 4 years, 10 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
« no previous file with comments | « build/android/tombstones.py ('k') | no next file » | 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) 2013 The Android Open Source Project 3 # Copyright (C) 2013 The Android Open Source Project
4 # 4 #
5 # Licensed under the Apache License, Version 2.0 (the "License"); 5 # Licensed under the Apache License, Version 2.0 (the "License");
6 # you may not use this file except in compliance with the License. 6 # you may not use this file except in compliance with the License.
7 # You may obtain a copy of the License at 7 # You may obtain a copy of the License at
8 # 8 #
9 # http://www.apache.org/licenses/LICENSE-2.0 9 # http://www.apache.org/licenses/LICENSE-2.0
10 # 10 #
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 packed_relocation_adjustments = True 179 packed_relocation_adjustments = True
180 elif option == "--no-packed-relocation-adjustments": 180 elif option == "--no-packed-relocation-adjustments":
181 packed_relocation_adjustments = False 181 packed_relocation_adjustments = False
182 elif option == "--more-info": 182 elif option == "--more-info":
183 more_info = True 183 more_info = True
184 elif option == "--less-info": 184 elif option == "--less-info":
185 more_info = False 185 more_info = False
186 elif option == "--verbose": 186 elif option == "--verbose":
187 logging.basicConfig(level=logging.DEBUG) 187 logging.basicConfig(level=logging.DEBUG)
188 188
189 if symbol.CHROME_SYMBOLS_DIR and not chrome_apk_dir:
190 chrome_apk_dir = os.path.join(symbol.CHROME_SYMBOLS_DIR,
191 '..', DEFAULT_APK_DIR)
192
193 if len(arguments) > 1: 189 if len(arguments) > 1:
194 PrintUsage() 190 PrintUsage()
195 191
192 # Do an up-front test that the output directory is known.
193 if not symbol.CHROME_SYMBOLS_DIR:
194 constants.CheckOutputDirectory()
195
196 if not chrome_apk_dir:
197 # TODO(agrieve): This directory doesn't exist with GN.
198 probable_dir = os.path.join(constants.GetOutDirectory(), DEFAULT_APK_DIR)
199 if os.path.exists(probable_dir):
200 chrome_apk_dir = probable_dir
201
196 if not arguments or arguments[0] == "-": 202 if not arguments or arguments[0] == "-":
197 print "Reading native crash info from stdin" 203 print "Reading native crash info from stdin"
198 f = sys.stdin 204 f = sys.stdin
199 else: 205 else:
200 print "Searching for native crashes in: " + os.path.realpath(arguments[0]) 206 print "Searching for native crashes in: " + os.path.realpath(arguments[0])
201 f = open(arguments[0], "r") 207 f = open(arguments[0], "r")
202 208
203 lines = f.readlines() 209 lines = f.readlines()
204 f.close() 210 f.close()
205 211
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
245 if rootdir: 251 if rootdir:
246 # be a good citizen and clean up...os.rmdir and os.removedirs() don't work 252 # be a good citizen and clean up...os.rmdir and os.removedirs() don't work
247 cmd = "rm -rf \"%s\"" % rootdir 253 cmd = "rm -rf \"%s\"" % rootdir
248 print "\ncleaning up (%s)" % cmd 254 print "\ncleaning up (%s)" % cmd
249 os.system(cmd) 255 os.system(cmd)
250 256
251 if __name__ == "__main__": 257 if __name__ == "__main__":
252 sys.exit(main(sys.argv[1:])) 258 sys.exit(main(sys.argv[1:]))
253 259
254 # vi: ts=2 sw=2 260 # vi: ts=2 sw=2
OLDNEW
« no previous file with comments | « build/android/tombstones.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698