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

Unified Diff: build/android/gyp/pack_arm_relocations.py

Issue 456493002: Add native libraries to gn apks (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 6 years, 4 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « build/android/gyp/gcc_preprocess.py ('k') | build/android/gyp/push_libraries.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/gyp/pack_arm_relocations.py
diff --git a/build/android/gyp/pack_arm_relocations.py b/build/android/gyp/pack_arm_relocations.py
index 54d63d7a0b0b86c8f4a48225e67c6c367db43ee2..d650927ac858ffbd8b115efe787b8a48b5538b32 100755
--- a/build/android/gyp/pack_arm_relocations.py
+++ b/build/android/gyp/pack_arm_relocations.py
@@ -21,7 +21,6 @@ irrespective of any --enable-packing setting. Typically this would be
'libchromium_android_linker.so'.
"""
-import json
import optparse
import os
import shlex
@@ -59,7 +58,8 @@ def CopyArmLibraryUnchanged(library_path, output_path):
shutil.copy(library_path, output_path)
-def main():
+def main(args):
+ args = build_utils.ExpandFileArgs(args)
parser = optparse.OptionParser()
parser.add_option('--configuration-name',
@@ -80,17 +80,16 @@ def main():
help='Directory for stripped libraries')
parser.add_option('--packed-libraries-dir',
help='Directory for packed libraries')
- parser.add_option('--libraries-file',
- help='Path to json file containing list of libraries')
+ parser.add_option('--libraries',
+ help='List of libraries')
parser.add_option('--stamp', help='Path to touch on success')
- options, _ = parser.parse_args()
+ options, _ = parser.parse_args(args)
enable_packing = (options.enable_packing == '1' and
options.configuration_name == 'Release')
exclude_packing_set = set(shlex.split(options.exclude_packing_list))
- with open(options.libraries_file, 'r') as libfile:
- libraries = json.load(libfile)
+ libraries = build_utils.ParseGypList(options.libraries)
build_utils.MakeDirectory(options.packed_libraries_dir)
@@ -113,4 +112,4 @@ def main():
if __name__ == '__main__':
- sys.exit(main())
+ sys.exit(main(sys.argv[1:]))
« no previous file with comments | « build/android/gyp/gcc_preprocess.py ('k') | build/android/gyp/push_libraries.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698