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

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

Issue 269943005: Add android_library template (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 6 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
Index: build/android/gyp/jar_toc.py
diff --git a/build/android/gyp/jar_toc.py b/build/android/gyp/jar_toc.py
index 1122f683c9e3b1cceae187da3aebbb781ca1bda9..d8febfb43faf1e4910febfde6c71266d44c435a5 100755
--- a/build/android/gyp/jar_toc.py
+++ b/build/android/gyp/jar_toc.py
@@ -18,6 +18,7 @@ rebuild, will have a corresponding change in the TOC file.
"""
import optparse
+import os
import re
import sys
import zipfile
@@ -86,18 +87,26 @@ def DoJarToc(options):
lambda: UpdateToc(jar_path, toc_path),
record_path=record_path,
input_paths=[jar_path],
+ force=not os.path.exists(jar_path),
)
- build_utils.Touch(toc_path)
+ build_utils.Touch(toc_path, fail_if_missing=True)
def main():
parser = optparse.OptionParser()
+ parser.add_option("--depfile")
+
parser.add_option('--jar-path', help='Input .jar path.')
parser.add_option('--toc-path', help='Output .jar.TOC path.')
parser.add_option('--stamp', help='Path to touch on success.')
options, _ = parser.parse_args()
+ if options.depfile:
+ build_utils.WriteDepfile(
+ options.depfile,
+ build_utils.GetPythonDependencies())
Nico 2014/05/05 22:08:10 same question as in the other file
cjhopman 2014/06/25 01:20:03 N/A.
+
DoJarToc(options)
if options.stamp:

Powered by Google App Engine
This is Rietveld 408576698