GitLab on Wheezy, error while installing Gems, libmysqlclient-dev probably missing but unistallable

一世执手 提交于 2019-12-13 01:27:12

问题


So, while I was installing GitLab following the official tutorial I got an error on the Gems installation.

Gem files will remain installed in /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/mysql2-0.3.11 for inspection.
Results logged to /home/git/gitlab/vendor/bundle/ruby/2.0.0/gems/mysql2-0.3.11/ext/mysql2/gem_make.out
An error occurred while installing mysql2 (0.3.11), and Bundler cannot continue.
Make sure that `gem install mysql2 -v '0.3.11'` succeeds before bundling.

Looking online they say this problem comes often when some lib is missing.. and one comment confirm what I was scared of...

problem solve, type this command

sudo apt-get install libmysqlclient-dev

sudo apt-get install mysql

then run gem install mysql2

The problem is that I tried to install it but..

sudo apt-get install libmysqlclient-dev
Reading package lists... Done
Building dependency tree       
Reading state information... Done
Package libmysqlclient-dev is not available, but is referred to by another package.
This may mean that the package is missing, has been obsoleted, or
is only available from another source
However the following packages replace it:
  mysql-server-5.5

E: Package 'libmysqlclient-dev' has no installation candidate

and mysql-server-5.5 is already installed... How can I solve it?

Info: Linux 3.10.13-x86_64-jb1 #3 SMP Fri Oct 4 11:46:29 CEST 2013 x86_64 GNU/Linux


回答1:


Check your sources.list (/etc/apt/sources.list) and make sure you have these repos listed there

deb http://packages.dotdeb.org wheezy all
deb-src http://packages.dotdeb.org wheezy all

now run

sudo apt-get install libmysqlclient-dev

Then Gitlab gem will install without error too.



来源:https://stackoverflow.com/questions/21747026/gitlab-on-wheezy-error-while-installing-gems-libmysqlclient-dev-probably-missi

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!