我正在Debian 9.6上运行Ruby v2.3.3。我在终端sudo gem install mysql
中执行了此命令。
这给了我一个错误。
Could not create Makefile due to some reason, probably lack of necessary
libraries and/or headers. Check the mkmf.log file for more details. You may
need configuration options.
以下是错误的全文:https://pastebin.com/raw/HZcL2UtF
以下是mkmf.log
的内容:https://pastebin.com/raw/Bki5e9tT
为什么我不能安装mysql
gem?如何解决此错误?
答案 0 :(得分:1)
通常,这意味着您的系统上不需要mysql库。
尝试执行:
sudo apt-get update
sudo apt-get install libmysqlclient-dev libmysqlclient16
然后再次运行mysql gem安装:
sudo gem install mysql