Index: build/common.gypi |
diff --git a/build/common.gypi b/build/common.gypi |
index cbf994d5a684673522932f17a103d21c309afbdb..a7264b46f1221351646506c34082b20f9e56e87a 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, |
@@ -47,6 +50,7 @@ |
}, |
# Copy conditionally-set variables out one scope. |
'chromeos%': '<(chromeos)', |
+ 'chromecast%': '<(chromecast)', |
'use_aura%': '<(use_aura)', |
'use_ash%': '<(use_ash)', |
'use_cras%': '<(use_cras)', |
@@ -97,11 +101,11 @@ |
'use_aura%': 1, |
}], |
- # ToT Linux should be aura. |
+ # ToT Linux should be aura (except for chromecast builds). |
alexst (slow to review)
2014/04/22 17:28:12
Does that mean all the rendering messages that now
lcwu1
2014/04/22 18:24:42
Alex, I would think that when aura is disabled, th
|
# |
# TODO(erg): Merge this into the previous block once compiling with |
# aura safely implies including ash capabilities. |
- ['OS=="linux"', { |
+ ['OS=="linux" and chromecast==0', { |
'use_aura%': 1, |
}], |
@@ -117,7 +121,7 @@ |
'use_ozone%': 1, |
}], |
- ['embedded==1', { |
+ ['embedded==1 or chromecast==1', { |
'use_system_fontconfig%': 0, |
}, { |
'use_system_fontconfig%': 1, |
@@ -134,6 +138,7 @@ |
}, |
# Copy conditionally-set variables out one scope. |
'chromeos%': '<(chromeos)', |
+ 'chromecast%': '<(chromecast)', |
'desktop_linux%': '<(desktop_linux)', |
'use_aura%': '<(use_aura)', |
'use_ash%': '<(use_ash)', |
@@ -181,7 +186,7 @@ |
}], |
# Set default value of toolkit_views based on OS. |
- ['OS=="win" or chromeos==1 or use_aura==1', { |
+ ['OS=="win" or chromeos==1 or use_aura==1 or chromecast==1', { |
'toolkit_views%': 1, |
}, { |
'toolkit_views%': 0, |
@@ -242,6 +247,7 @@ |
# Copy conditionally-set variables out one scope. |
'chromeos%': '<(chromeos)', |
+ 'chromecast%': '<(chromecast)', |
'host_arch%': '<(host_arch)', |
'target_arch%': '<(target_arch)', |
'target_subarch%': '<(target_subarch)', |
@@ -557,6 +563,10 @@ |
'os_bsd%': 0, |
}], |
+ ['chromecast==1', { |
+ 'safe_browsing%': 0, |
+ }], |
+ |
# NSS usage. |
['(OS=="linux" or OS=="freebsd" or OS=="openbsd" or OS=="solaris") and use_openssl==0', { |
'use_nss%': 1, |
@@ -573,28 +583,28 @@ |
}], |
# libudev usage. This currently only affects the content layer. |
- ['OS=="linux" and embedded==0', { |
+ ['OS=="linux" and embedded==0 and chromecast==0', { |
'use_udev%': 1, |
}, { |
'use_udev%': 0, |
}], |
# Flags to use X11 on non-Mac POSIX platforms. |
- ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or use_ozone==1', { |
+ ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or use_ozone==1 or chromecast==1', { |
'use_x11%': 0, |
}, { |
'use_x11%': 1, |
}], |
# Flags to use glib. |
- ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or embedded==1', { |
+ ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or embedded==1 or chromecast==1', { |
'use_glib%': 0, |
}, { |
'use_glib%': 1, |
}], |
# Flags to use pango and cairo. |
- ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or embedded==1', { |
+ ['OS=="win" or OS=="mac" or OS=="ios" or OS=="android" or embedded==1 or chromecast==1', { |
'use_pango%': 0, |
'use_cairo%': 0, |
}, { |
@@ -603,7 +613,7 @@ |
}], |
# DBus usage. |
- ['OS=="linux" and embedded==0', { |
+ ['OS=="linux" and embedded==0 and chromecast==0', { |
'use_dbus%': 1, |
}, { |
'use_dbus%': 0, |
@@ -662,9 +672,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, |
@@ -720,7 +730,7 @@ |
'enable_plugin_installation%': 1, |
}], |
- ['OS=="android" or OS=="ios" or embedded==1', { |
+ ['OS=="android" or OS=="ios" or embedded==1 or chromecast==1', { |
'enable_plugins%': 0, |
}, { |
'enable_plugins%': 1, |
@@ -858,15 +868,15 @@ |
}], |
# Disable various features by default on embedded. |
- ['embedded==1', { |
+ ['embedded==1 or chromecast==1', { |
'remoting%': 0, |
'enable_printing%': 0, |
}], |
# 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). |
- ['android_webview_build==0', { |
+ ['android_webview_build==0 and chromecast==0', { |
'icu_use_data_file_flag%' : 1, |
}, { |
'icu_use_data_file_flag%' : 0, |
@@ -953,6 +963,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)', |
@@ -1632,6 +1643,19 @@ |
# Copy it out one scope. |
'android_webview_build%': '<(android_webview_build)', |
}], # OS=="android" |
+ ['chromecast==1', { |
+ 'disable_nacl%': 1, |
jam
2014/04/22 16:21:15
I'm curious why this is needed? You only bring in
lcwu1
2014/04/22 18:24:42
Yes, this is indeed not needed. Removed.
|
+ 'ffmpeg_branding%': 'Chrome', |
+ 'conditions': [ |
+ ['target_arch=="arm"', { |
+ 'cast_uses_directfb%': 0, |
+ 'enable_mpeg2ts_stream_parser%': 1, |
+ 'video_hole%': 1, |
+ }, { |
+ 'cast_uses_directfb%': 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. |
@@ -1759,7 +1783,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', { |
'use_cups%': 1, |
}, { |
'use_cups%': 0, |
@@ -2056,6 +2080,12 @@ |
'arm_thumb%': 0, |
}], |
+ ['chromecast==1', { |
+ 'arm_arch%': '', |
+ 'arm_tune%': 'cortex-a9', |
+ 'arm_thumb%': 1, |
+ }], |
+ |
# Enable brlapi by default for chromeos. |
[ 'chromeos==1', { |
'use_brlapi%': 1, |
@@ -2145,6 +2175,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 |
@@ -2502,6 +2534,20 @@ |
}], |
], # win_z7!=0 |
}], # OS==win |
+ ['chromecast==1', { |
jam
2014/04/22 16:21:15
i'm curious why this one and the previous section
lcwu1
2014/04/22 18:24:42
I was trying to follow the convention here in this
jam
2014/04/22 18:31:57
I'm not sure I understand what you mean. you're no
|
+ 'defines': [ |
+ 'LOG_DISABLED=0', |
+ ], |
+ 'conditions': [ |
+ ['target_arch=="arm"', { |
+ 'defines': [ |
+ # Work around an error when compiling v8/src/platform-linux.cc |
+ # with gcc-4.5. |
+ '__SOFTFP', |
+ ], |
+ }], |
+ ], |
+ }], |
['enable_task_manager==1', { |
'defines': [ |
'ENABLE_TASK_MANAGER=1', |
@@ -3484,6 +3530,32 @@ |
}], |
], |
}], |
+ ['chromecast==1', { |
+ 'cflags': [ |
+ # 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 Chormium (e.g. v8) define their own |
+ # cflags that are not desirable. Remove them explicitly |
+ # here. |
+ '-march=armv7-a', |
+ '-mtune=cortex-a8', |
+ ], |
+ }], |
], |
}], |
], |