Bug 1751810 - Stop checking for DIA SDK headers and libraries. r=firefox-build-system-reviewers,andi

After bug 1588538, the only use of the DIA SDK is to copy msdia140.dll
for llvm-symbolizer.exe.

Differential Revision: https://phabricator.services.mozilla.com/D136820
This commit is contained in:
Mike Hommey 2022-01-25 09:23:03 +00:00
Родитель bc6de6a896
Коммит ba9b891611
1 изменённых файлов: 26 добавлений и 33 удалений

Просмотреть файл

@ -302,32 +302,9 @@ def vc_path(c_compiler, host_c_compiler, vc_toolchain_search_path):
return os.path.normpath(result) return os.path.normpath(result)
option(env="DIA_SDK_PATH", nargs=1, help="Path to the Debug Interface Access SDK") @depends(vc_path, valid_windows_sdk_dir, valid_ucrt_sdk_dir)
@depends(vc_path, "DIA_SDK_PATH")
@checking("for the Debug Interface Access SDK", lambda x: x or "not found")
@imports("os") @imports("os")
def dia_sdk_dir(vc_path, dia_sdk_path): def include_path(vc_path, windows_sdk_dir, ucrt_sdk_dir):
if dia_sdk_path:
path = os.path.normpath(dia_sdk_path[0])
elif vc_path:
# This would be easier if we had the installationPath that
# get_vc_paths works with, since 'DIA SDK' is relative to that.
path = os.path.normpath(
os.path.join(vc_path, "..", "..", "..", "..", "DIA SDK")
)
else:
return
if os.path.exists(os.path.join(path, "include", "dia2.h")):
return path
@depends(vc_path, valid_windows_sdk_dir, valid_ucrt_sdk_dir, dia_sdk_dir)
@imports("os")
def include_path(vc_path, windows_sdk_dir, ucrt_sdk_dir, dia_sdk_dir):
if not vc_path: if not vc_path:
return return
atlmfc_dir = os.path.join(vc_path, "atlmfc", "include") atlmfc_dir = os.path.join(vc_path, "atlmfc", "include")
@ -366,8 +343,6 @@ def include_path(vc_path, windows_sdk_dir, ucrt_sdk_dir, dia_sdk_dir):
os.path.join(ucrt_sdk_dir.include, "ucrt"), os.path.join(ucrt_sdk_dir.include, "ucrt"),
) )
) )
if dia_sdk_dir:
includes.append(os.path.join(dia_sdk_dir, "include"))
# Set in the environment for old-configure # Set in the environment for old-configure
includes = ";".join(includes) includes = ";".join(includes)
os.environ["INCLUDE"] = includes os.environ["INCLUDE"] = includes
@ -380,6 +355,29 @@ set_config("INCLUDE", include_path)
set_define("_SILENCE_CLANG_COROUTINE_MESSAGE", "") set_define("_SILENCE_CLANG_COROUTINE_MESSAGE", "")
option(env="DIA_SDK_PATH", nargs=1, help="Path to the Debug Interface Access SDK")
@depends(vc_path, "DIA_SDK_PATH")
@checking("for the Debug Interface Access SDK", lambda x: x or "not found")
@imports("os")
def dia_sdk_dir(vc_path, dia_sdk_path):
if dia_sdk_path:
path = os.path.normpath(dia_sdk_path[0])
elif vc_path:
# This would be easier if we had the installationPath that
# get_vc_paths works with, since 'DIA SDK' is relative to that.
path = os.path.normpath(
os.path.join(vc_path, "..", "..", "..", "..", "DIA SDK")
)
else:
return
if os.path.exists(os.path.join(path, "include", "dia2.h")):
return path
@template @template
def dia_sdk_subdir(host_or_target, subdir): def dia_sdk_subdir(host_or_target, subdir):
@depends(dia_sdk_dir, host_or_target, dependable(subdir)) @depends(dia_sdk_dir, host_or_target, dependable(subdir))
@ -417,12 +415,9 @@ def lib_path_for(host_or_target):
vc_path, vc_path,
valid_windows_sdk_dir, valid_windows_sdk_dir,
valid_ucrt_sdk_dir, valid_ucrt_sdk_dir,
dia_sdk_subdir(host_or_target, "lib"),
) )
@imports("os") @imports("os")
def lib_path( def lib_path(target, is_host, vc_path, windows_sdk_dir, ucrt_sdk_dir):
target, is_host, vc_path, windows_sdk_dir, ucrt_sdk_dir, dia_sdk_lib_dir
):
if not vc_path: if not vc_path:
return return
sdk_target = { sdk_target = {
@ -452,8 +447,6 @@ def lib_path_for(host_or_target):
os.path.join(ucrt_sdk_dir.lib, "ucrt", sdk_target), os.path.join(ucrt_sdk_dir.lib, "ucrt", sdk_target),
) )
) )
if dia_sdk_lib_dir:
libs.append(dia_sdk_lib_dir)
return libs return libs
return lib_path return lib_path