Chromium Code Reviews| Index: build/gyp_chromium |
| diff --git a/build/gyp_chromium b/build/gyp_chromium |
| index e316adfd65107eb5fdf238b660a0e204926f98c2..73a1b96f989422d121523b107de1f666b60b87c9 100755 |
| --- a/build/gyp_chromium |
| +++ b/build/gyp_chromium |
| @@ -129,6 +129,27 @@ def GetArgsStringForGN(supplemental_files): |
| """Returns the args to pass to GN. |
| Based on a subset of the GYP variables that have been rewritten a bit.""" |
| + # Find the .gyp directory in the user's home directory. |
| + home_dot_gyp = os.environ.get('GYP_CONFIG_DIR', None) |
|
brettw
2014/01/16 21:51:34
This block is just copied from GYP.
|
| + if home_dot_gyp: |
| + home_dot_gyp = os.path.expanduser(home_dot_gyp) |
| + if not home_dot_gyp: |
| + home_vars = ['HOME'] |
| + if sys.platform in ('cygwin', 'win32'): |
| + home_vars.append('USERPROFILE') |
|
scottmg
2014/01/16 22:00:30
this seems a bit dumb, since this is the first thi
|
| + for home_var in home_vars: |
| + home = os.getenv(home_var) |
| + if home != None: |
| + home_dot_gyp = os.path.join(home, '.gyp') |
| + if not os.path.exists(home_dot_gyp): |
| + home_dot_gyp = None |
| + else: |
| + break |
| + |
| + include_gypi = os.path.join(home_dot_gyp, "include.gypi") |
| + if os.path.exists(include_gypi): |
| + supplemental_files += [include_gypi] |
| + |
| vars_dict = GetGypVarsForGN(supplemental_files) |
| gn_args = '' |