summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorandrewhayden@chromium.org <andrewhayden@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-29 10:35:52 +0000
committerandrewhayden@chromium.org <andrewhayden@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2014-07-29 10:35:52 +0000
commitac9f06523fc3e7790e4c6035b8ee71257f2fbcae (patch)
tree988b037a2fefe482d9f8d88829a1649105155f3c
parentfa188b0bccc95071851ec68dd9b71cb32ee95f01 (diff)
downloadchromium_src-ac9f06523fc3e7790e4c6035b8ee71257f2fbcae.zip
chromium_src-ac9f06523fc3e7790e4c6035b8ee71257f2fbcae.tar.gz
chromium_src-ac9f06523fc3e7790e4c6035b8ee71257f2fbcae.tar.bz2
Separate the chrome_shell Android targets like we do for content_shell
This is necessary in order to allow the 'all' targets on bots to link the chrome_shell libraries with different gyp variables than the android 'core' libraries. This is necessary in order to allow features that are not "shell-friendly" to be toggled in the core Android libraries without ALSO toggled simultaneously in the chrome_shell libraries. BUG=367239 TBR=simonb Review URL: https://codereview.chromium.org/422913002 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@286161 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r--chrome/chrome_android.gypi111
-rw-r--r--chrome/chrome_shell.gypi111
2 files changed, 119 insertions, 103 deletions
diff --git a/chrome/chrome_android.gypi b/chrome/chrome_android.gypi
index 6fdd27a..a1ec31a 100644
--- a/chrome/chrome_android.gypi
+++ b/chrome/chrome_android.gypi
@@ -4,99 +4,20 @@
{
'variables': {
'chromium_code': 1,
- 'package_name': 'chrome_shell_apk',
+ 'conditions': [
+ ['component != "shared_library" and target_arch != "arm64" and target_arch != "x64" and profiling_full_stack_frames != 1', {
+ # Only enable the chromium linker on regular builds, since the
+ # component build crashes on Android 4.4. See b/11379966
+ 'use_chromium_linker': '1',
+ }],
+ ],
},
'includes': [
'chrome_android_paks.gypi', # Included for the list of pak resources.
+ 'chrome_shell.gypi', # Built atop chrome_android_core (defined here)
],
'targets': [
{
- 'target_name': 'libchromeshell',
- 'type': 'shared_library',
- 'dependencies': [
- '../base/base.gyp:base',
- 'chrome_android_core',
- 'chrome.gyp:browser_ui',
- '../content/content.gyp:content_app_browser',
- ],
- 'sources': [
- # This file must always be included in the shared_library step to ensure
- # JNI_OnLoad is exported.
- 'app/android/chrome_jni_onload.cc',
- 'android/shell/chrome_main_delegate_chrome_shell_android.cc',
- 'android/shell/chrome_main_delegate_chrome_shell_android.h',
- "android/shell/chrome_shell_google_location_settings_helper.cc",
- "android/shell/chrome_shell_google_location_settings_helper.h",
- ],
- 'include_dirs': [
- '../skia/config',
- ],
- 'conditions': [
- [ 'order_profiling!=0', {
- 'conditions': [
- [ 'OS=="android"', {
- 'dependencies': [ '../tools/cygprofile/cygprofile.gyp:cygprofile', ],
- }],
- ],
- }],
- [ 'use_allocator!="none"', {
- 'dependencies': [
- '../base/allocator/allocator.gyp:allocator', ],
- }],
- ['OS=="android"', {
- 'ldflags': [
- # Some android targets still depend on --gc-sections to link.
- # TODO: remove --gc-sections for Debug builds (crbug.com/159847).
- '-Wl,--gc-sections',
- ],
- }],
- ],
- },
- {
- 'target_name': 'chrome_shell_apk',
- 'type': 'none',
- 'dependencies': [
- 'chrome_java',
- 'chrome_shell_paks',
- 'libchromeshell',
- '../media/media.gyp:media_java',
- ],
- 'variables': {
- 'apk_name': 'ChromeShell',
- 'manifest_package_name': 'org.chromium.chrome.shell',
- 'java_in_dir': 'android/shell/java',
- 'resource_dir': 'android/shell/res',
- 'asset_location': '<(PRODUCT_DIR)/../assets/<(package_name)',
- 'native_lib_target': 'libchromeshell',
- 'native_lib_version_name': '<(version_full)',
- 'additional_input_paths': [
- '<@(chrome_android_pak_output_resources)',
- ],
- 'conditions': [
- ['component != "shared_library" and target_arch != "arm64" and target_arch != "x64" and profiling_full_stack_frames != 1', {
- # Only enable the chromium linker on regular builds, since the
- # component build crashes on Android 4.4. See b/11379966
- 'use_chromium_linker': '1',
- }],
- ],
- },
- 'includes': [ '../build/java_apk.gypi', ],
- },
- {
- # chrome_shell_apk creates a .jar as a side effect. Any java targets
- # that need that .jar in their classpath should depend on this target,
- # chrome_shell_apk_java. Dependents of chrome_shell_apk receive its
- # jar path in the variable 'apk_output_jar_path'.
- # This target should only be used by targets which instrument
- # chrome_shell_apk.
- 'target_name': 'chrome_shell_apk_java',
- 'type': 'none',
- 'dependencies': [
- 'chrome_shell_apk',
- ],
- 'includes': [ '../build/apk_fake_jar.gypi' ],
- },
- {
'target_name': 'chrome_android_core',
'type': 'static_library',
'dependencies': [
@@ -130,21 +51,5 @@
],
},
},
- {
- 'target_name': 'chrome_shell_paks',
- 'type': 'none',
- 'dependencies': [
- '<(DEPTH)/chrome/chrome_resources.gyp:packed_resources',
- '<(DEPTH)/chrome/chrome_resources.gyp:packed_extra_resources',
- ],
- 'copies': [
- {
- 'destination': '<(chrome_android_pak_output_folder)',
- 'files': [
- '<@(chrome_android_pak_input_resources)',
- ],
- }
- ],
- },
],
}
diff --git a/chrome/chrome_shell.gypi b/chrome/chrome_shell.gypi
new file mode 100644
index 0000000..686caf5
--- /dev/null
+++ b/chrome/chrome_shell.gypi
@@ -0,0 +1,111 @@
+# Copyright 2014 The Chromium Authors. All rights reserved.
+# Use of this source code is governed by a BSD-style license that can be
+# found in the LICENSE file.
+
+# This GYPI allows independent customization of the chrome shell in a manner
+# similar to content shell (in content_shell.gypi). Notably, this file does
+# NOT contain chrome_android_core, which is independent of the chrome shell
+# and should be separately customized.
+{
+ 'variables': {
+ 'apk_name': 'ChromeShell',
+ 'manifest_package_name': 'org.chromium.chrome.shell',
+ 'native_lib_version_name': '<(version_full)',
+ 'package_name': 'chrome_shell_apk',
+ },
+ 'targets': [
+ {
+ 'target_name': 'libchromeshell',
+ 'type': 'shared_library',
+ 'dependencies': [
+ '../base/base.gyp:base',
+ 'chrome_android_core',
+ 'chrome.gyp:browser_ui',
+ '../content/content.gyp:content_app_browser',
+ ],
+ 'sources': [
+ # This file must always be included in the shared_library step to ensure
+ # JNI_OnLoad is exported.
+ 'app/android/chrome_jni_onload.cc',
+ 'android/shell/chrome_main_delegate_chrome_shell_android.cc',
+ 'android/shell/chrome_main_delegate_chrome_shell_android.h',
+ "android/shell/chrome_shell_google_location_settings_helper.cc",
+ "android/shell/chrome_shell_google_location_settings_helper.h",
+ ],
+ 'include_dirs': [
+ '../skia/config',
+ ],
+ 'conditions': [
+ [ 'order_profiling!=0', {
+ 'conditions': [
+ [ 'OS=="android"', {
+ 'dependencies': [ '../tools/cygprofile/cygprofile.gyp:cygprofile', ],
+ }],
+ ],
+ }],
+ [ 'use_allocator!="none"', {
+ 'dependencies': [
+ '../base/allocator/allocator.gyp:allocator', ],
+ }],
+ ['OS=="android"', {
+ 'ldflags': [
+ # Some android targets still depend on --gc-sections to link.
+ # TODO: remove --gc-sections for Debug builds (crbug.com/159847).
+ '-Wl,--gc-sections',
+ ],
+ }],
+ ],
+ },
+ {
+ 'target_name': 'chrome_shell_apk',
+ 'type': 'none',
+ 'dependencies': [
+ 'chrome_java',
+ 'chrome_shell_paks',
+ 'libchromeshell',
+ '../media/media.gyp:media_java',
+ ],
+ 'variables': {
+ 'java_in_dir': 'android/shell/java',
+ 'resource_dir': 'android/shell/res',
+ 'asset_location': '<(PRODUCT_DIR)/../assets/<(package_name)',
+ 'native_lib_target': 'libchromeshell',
+ 'additional_input_paths': [
+ '<@(chrome_android_pak_output_resources)',
+ ],
+ },
+ 'includes': [ '../build/java_apk.gypi', ],
+ },
+ {
+ # chrome_shell_apk creates a .jar as a side effect. Any java targets
+ # that need that .jar in their classpath should depend on this target,
+ # chrome_shell_apk_java. Dependents of chrome_shell_apk receive its
+ # jar path in the variable 'apk_output_jar_path'.
+ # This target should only be used by targets which instrument
+ # chrome_shell_apk.
+ 'target_name': 'chrome_shell_apk_java',
+ 'type': 'none',
+ 'dependencies': [
+ 'chrome_shell_apk',
+ ],
+ 'includes': [ '../build/apk_fake_jar.gypi' ],
+ },
+ {
+ 'target_name': 'chrome_shell_paks',
+ 'type': 'none',
+ 'dependencies': [
+ '<(DEPTH)/chrome/chrome_resources.gyp:packed_resources',
+ '<(DEPTH)/chrome/chrome_resources.gyp:packed_extra_resources',
+ ],
+ 'copies': [
+ {
+ 'destination': '<(chrome_android_pak_output_folder)',
+ 'files': [
+ '<@(chrome_android_pak_input_resources)',
+ ],
+ }
+ ],
+ },
+ ],
+
+}