提交 0a76c667 authored 作者: Pascal Lamblin's avatar Pascal Lamblin

Fix a crash on Mac OS when sys.prefix is different from its realpath

The problem was that new_path was actually in the environment variable, but when realpath(v) was called, it became a different string (starting with a single backslash instead of two).
上级 fb3ceef9
...@@ -1684,6 +1684,7 @@ class GCC_compiler(object): ...@@ -1684,6 +1684,7 @@ class GCC_compiler(object):
cxxflags.extend(['-framework', 'Python']) cxxflags.extend(['-framework', 'Python'])
if 'Anaconda' in sys.version: if 'Anaconda' in sys.version:
new_path = os.path.join(sys.prefix, "lib") new_path = os.path.join(sys.prefix, "lib")
new_path = os.path.realpath(new_path)
v = os.getenv("DYLD_FALLBACK_LIBRARY_PATH", None) v = os.getenv("DYLD_FALLBACK_LIBRARY_PATH", None)
if v is not None: if v is not None:
# This will resolve symbolic links # This will resolve symbolic links
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论