summaryrefslogtreecommitdiff
path: root/build
diff options
context:
space:
mode:
authorkjellander@webrtc.org <kjellander@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-03-10 09:51:17 +0000
committerkjellander@webrtc.org <kjellander@webrtc.org@4adac7df-926f-26a2-2b94-8c16560cd09d>2014-03-10 09:51:17 +0000
commitda666ceca7b826376afd5ef2b51649cbf5db199d (patch)
tree1ffff16181ab58a9d9c6730798e842ac68418458 /build
parent4e9a04bd53f7979108a6e19a7ecbc1fdff0d6bc5 (diff)
downloadwebrtc-da666ceca7b826376afd5ef2b51649cbf5db199d.tar.gz
Roll chromium_revision 249215:255773
Overview of changes in Chrome DEPS: $ svn diff http://src.chromium.org/chrome/trunk/src/DEPS -r 249215:255773 which can be compared with the output of: $ grep chromium_deps DEPS in a WebRTC checkout, gives the following relevant changes: * third_party/icu 246118:249466 * third_party/libyuv 978:979 * third_party/libjpeg_turbo 239595:251747 * third_party/libsrtp 214783:250757 * third_party/nss 246067:254867 * tools/clang-format 198831:202065 * tools/gyp 1846:1860 Among a variety of updated DEPS, this enables us to use the new automatic download of Chromium's stripped down Visual Studio 2013 toolchain on Windows. For Windows, Visual Studio 2013 is also the default compiler in Chrome. This CL sets the GYP_MSVS_VERSION to 2010 unless otherwise specified. Doing that we can first fix our 2013 problems before we move over to having 2013 by default. The plan is to build 2013 at the WebRTC FYI waterfall at http://build.chromium.org/p/client.webrtc.fyi/waterfall to ensure we can support VS2013 before the switch. I realized we can sync Chromium's find_depot_tools.py script into it's own folder and just alter the PYTHONPATH for the gyp_webrtc script. That way there's no need to have the dummy module in webrtc/build anymore. The real script is also needed for the logic that handles checking VS2013 and downloading it if not found. BUG=chromium:340973 TEST=All trybots passing runhooks and compile step. R=tommi@webrtc.org Review URL: https://webrtc-codereview.appspot.com/9299004 git-svn-id: http://webrtc.googlecode.com/svn/trunk/webrtc@5667 4adac7df-926f-26a2-2b94-8c16560cd09d
Diffstat (limited to 'build')
-rw-r--r--build/find_depot_tools.py14
-rwxr-xr-xbuild/gyp_webrtc39
2 files changed, 35 insertions, 18 deletions
diff --git a/build/find_depot_tools.py b/build/find_depot_tools.py
deleted file mode 100644
index cfea09b7..00000000
--- a/build/find_depot_tools.py
+++ /dev/null
@@ -1,14 +0,0 @@
-#!/usr/bin/env python
-#
-# Copyright (c) 2014 The WebRTC project authors. All Rights Reserved.
-#
-# Use of this source code is governed by a BSD-style license
-# that can be found in the LICENSE file in the root of the source
-# tree. An additional intellectual property rights grant can be found
-# in the file PATENTS. All contributing project authors may
-# be found in the AUTHORS file in the root of the source tree.
-
-# This empty Python module is needed to avoid an error when importing
-# gyp_chromium in gyp_webrtc. The reason we're doing that is to avoid code
-# duplication. We don't use the functions that actually use the find_depot_tools
-# module. It was introduced as a dependency in http://crrev.com/245412.
diff --git a/build/gyp_webrtc b/build/gyp_webrtc
index 8909eea8..9949e95d 100755
--- a/build/gyp_webrtc
+++ b/build/gyp_webrtc
@@ -18,9 +18,9 @@ import sys
script_dir = os.path.dirname(os.path.realpath(__file__))
checkout_root = os.path.abspath(os.path.join(script_dir, os.pardir, os.pardir))
-chrome_build_dir = os.path.join(checkout_root, 'build')
-sys.path.insert(0, chrome_build_dir)
+sys.path.insert(0, os.path.join(checkout_root, 'build'))
+sys.path.insert(0, os.path.join(checkout_root, 'tools', 'find_depot_tools'))
import gyp_chromium
import gyp_helper
@@ -60,11 +60,34 @@ if __name__ == '__main__':
if not os.environ.get('GYP_GENERATORS'):
os.environ['GYP_GENERATORS'] = 'ninja'
+ # Set default Visual Studio version to 2010 until WebRTC fully supports 2013.
+ # TODO(kjellander): Remove this to enable 2013 as default when we're ready.
+ if (sys.platform in ('cygwin', 'win32') and
+ not os.environ.get('GYP_MSVS_VERSION')):
+ print 'Setting GYP_MSVS_VERSION to 2010 by default.'
+ os.environ['GYP_MSVS_VERSION'] = '2010'
+
+ vs2013_runtime_dll_dirs = None
+ if int(os.environ.get('GYP_MSVS_VERSION', '2010')) == 2013:
+ # Download Chromium's stripped down Visual Studio 2013 compile toolchain.
+ # TODO(kjellander): Make this look like gyp_chromium when 2013 works for us,
+ # this can currently only run for 2013 since GYP_MSVS_VERSION gets
+ # overwritten with 2013 in DownloadVsToolChain() right now.
+ vs2013_runtime_dll_dirs = gyp_chromium.DownloadVsToolChain()
+
# Enforce gyp syntax checking. This adds about 20% execution time.
args.append('--check')
supplemental_includes = gyp_chromium.GetSupplementalFiles()
- if not gyp_chromium.RunGN(supplemental_includes):
+ gn_vars_dict = gyp_chromium.GetGypVarsForGN(supplemental_includes)
+
+ # Automatically turn on crosscompile support for platforms that need it.
+ if all(('ninja' in os.environ.get('GYP_GENERATORS', ''),
+ gn_vars_dict.get('OS') in ['android', 'ios'],
+ 'GYP_CROSSCOMPILE' not in os.environ)):
+ os.environ['GYP_CROSSCOMPILE'] = '1'
+
+ if not gyp_chromium.RunGN(gn_vars_dict):
sys.exit(1)
args.extend(['-I' + i for i in
gyp_chromium.additional_include_files(supplemental_includes,
@@ -77,4 +100,12 @@ if __name__ == '__main__':
sys.stdout.flush()
# Off we go...
- sys.exit(gyp.main(args))
+ gyp_rc = gyp.main(args)
+
+ if vs2013_runtime_dll_dirs:
+ x64_runtime, x86_runtime = vs2013_runtime_dll_dirs
+ gyp_chromium.CopyVsRuntimeDlls(
+ os.path.join(checkout_root, gyp_chromium.GetOutputDirectory()),
+ (x86_runtime, x64_runtime))
+
+ sys.exit(gyp_rc)