mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-25 05:41:12 +00:00
Bug 1402915: In clang-cl builds, use MSVC paths for INCLUDE/LIB/etc. r=froydnj
--HG-- extra : rebase_source : c63a662edd2e341e8c69ea2ace54e92f5bbd8711
This commit is contained in:
parent
2f634add59
commit
8d81fe677d
@ -247,12 +247,19 @@ def valid_ucrt_sdk_dir(windows_sdk_dir, windows_sdk_dir_env):
|
||||
@depends(c_compiler)
|
||||
@imports('os')
|
||||
def vc_path(c_compiler):
|
||||
if c_compiler.type != 'msvc':
|
||||
if c_compiler.type not in ('msvc', 'clang-cl'):
|
||||
return
|
||||
|
||||
# Normally, we'd start from c_compiler.compiler, but for now, it's not the
|
||||
# ideal full path to the compiler. At least, we're guaranteed find_program
|
||||
# will get us the one we found in toolchain.configure.
|
||||
cl = find_program(c_compiler.compiler)
|
||||
vc_program = c_compiler.compiler
|
||||
|
||||
# In clang-cl builds, we use the headers and libraries from an MSVC installation.
|
||||
if c_compiler.type == 'clang-cl':
|
||||
vc_program = 'cl.exe'
|
||||
|
||||
cl = find_program(vc_program)
|
||||
result = os.path.dirname(cl)
|
||||
while True:
|
||||
next, p = os.path.split(result)
|
||||
|
Loading…
Reference in New Issue
Block a user