我正在为我的一次讲座做一个项目,我需要下载psycopg2包,以便使用正在使用的postgresql数据库。不幸的是,当我尝试pip安装psycopg2时,会弹出以下错误:
ld: library not found for -lssl
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command '/usr/bin/clang' failed with exit status 1
ld: library not found for -lssl
clang: error: linker command failed with exit code 1 (use -v to see invocation)
error: command '/usr/bin/clang' failed with exit status 1
有人知道为什么会这样吗?提前谢谢
如果存在postgresql,则运行:
在venv:
如果只需要使用命令
pip install psycopg2
在macOSX中导出路径:请尝试使用以下工具安装它:
我通过安装命令行工具解决了这个问题
然后通过自制安装openssl并手动将自制安装的openssl链接到pip:
关于macOS Sierra 10.12.1
相关问题 更多 >
编程相关推荐