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

Side by Side Diff: build/android/strip_library_for_apk.py

Issue 12853002: Convert java library javac/jar to python (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 7 years, 9 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/pylib/build_utils.py ('k') | build/java.gypi » ('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 2013 The Chromium Authors. All rights reserved. 3 # Copyright 2013 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 import optparse 7 import optparse
8 import os 8 import os
9 import subprocess 9 import subprocess
10 import sys 10 import sys
(...skipping 13 matching lines...) Expand all
24 24
25 parser.add_option('--android-strip', 25 parser.add_option('--android-strip',
26 help='Path to the toolchain\'s strip binary') 26 help='Path to the toolchain\'s strip binary')
27 parser.add_option('--android-strip-arg', action='append', 27 parser.add_option('--android-strip-arg', action='append',
28 help='Argument to be passed to strip') 28 help='Argument to be passed to strip')
29 parser.add_option('--stripped-libraries-dir', 29 parser.add_option('--stripped-libraries-dir',
30 help='Directory for stripped libraries') 30 help='Directory for stripped libraries')
31 31
32 options, paths = parser.parse_args() 32 options, paths = parser.parse_args()
33 33
34 build_utils.EnsureDirectoryExists(options.stripped_libraries_dir) 34 build_utils.MakeDirectory(options.stripped_libraries_dir)
35 35
36 for library_path in paths: 36 for library_path in paths:
37 stripped_library_path = os.path.join(options.stripped_libraries_dir, 37 stripped_library_path = os.path.join(options.stripped_libraries_dir,
38 os.path.basename(library_path)) 38 os.path.basename(library_path))
39 StripLibrary(options.android_strip, options.android_strip_arg, library_path, 39 StripLibrary(options.android_strip, options.android_strip_arg, library_path,
40 stripped_library_path) 40 stripped_library_path)
41 41
42 42
43 if __name__ == '__main__': 43 if __name__ == '__main__':
44 sys.exit(main(sys.argv)) 44 sys.exit(main(sys.argv))
OLDNEW
« no previous file with comments | « build/android/pylib/build_utils.py ('k') | build/java.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698