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

Side by Side Diff: mojo/devtools/common/debugger

Issue 1250003005: Fix ADB path passing to GDB in devtools (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 5 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 | « no previous file | 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 # Copyright 2014 The Chromium Authors. All rights reserved. 2 # Copyright 2014 The Chromium Authors. All rights reserved.
3 # Use of this source code is governed by a BSD-style license that can be 3 # Use of this source code is governed by a BSD-style license that can be
4 # found in the LICENSE file. 4 # found in the LICENSE file.
5 5
6 import argparse 6 import argparse
7 import codecs 7 import codecs
8 import logging 8 import logging
9 import os.path 9 import os.path
10 import requests 10 import requests
(...skipping 204 matching lines...) Expand 10 before | Expand all | Expand 10 after
215 raise DirectoryNotFoundException() 215 raise DirectoryNotFoundException()
216 except DirectoryNotFoundException: 216 except DirectoryNotFoundException:
217 logging.fatal("Unable to find the build directory, please specify it " 217 logging.fatal("Unable to find the build directory, please specify it "
218 "using --build-dir.") 218 "using --build-dir.")
219 return 219 return
220 220
221 if args.package_name: 221 if args.package_name:
222 debug_session_arguments["package_name"] = args.package_name 222 debug_session_arguments["package_name"] = args.package_name
223 else: 223 else:
224 debug_session_arguments["package_name"] = _DEFAULT_PACKAGE_NAME 224 debug_session_arguments["package_name"] = _DEFAULT_PACKAGE_NAME
225 if args.adb_path:
226 debug_session_arguments['adb'] = args.adb_path
225 if args.pyelftools_dir: 227 if args.pyelftools_dir:
226 debug_session_arguments["pyelftools_dir"] = args.pyelftools_dir 228 debug_session_arguments["pyelftools_dir"] = args.pyelftools_dir
227 else: 229 else:
228 debug_session_arguments["pyelftools_dir"] = os.path.join( 230 debug_session_arguments["pyelftools_dir"] = os.path.join(
229 _get_dir_above('third_party'), 'third_party', 'pyelftools') 231 _get_dir_above('third_party'), 'third_party', 'pyelftools')
230 232
231 debug_session_arguments_str = ', '.join( 233 debug_session_arguments_str = ', '.join(
232 [k + '="' + codecs.encode(v, 'string_escape') + '"' 234 [k + '="' + codecs.encode(v, 'string_escape') + '"'
233 for k, v in debug_session_arguments.items()]) 235 for k, v in debug_session_arguments.items()])
234 236
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
301 _add_device_command(subparsers) 303 _add_device_command(subparsers)
302 _add_tracing_command(subparsers) 304 _add_tracing_command(subparsers)
303 _add_wm_command(subparsers) 305 _add_wm_command(subparsers)
304 _add_gdb_command(subparsers) 306 _add_gdb_command(subparsers)
305 307
306 args = parser.parse_args() 308 args = parser.parse_args()
307 return args.func(args) 309 return args.func(args)
308 310
309 if __name__ == '__main__': 311 if __name__ == '__main__':
310 sys.exit(main()) 312 sys.exit(main())
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698