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

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

Issue 197693002: [Android] Lint build/android/gyp/. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: now using extra_paths_list to avoid F0401s Created 6 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/gyp/create_native_libraries_header.py ('k') | build/android/gyp/dex.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 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 """Combines stripped libraries and incomplete APK into single standalone APK. 7 """Combines stripped libraries and incomplete APK into single standalone APK.
8 8
9 """ 9 """
10 10
(...skipping 18 matching lines...) Expand all
29 shutil.copy(intermediate_path, options.output_apk_path) 29 shutil.copy(intermediate_path, options.output_apk_path)
30 30
31 input_paths = [options.input_apk_path, options.libraries_top_dir] 31 input_paths = [options.input_apk_path, options.libraries_top_dir]
32 record_path = '%s.standalone.stamp' % options.input_apk_path 32 record_path = '%s.standalone.stamp' % options.input_apk_path
33 md5_check.CallAndRecordIfStale( 33 md5_check.CallAndRecordIfStale(
34 DoZip, 34 DoZip,
35 record_path=record_path, 35 record_path=record_path,
36 input_paths=input_paths) 36 input_paths=input_paths)
37 37
38 38
39 def main(argv): 39 def main():
40 parser = optparse.OptionParser() 40 parser = optparse.OptionParser()
41 parser.add_option('--libraries-top-dir', 41 parser.add_option('--libraries-top-dir',
42 help='Top directory that contains libraries ' 42 help='Top directory that contains libraries '
43 '(i.e. library paths are like ' 43 '(i.e. library paths are like '
44 'libraries_top_dir/lib/android_app_abi/foo.so).') 44 'libraries_top_dir/lib/android_app_abi/foo.so).')
45 parser.add_option('--input-apk-path', help='Path to incomplete APK.') 45 parser.add_option('--input-apk-path', help='Path to incomplete APK.')
46 parser.add_option('--output-apk-path', help='Path for standalone APK.') 46 parser.add_option('--output-apk-path', help='Path for standalone APK.')
47 parser.add_option('--stamp', help='Path to touch on success.') 47 parser.add_option('--stamp', help='Path to touch on success.')
48 options, _ = parser.parse_args() 48 options, _ = parser.parse_args()
49 49
50 required_options = ['libraries_top_dir', 'input_apk_path', 'output_apk_path'] 50 required_options = ['libraries_top_dir', 'input_apk_path', 'output_apk_path']
51 build_utils.CheckOptions(options, parser, required=required_options) 51 build_utils.CheckOptions(options, parser, required=required_options)
52 52
53 CreateStandaloneApk(options) 53 CreateStandaloneApk(options)
54 54
55 if options.stamp: 55 if options.stamp:
56 build_utils.Touch(options.stamp) 56 build_utils.Touch(options.stamp)
57 57
58 58
59 if __name__ == '__main__': 59 if __name__ == '__main__':
60 sys.exit(main(sys.argv)) 60 sys.exit(main())
OLDNEW
« no previous file with comments | « build/android/gyp/create_native_libraries_header.py ('k') | build/android/gyp/dex.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698