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

Unified Diff: tools/utils.py

Issue 397593006: Fixes create_sdk target for cross-builds. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 5 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
« tools/build.py ('K') | « tools/build.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/utils.py
===================================================================
--- tools/utils.py (revision 38203)
+++ tools/utils.py (working copy)
@@ -242,6 +242,13 @@
def GetArchFamily(arch):
return ARCH_FAMILY[arch]
+def IsCrossBuild(target_os, arch):
+ host_arch = ARCH_GUESS
+ if ((GetArchFamily(host_arch) != GetArchFamily(arch)) or
Bill Hesse 2014/07/16 07:35:43 Why not just return the boolean expression?
zra 2014/07/16 14:48:20 Done.
+ (target_os != GuessOS())):
+ return True
+ return False
+
def GetBuildConf(mode, arch, conf_os=None):
if conf_os == 'android':
return '%s%s%s' % (GetBuildMode(mode), conf_os.title(), arch.upper())
@@ -260,7 +267,7 @@
def GetBuildRoot(host_os, mode=None, arch=None, target_os=None):
build_root = GetBuildDir(host_os, target_os)
if mode:
- build_root = os.path.join(build_root, GetBuildConf(mode, arch))
+ build_root = os.path.join(build_root, GetBuildConf(mode, arch, target_os))
return build_root
def GetBaseDir():
« tools/build.py ('K') | « tools/build.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698