Index: pylib/gyp/common.py |
=================================================================== |
--- pylib/gyp/common.py (revision 1475) |
+++ pylib/gyp/common.py (working copy) |
@@ -10,6 +10,7 @@ |
import re |
import tempfile |
import sys |
+import pprint |
Torne
2012/08/22 11:23:21
Left over from debugging?
|
# A minimal memoizing decorator. It'll blow up if the args aren't immutable, |
@@ -370,6 +371,17 @@ |
return params.get('flavor', flavor) |
+def GetHostFlavor(params): |
+ """Returns |params.options.host_flavor| if it's set, the system's default |
+ flavor else.""" |
+ options = params.get('options') |
+ if options.host_flavor: |
+ host_flavor = options.host_flavor |
+ else: |
+ host_flavor = GetFlavor({}) |
+ return host_flavor; |
+ |
+ |
def CopyTool(flavor, out_path): |
"""Finds (mac|sun|win)_tool.gyp in the gyp directory and copies it |
to |out_path|.""" |