我正在尝试用Debian 8在docker中安装mysqlclient-python。
但是当我运行python3 setup.py安装时
我得到了错误:
x86_64-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,-Bsymbolic-functions -Wl,-z,relro -Wl,-z,relro -g -fstack-protector-strong -Wformat -Werror=format-security -D_FORTIFY_SOURCE=2 build/temp.linux-x86_64-3.4/_mysql.o -lmysqlclient -lpthread -lz -lm -ldl -lssl -lcrypto -o build/lib.linux-x86_64-3.4/_mysql.cpython-34m.so
/usr/bin/ld: cannot find -lssl
/usr/bin/ld: cannot find -lcrypto
collect2: error: ld returned 1 exit status
error: command 'x86_64-linux-gnu-gcc' failed with exit status 1我试着安装各种软件包(openssl、crypto++、libmysqlclient、libmysqlclient、.)但什么也帮不了我..。
你知道我到底需要什么吗?
发布于 2017-03-24 22:16:46
如果-lssl和-lcrypto失败了,您可能会丢失libssl头文件
在基于debian的系统上,您可以使用
apt-get install libssl-dev很可能在安装apt的Dockerfile中已经有了一个libssl-dev行,您只需将libssl-dev添加到其中的包列表中即可。
https://stackoverflow.com/questions/43003378
复制相似问题