Chromium Code Reviews| Index: gclient.py |
| diff --git a/gclient.py b/gclient.py |
| index a91c61b32bf45253a9bedf9a8f39b909ec317bdb..c3560bdb16e4838cb914b317e4ba8466f76a6675 100644 |
| --- a/gclient.py |
| +++ b/gclient.py |
| @@ -55,6 +55,14 @@ Specifying a target OS |
| Example: |
| target_os = [ "android" ] |
| + |
| + If the "target_os_only" key is also present and true, then *only* the |
| + operating systems listed in "target_os" will be used. If "target_os" is not |
| + present, "target_os_only" has no effect. |
| + |
| + Example: |
| + target_os = [ "ios" ] |
| + target_os_only = True |
| """ |
| __version__ = "0.6.4" |
| @@ -886,7 +894,10 @@ solutions = [ |
| # Append any target OS that is not already being enforced to the tuple. |
| target_os = config_dict.get('target_os', []) |
| - self._enforced_os = tuple(set(self._enforced_os).union(target_os)) |
| + if len(target_os) > 0 and config_dict.get('target_os_only', False): |
|
M-A Ruel
2012/11/02 12:07:21
if target_os and ...
will work just fine.
in fact
stuartmorgan
2012/11/02 12:36:12
Good call; done (and test updated to check that it
|
| + self._enforced_os = tuple(set(target_os)) |
| + else: |
| + self._enforced_os = tuple(set(self._enforced_os).union(target_os)) |
| deps_to_add = [] |
| for s in config_dict.get('solutions', []): |