提交 2bb847cf authored 作者: lucianopaz's avatar lucianopaz 提交者: Luciano Paz

Use empty blas_ldflags if no cxx is configured

上级 7eafb6c6
......@@ -2773,6 +2773,9 @@ def default_blas_ldflags():
else:
raise RuntimeError(f"Supplied flags {flags} failed to compile")
# If no compiler is available we default to empty ldflags
if not config.cxx:
return ""
_std_lib_dirs = std_lib_dirs()
if len(_std_lib_dirs) > 0:
rpath = _std_lib_dirs[0]
......
......@@ -226,6 +226,11 @@ def test_default_blas_ldflags(
)
def test_default_blas_ldflags_no_cxx():
with pytensor.config.change_flags(cxx=""):
assert default_blas_ldflags() == ""
@patch(
"os.listdir", return_value=["mkl_core.1.dll", "mkl_rt.1.0.dll", "mkl_rt.1.1.lib"]
)
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论