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

Unified Diff: chromecast/build/build_env_arm_chromecast.sh

Issue 223143003: Initial checkin of chromecast content embedder (cast_shell) and related build scripts. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add an additional function in gl_surface_cast.cc Created 6 years, 9 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: chromecast/build/build_env_arm_chromecast.sh
diff --git a/chromecast/build/build_env_arm_chromecast.sh b/chromecast/build/build_env_arm_chromecast.sh
new file mode 100644
index 0000000000000000000000000000000000000000..94b63ced32c3cfca2e11c07cbd73a8c14f1c6aab
--- /dev/null
+++ b/chromecast/build/build_env_arm_chromecast.sh
@@ -0,0 +1,77 @@
+# Copyright (c) 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.
+
+function setup_chromium_env_arm_chromecast() {
+ setup_chromium_env_common arm_chromecast $@
+
+ local tc_old="${CHROME_SRCROOT}/../../prebuilt/toolchain/arm-unknown-linux-gnueabi-4.5.3-glibc/bin/arm-unknown-linux-gnueabi"
+ local tc_new="${CHROME_SRCROOT}/../../prebuilt/toolchain/armv7a/bin/armv7a-cros-linux-gnueabi"
+ if [[ -e ${tc_old}-gcc ]]; then
+ tc=${tc_old}
+ elif [[ -e ${tc_new}-gcc ]]; then
+ tc=${tc_new}
+ else
+ echo "could not find toolchain"
+ exit 1
+ fi
+ setup_build_toolchain "${tc}"
+
+ setup_chromium_env_common_chromecast
+
+ # If using a hardfloat toolchain, set the gyp defines for it.
+ if [[ ! -e ${CHROME_SRCROOT}/../../prebuilt/toolchain/arm-unknown-linux-gnueabi-4.5.3-glibc/bin/arm-unknown-linux-gnueabi-gcc &&
+ ( -e ${CHROME_SRCROOT}/../../prebuilt/toolchain/armv7a/bin/armv7a-cros-linux-gnueabi-gcc ||
+ -e `which armv7a-cros-linux-gnueabi-gcc` ) ]]; then
+ export GYP_DEFINES="${GYP_DEFINES} arm_float_abi=hard v8_use_arm_eabi_hardfloat=true"
+ fi
+
+ # Check if widevine is available.
+ if [ -d "${CHROME_SRCROOT}/chromecast/internal/widevine_cdm" ]; then
+ export GYP_DEFINES="${GYP_DEFINES} use_widevine=1"
+ fi
+
+ # Check if playready is available.
+ if [ -d "${CHROME_SRCROOT}/chromecast/internal/playready_cdm" ]; then
+ export GYP_DEFINES="${GYP_DEFINES} use_playready=1"
+ fi
+
+ # - arm_thumb=1: turn on Thumb mode for a smaller executable.
+ # - armv7=1: We are using a Cortex A9 which support Arm V7.
+ # - cast_uses_directfb=0 (use MARVELL's graphics directly)
+ # - chromecast_branding=Chrome: Whether this is internal release build
+ # (Chrome) or public build (Chromium)
+ # - linux_use_gold_binary=0: Don't use gold linker.
+ # - linux_use_gold_flags=0: Don't use gold specific flags.
+ # - sysroot: Set the build sysroot directory
+ # - target_arch=arm : this is ARM.
+ # - use_alsa=0
+ # - use_libjpeg_turbo=1: Use libjpeg_turbo for arm build
+ # - use_pulseaudio=0
+ # - use_system_libjpeg=0
+ # - video_hole=1: Enable video hole punching
+ local defines="
+arm_arch=''
jam 2014/04/04 01:01:24 i wonder if this stuff better belongs in build/com
lcwu1 2014/04/05 01:17:13 Yes, I too prefer what you suggested. (In fact, in
jam 2014/04/07 17:32:01 I see. ok btw this is what android does (they set
+arm_tune='cortex-a9'
+arm_thumb=1
+armv7=1
+cast_uses_directfb=0
+chromecast_branding=Chrome
+linux_use_gold_binary=0
+linux_use_gold_flags=0
+sysroot=${CHROME_SRCROOT}/../../${TARGET_OUT_TOOLCHAIN:-out/target/product/anchovy/build_sysroot}
+target_arch=arm
+use_alsa=0
+use_libjpeg_turbo=1
+use_pulseaudio=0
+use_system_libjpeg=0
+video_hole=1
+"
+
+ export GYP_DEFINES="${GYP_DEFINES} ${defines}"
+}
+
+function setup_chrome_env_arm_chromecast() {
+ setup_chromium_env_arm_chromecast $@
+ brand_as_chrome
+}

Powered by Google App Engine
This is Rietveld 408576698