Lines Matching refs:os

8 import os
16 script_dir = os.path.dirname(os.path.realpath(__file__))
17 chrome_src = os.path.abspath(os.path.join(script_dir, os.pardir))
18 SRC_DIR = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))
19 sys.path.insert(1, os.path.join(chrome_src, 'tools'))
20 sys.path.insert(0, os.path.join(chrome_src, 'build', 'gyp', 'pylib'))
21 json_data_file = os.path.join(script_dir, 'win_toolchain.json')
34 bool(int(os.environ.get('DEPOT_TOOLS_WIN_TOOLCHAIN', '1')))
37 if ((sys.platform in ('win32', 'cygwin') or os.path.exists(json_data_file))
39 if not os.path.exists(json_data_file):
55 os.environ['GYP_MSVS_OVERRIDE_PATH'] = toolchain
56 os.environ['GYP_MSVS_VERSION'] = version
63 os.environ['GYP_DEFINES'] = ' '.join('%s=%s' % (k, pipes.quote(str(v)))
65 os.environ['WINDOWSSDKDIR'] = win_sdk
66 os.environ['WDK_DIR'] = wdk
69 os.environ['PATH'] = runtime_path + ';' + os.environ['PATH']
76 if os.environ['GYP_MSVS_VERSION'] == '2013':
78 elif os.environ['GYP_MSVS_VERSION'] == '2015':
88 if (os.path.isdir(os.path.dirname(target)) and
89 (not os.path.isfile(target) or
90 os.stat(target).st_mtime != os.stat(source).st_mtime)):
92 if os.path.exists(target):
93 os.unlink(target)
102 target = os.path.join(target_dir, dll)
103 source = os.path.join(source_dir, dll)
112 target = os.path.join(target_dir, dll)
113 source = os.path.join(source_dir, dll)
126 out_debug = os.path.join(output_dir, 'Debug')
127 out_debug_nacl64 = os.path.join(output_dir, 'Debug', 'x64')
128 out_release = os.path.join(output_dir, 'Release')
129 out_release_nacl64 = os.path.join(output_dir, 'Release', 'x64')
130 out_debug_x64 = os.path.join(output_dir, 'Debug_x64')
131 out_release_x64 = os.path.join(output_dir, 'Release_x64')
133 if os.path.exists(out_debug) and not os.path.exists(out_debug_nacl64):
134 os.makedirs(out_debug_nacl64)
135 if os.path.exists(out_release) and not os.path.exists(out_release_nacl64):
136 os.makedirs(out_release_nacl64)
137 if os.environ.get('GYP_MSVS_VERSION') == '2015':
154 if os.environ.get('GYP_MSVS_OVERRIDE_PATH'):
155 pgo_x86_runtime_dir = os.path.join(os.environ.get('GYP_MSVS_OVERRIDE_PATH'),
157 pgo_x64_runtime_dir = os.path.join(pgo_x86_runtime_dir, 'amd64')
159 source_x86 = os.path.join(pgo_x86_runtime_dir, pgo_runtime_dll)
160 if os.path.exists(source_x86):
161 _CopyRuntimeImpl(os.path.join(out_release, pgo_runtime_dll), source_x86)
162 source_x64 = os.path.join(pgo_x64_runtime_dir, pgo_runtime_dll)
163 if os.path.exists(source_x64):
164 _CopyRuntimeImpl(os.path.join(out_release_x64, pgo_runtime_dll),
193 if os.environ.get('GYP_MSVS_VERSION') == '2015':
208 if force == '--force' or os.path.exists(json_data_file):
212 bool(int(os.environ.get('DEPOT_TOOLS_WIN_TOOLCHAIN', '1')))
219 os.path.join(depot_tools_path,
237 if not 'WINDOWSSDKDIR' in os.environ:
239 if os.path.isdir(default_sdk_path):
240 os.environ['WINDOWSSDKDIR'] = default_sdk_path
248 os.environ['GYP_MSVS_OVERRIDE_PATH'],
249 os.environ['WINDOWSSDKDIR'],
250 os.environ['GYP_MSVS_VERSION'],
251 os.environ.get('WDK_DIR', ''),