Ruby on Rails - Bundler MySQL错误

时间:2022-08-07 00:16:02

I was trying to create a new Rails project. When I ran bundle install, I got an error for some reason. Can anyone tell me why this error is occurred and how to fix it?

我试图创建一个新的Rails项目。当我运行bundle install时,由于某种原因我收到了错误。谁能告诉我为什么会出现这个错误以及如何修复它?

Rails log (Pastebin): Pastebin Log

Rails日志(Pastebin):Pastebin日志

Don't mark as duplicate, just send the link of the question and tell me to delete this post. My operating system is Ubuntu.

不要标记为重复,只需发送问题的链接并告诉我删除此帖子。我的操作系统是Ubuntu。

1 个解决方案

#1


3  

It sounds like you don't have the libmysqlclient-dev package installed:

听起来你没有安装libmysqlclient-dev软件包:

sudo apt-get install libmysqlclient-dev
gem install mysql2

Then try:

然后尝试:

bundle install

捆绑安装

#1


3  

It sounds like you don't have the libmysqlclient-dev package installed:

听起来你没有安装libmysqlclient-dev软件包:

sudo apt-get install libmysqlclient-dev
gem install mysql2

Then try:

然后尝试:

bundle install

捆绑安装