OLD | NEW |
1 #!/usr/bin/env python | 1 #!/usr/bin/env python |
2 # Copyright 2016 The Chromium Authors. All rights reserved. | 2 # Copyright 2016 The Chromium Authors. All rights reserved. |
3 # Use of this source code is governed by a BSD-style license that can be | 3 # Use of this source code is governed by a BSD-style license that can be |
4 # found in the LICENSE file. | 4 # found in the LICENSE file. |
5 | 5 |
6 """Generates an Android Studio project from a GN target.""" | 6 """Generates an Android Studio project from a GN target.""" |
7 | 7 |
8 import argparse | 8 import argparse |
9 import codecs | 9 import codecs |
10 import glob | 10 import glob |
(...skipping 26 matching lines...) Expand all Loading... |
37 _RES_SUBDIR = 'extracted-res' | 37 _RES_SUBDIR = 'extracted-res' |
38 _GRADLE_BUILD_FILE = 'build.gradle' | 38 _GRADLE_BUILD_FILE = 'build.gradle' |
39 # This needs to come first alphabetically among all modules. | 39 # This needs to come first alphabetically among all modules. |
40 _MODULE_ALL = '_all' | 40 _MODULE_ALL = '_all' |
41 | 41 |
42 _DEFAULT_TARGETS = [ | 42 _DEFAULT_TARGETS = [ |
43 # TODO(agrieve): .build_config seem not quite right for this target | 43 # TODO(agrieve): .build_config seem not quite right for this target |
44 # because it has resources as deps of android_apk() rather than using an | 44 # because it has resources as deps of android_apk() rather than using an |
45 # android_library() intermediate target. | 45 # android_library() intermediate target. |
46 # '//android_webview:system_webview_apk', | 46 # '//android_webview:system_webview_apk', |
47 '//android_webview/test:android_webview_apk', | 47 '//android_webview/test:webview_instrumentation_apk', |
48 '//android_webview/test:android_webview_test_apk', | 48 '//android_webview/test:webview_instrumentation_test_apk', |
49 '//base:base_junit_tests', | 49 '//base:base_junit_tests', |
50 '//chrome/android:chrome_junit_tests', | 50 '//chrome/android:chrome_junit_tests', |
51 '//chrome/android:chrome_public_apk', | 51 '//chrome/android:chrome_public_apk', |
52 '//chrome/android:chrome_public_test_apk', | 52 '//chrome/android:chrome_public_test_apk', |
53 '//chrome/android:chrome_sync_shell_apk', | 53 '//chrome/android:chrome_sync_shell_apk', |
54 '//chrome/android:chrome_sync_shell_test_apk', | 54 '//chrome/android:chrome_sync_shell_test_apk', |
55 '//content/public/android:content_junit_tests', | 55 '//content/public/android:content_junit_tests', |
56 '//content/shell/android:content_shell_apk', | 56 '//content/shell/android:content_shell_apk', |
57 ] | 57 ] |
58 | 58 |
(...skipping 733 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
792 _ExtractZips(generator.project_dir, zip_tuples) | 792 _ExtractZips(generator.project_dir, zip_tuples) |
793 | 793 |
794 logging.warning('Project created! (%d subprojects)', len(project_entries)) | 794 logging.warning('Project created! (%d subprojects)', len(project_entries)) |
795 logging.warning('Generated projects work with Android Studio 2.3') | 795 logging.warning('Generated projects work with Android Studio 2.3') |
796 logging.warning('For more tips: https://chromium.googlesource.com/chromium' | 796 logging.warning('For more tips: https://chromium.googlesource.com/chromium' |
797 '/src.git/+/master/docs/android_studio.md') | 797 '/src.git/+/master/docs/android_studio.md') |
798 | 798 |
799 | 799 |
800 if __name__ == '__main__': | 800 if __name__ == '__main__': |
801 main() | 801 main() |
OLD | NEW |