2013-11-03 4 views
0

/opt (LAMPP 번들)에 설치된 apache 서버로 보석을 실행하려고합니다. mysql2 gem을 설치하려고 할 때 오류가 발생했습니다. 검색 후 나는 다음 않았다 : 다음gem mysql2를 lampp로 설치

aptitude install libmysql-ruby libmysqlclient-dev ruby-dev 

과 :

gem install mysql2 -- --with-mysql-config=/opt/lampp/bin/mysql_config --with-mysql-dir=/opt/lampp/lib/mysql --with-mysql-lib=/opt/lampp/lib/mysql/ --with-mysql-include=/usr/include/mysql 

여기에 응답이다 :

checking for rb_thread_blocking_region()... yes 
checking for rb_wait_for_single_fd()... yes 
checking for rb_hash_dup()... yes 
checking for rb_intern3()... yes 
checking for mysql.h... no 
checking for mysql/mysql.h... yes 
checking for errmsg.h... no 
----- 
errmsg.h is missing. please check your installation of mysql and try again. 
----- 
*** extconf.rb failed *** 
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. 

Provided configuration options: 
--with-opt-dir 
--without-opt-dir 
--with-opt-include 
--without-opt-include=${opt-dir}/include 
--with-opt-lib 
--without-opt-lib=${opt-dir}/lib 
--with-make-prog 
--without-make-prog 
--srcdir=. 
--curdir 
--ruby=/usr/bin/ruby1.9.1 
--with-mysql-config 


Gem files will remain installed in /var/lib/gems/1.9.1/gems/mysql2-0.3.13 for inspection. 
Results logged to /var/lib/gems/1.9.1/gems/mysql2-0.3.13/ext/mysql2/gem_make.out 

그래서, 문제가 errmsg.h 라이브러리입니다. dev 패키지를 설치 한 후 루비는 다른 누락 된 라이브러리를 발견했습니다. 'mysql.h'하지만이 것은 아닙니다. 나는 지금 무엇을 해야할지 잘 모르겠다. 나는 비슷한 질문을하는 많은 애호가를 보았지만 아무도 도움이되지 못했다.

도움이 될 것입니다.

+0

과 같을 것이다 당신은 너무 ** ** libmysqlclient16를 설치 한 적이 있습니까? – xmikex83

답변

0

나는 결국 포기했다. Lampp은 시작에 좋지만 지금 번들로 제공되지 않은 것들이 많이 필요합니다. 설치하는 일은 점점 더 복잡해지고 있습니다. 나는 모든 것을 가상 머신으로 옮겼고 완벽하게 작동합니다.

0

글쎄, 나는 꽤 오래 전임을 알고있다. 그러나 나는 요즘 같은 문제가 있었다. 당신은 lampp nativly의 include 폴더를 사용하여 필요한 모든 의존성을 찾았습니다.

그래서 표현은

gem install mysql2 -- --with-mysql-config=/opt/lampp/bin/mysql_config --with-mysql-dir=/opt/lampp/mysql --with-mysql-lib=/opt/lampp/lib/mysql/ --with-mysql-include=/opt/lampp/include/ 
관련 문제