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

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

Issue 2014983003: [Android] Build changes needed for Robolectric 3.0. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Fixed agrieves nit and mispelling. Created 4 years, 7 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/jar.py ('k') | build/config/android/internal_rules.gni » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/gyp/javac.py
diff --git a/build/android/gyp/javac.py b/build/android/gyp/javac.py
index 5722fb1d97a72dfbd63d8b9d1d94c5f7ca69c62e..3cce16dfb5b24caa3c9e0172be8aee89e9c9fa32 100755
--- a/build/android/gyp/javac.py
+++ b/build/android/gyp/javac.py
@@ -228,10 +228,12 @@ def _OnStaleMd5(changes, options, javac_cmd, java_files, classpath_inputs):
jar.JarDirectory(classes_dir,
options.jar_path,
- predicate=inclusion_predicate)
+ predicate=inclusion_predicate,
+ provider_configurations=options.provider_configurations)
jar.JarDirectory(classes_dir,
excluded_jar_path,
- predicate=exclusion_predicate)
+ predicate=exclusion_predicate,
+ provider_configurations=options.provider_configurations)
def _ParseOptions(argv):
@@ -272,6 +274,22 @@ def _ParseOptions(argv):
default='',
help='List of .class file patterns to exclude from the jar.')
parser.add_option(
+ '--processor',
+ dest='processors',
+ action='append',
+ help='Annotation processor to use.')
+ parser.add_option(
+ '--processor-arg',
+ dest='processor_args',
+ action='append',
+ help='key=value arguments for the annotation processors.')
+ parser.add_option(
+ '--provider-configuration',
+ dest='provider_configurations',
+ action='append',
+ help='File to specify a service provider. Will be included '
+ 'in the jar under META-INF/services.')
+ parser.add_option(
'--chromium-code',
type='int',
help='Whether code being compiled should be built with stricter '
@@ -350,6 +368,12 @@ def main(argv):
# trigger a compile warning or error.
javac_cmd.extend(['-XDignore.symbol.file'])
+ if options.processors:
+ javac_cmd.extend(['-processor', ','.join(options.processors)])
+ if options.processor_args:
+ for arg in options.processor_args:
+ javac_cmd.extend(['-A%s' % arg])
+
classpath_inputs = options.bootclasspath
if options.classpath:
if options.classpath[0].endswith('.interface.jar'):
« no previous file with comments | « build/android/gyp/jar.py ('k') | build/config/android/internal_rules.gni » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698