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

Unified Diff: build/android/javac.py

Issue 12702017: [Android] Make build output a little quieter. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | build/java.gypi » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: build/android/javac.py
diff --git a/build/android/javac.py b/build/android/javac.py
index 1ba5d064f8d18a5ee86c12aa1b5e996b41ddc52f..6117a5758caa73bfb173baecdecb7e29ef023fed 100755
--- a/build/android/javac.py
+++ b/build/android/javac.py
@@ -41,16 +41,23 @@ def DoJavac(options):
build_utils.DeleteDirectory(output_dir)
build_utils.MakeDirectory(output_dir)
- subprocess.check_call([
+ cmd = [
'javac',
'-g',
- '-Xlint:unchecked',
'-source', '1.5',
'-target', '1.5',
'-classpath', ':'.join(classpath),
- '-d', output_dir] +
- java_files)
+ '-d', output_dir]
+ # Only output Java warnings for chromium code
+ if options.chromium_code:
+ cmd += ['-Xlint:unchecked']
+ else:
+ cmd += [# Suppress "Sun proprietary API" warnings. See:
+ # http://stackoverflow.com/questions/1136659/how-can-i-suppress-java-compiler-warnings-about-sun-proprietary-api
+ '-XDignore.symbol.file']
+
+ subprocess.check_call(cmd + java_files)
def main(argv):
parser = optparse.OptionParser()
@@ -61,6 +68,9 @@ def main(argv):
parser.add_option('--classpath', help='Classpath for javac.')
parser.add_option('--output-dir', help='Directory for javac output.')
parser.add_option('--stamp', help='Path to touch on success.')
+ parser.add_option('--chromium-code', type='int', help='Whether code being'
cjhopman 2013/04/01 20:33:13 Nit: space at end of string
+ 'compiled should be built with stricter warnings for '
+ 'chromium code.')
# TODO(newt): remove this once http://crbug.com/177552 is fixed in ninja.
parser.add_option('--ignore', help='Ignored.')
« no previous file with comments | « no previous file | build/java.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698