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

Unified Diff: build/common.gypi

Issue 223143004: Add chromecast_build gyp variable and add rules when the variable is set to 1. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Enable ozone/embedded when chromecast == 1. Also add libgles2-mesa-dev as a dependency for chromeca… Created 6 years, 6 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/common.gypi
diff --git a/build/common.gypi b/build/common.gypi
index 166130c6e231d0f813b5d306ed1db1ff91661451..0a3ffd32b9d445fff4403fac6f6f39adfde8283a 100644
--- a/build/common.gypi
+++ b/build/common.gypi
@@ -21,6 +21,9 @@
# Whether we're building a ChromeOS build.
'chromeos%': 0,
+ # Whether we're building the cast (chromecast) shell
+ 'chromecast%': 0,
+
# Whether or not we are using the Aura windowing framework.
'use_aura%': 0,
@@ -43,10 +46,14 @@
}, {
'host_arch%': '<!pymod_do_main(detect_host_arch)',
}],
+ ['chromecast==1', {
+ 'embedded%': 1,
+ }],
],
},
# Copy conditionally-set variables out one scope.
'chromeos%': '<(chromeos)',
+ 'chromecast%': '<(chromecast)',
'use_aura%': '<(use_aura)',
'use_ash%': '<(use_ash)',
'use_cras%': '<(use_cras)',
@@ -126,6 +133,7 @@
},
# Copy conditionally-set variables out one scope.
'chromeos%': '<(chromeos)',
+ 'chromecast%': '<(chromecast)',
'desktop_linux%': '<(desktop_linux)',
'use_aura%': '<(use_aura)',
'use_ash%': '<(use_ash)',
@@ -237,6 +245,7 @@
# Copy conditionally-set variables out one scope.
'chromeos%': '<(chromeos)',
+ 'chromecast%': '<(chromecast)',
'host_arch%': '<(host_arch)',
'target_arch%': '<(target_arch)',
'target_subarch%': '<(target_subarch)',
@@ -707,9 +716,9 @@
}],
# Android OS includes support for proprietary codecs regardless of
- # building Chromium or Google Chrome. We also ship Google Chrome with
- # proprietary codecs.
- ['OS=="android" or branding=="Chrome"', {
+ # building Chromium or Google Chrome. We also ship Google Chrome and
+ # Chromecast with proprietary codecs.
+ ['OS=="android" or branding=="Chrome" or chromecast==1', {
'proprietary_codecs%': 1,
}, {
'proprietary_codecs%': 0,
@@ -923,10 +932,10 @@
}],
# By default, use ICU data file (icudtl.dat) on all platforms
- # except when building Android WebView.
+ # except when building Android WebView or Chromecast.
# TODO(jshin): Handle 'use_system_icu' on Linux (Chromium).
# Set the data reduction proxy origin for Android Webview.
- ['android_webview_build==0', {
+ ['android_webview_build==0 and chromecast==0', {
'icu_use_data_file_flag%' : 1,
'spdy_proxy_auth_origin%': '',
'data_reduction_proxy_probe_url%': '',
@@ -1028,6 +1037,7 @@
'use_gnome_keyring%': '<(use_gnome_keyring)',
'linux_fpic%': '<(linux_fpic)',
'chromeos%': '<(chromeos)',
+ 'chromecast%': '<(chromecast)',
'enable_viewport%': '<(enable_viewport)',
'enable_hidpi%': '<(enable_hidpi)',
'use_xi2_mt%':'<(use_xi2_mt)',
@@ -1747,6 +1757,19 @@
# Copy it out one scope.
'android_webview_build%': '<(android_webview_build)',
}], # OS=="android"
+ ['chromecast==1', {
+ 'ffmpeg_branding%': 'Chrome',
+ 'ozone_platform_ozonex%': 1,
rjkroege 2014/06/25 16:44:16 where is this platform?
spang 2014/06/25 16:53:28 This is a gyp hack to allow X dependencies in ozon
+ 'conditions': [
+ ['target_arch=="arm"', {
+ 'arm_arch%': '',
+ 'arm_tune%': 'cortex-a9',
+ 'arm_thumb%': 1,
+ 'enable_mpeg2ts_stream_parser%': 1,
+ 'video_hole%': 1,
+ }],
+ ],
+ }],
['android_webview_build==1', {
# When building the WebView in the Android tree, jarjar will remap all
# the class names, so the JNI generator needs to know this.
@@ -1874,7 +1897,7 @@
],
}],
- ['os_posix==1 and chromeos==0 and OS!="android" and OS!="ios"', {
+ ['os_posix==1 and chromeos==0 and OS!="android" and OS!="ios" and chromecast==0', {
rjkroege 2014/06/25 16:44:16 cups is for printing yes? I think you get this tur
lcwu1 2014/06/25 22:41:02 I don't think it is turned off when embedded==1. I
'use_cups%': 1,
}, {
'use_cups%': 0,
@@ -2283,6 +2306,8 @@
'component%': '<(component)',
+ 'chromecast%': '<(chromecast)',
+
# See http://msdn.microsoft.com/en-us/library/aa652360(VS.71).aspx
'win_release_Optimization%': '2', # 2 = /Os
'win_debug_Optimization%': '0', # 0 = /Od
@@ -2661,6 +2686,21 @@
}],
], # win_z7!=0
}], # OS==win
+ ['chromecast==1', {
+ 'defines': [
+ 'LOG_DISABLED=0',
rjkroege 2014/06/25 16:44:16 why?
lcwu1 2014/06/25 22:41:02 Because we don't want to disable all the logs from
+ ],
+ 'conditions': [
+ ['target_arch=="arm"', {
+ 'defines': [
+ # TODO(lcwu): Work around an error when building Chromium
rjkroege 2014/06/25 16:44:16 it would be a good idea to have a bug that goes wi
lcwu1 2014/06/25 22:41:02 Will create one.
+ # with gcc-4.5.3 (e.g. v8/src/platform-linux.cc). Remove
+ # this define once the toolchain is updated.
+ '__SOFTFP',
+ ],
+ }],
+ ],
+ }],
['enable_task_manager==1', {
'defines': [
'ENABLE_TASK_MANAGER=1',
@@ -3701,6 +3741,33 @@
}],
],
}],
+ ['chromecast==1', {
+ 'cflags': [
rjkroege 2014/06/25 16:44:16 this block would seem also be temporary? i.e. it c
lcwu1 2014/06/25 22:41:02 This block is not temporary. I only added this big
+ # We set arm_arch to "" so that -march compiler option
+ # is not set. Otherwise a gcc bug that would complain
+ # about it conflicting with '-mcpu=cortex-a9'. The flag
+ # '-march=armv7-a' is actually redundant anyway because
+ # it is enabled by default when we built the toolchain.
+ # And using '-mcpu=cortex-a9' should be sufficient.
+ '-mcpu=cortex-a9',
+ '-funwind-tables',
+ # Breakpad requires symbols with debugging information
+ '-g',
+ ],
+ 'ldflags': [
+ # We want to statically link libstdc++/libgcc_s.
+ '-static-libstdc++',
+ '-static-libgcc',
+ ],
+ 'cflags!': [
+ # Some components in Chromium (e.g. v8, skia, ffmpeg)
+ # define their own cflags for arm builds that could
+ # conflict with the flags we set here (e.g.
+ # '-mcpu=cortex-a9'). Remove these flags explicitly.
+ '-march=armv7-a',
+ '-mtune=cortex-a8',
+ ],
+ }],
],
}],
],
« no previous file with comments | « build/all.gyp ('k') | build/install-build-deps.sh » ('j') | build/install-build-deps.sh » ('J')

Powered by Google App Engine
This is Rietveld 408576698