| Index: build/android/gyp/write_build_config.py
|
| diff --git a/build/android/gyp/write_build_config.py b/build/android/gyp/write_build_config.py
|
| index 6c29b8957c6fc89a79138c48acae32e04e9e0e96..3a529afaa4fe00ff6ce9c54dca3941473b0246f4 100755
|
| --- a/build/android/gyp/write_build_config.py
|
| +++ b/build/android/gyp/write_build_config.py
|
| @@ -291,6 +291,10 @@ def main(argv):
|
| help='Whether this library should be treated as a prebuilt library by '
|
| 'generate_gradle.py.')
|
| parser.add_option('--main-class', help='Java class for java_binary targets.')
|
| + parser.add_option('--java-resources-jar-path',
|
| + help='Path to JAR that contains java resources. Everything '
|
| + 'from this JAR except meta-inf/ content and .class files '
|
| + 'will be added to the final APK.')
|
|
|
| # android library options
|
| parser.add_option('--dex-path', help='Path to target\'s dex output.')
|
| @@ -677,6 +681,20 @@ def main(argv):
|
| config['uncompressed_locales_java_list'] = (
|
| _CreateLocalePaksAssetJavaList(config['uncompressed_assets']))
|
|
|
| + # Collect java resources
|
| + java_resources_jars = [d['java_resources_jar'] for d in all_library_deps
|
| + if 'java_resources_jar' in d]
|
| + if options.tested_apk_config:
|
| + tested_apk_resource_jars = [d['java_resources_jar']
|
| + for d in tested_apk_library_deps
|
| + if 'java_resources_jar' in d]
|
| + java_resources_jars = [jar for jar in java_resources_jars
|
| + if jar not in tested_apk_resource_jars]
|
| + config['java_resources_jars'] = java_resources_jars
|
| +
|
| + if options.type == 'java_library' and options.java_resources_jar_path:
|
| + deps_info['java_resources_jar'] = options.java_resources_jar_path
|
| +
|
| build_utils.WriteJson(config, options.build_config, only_if_changed=True)
|
|
|
| if options.depfile:
|
|
|