# gem install mysql error with Xampp

**URL:** <https://discuss.rubyonrails.org/t/gem-install-mysql-error-with-xampp/39017>\
**Category:** rubyonrails-talk\
**Created:** [February 4, 2009, 12:32pm UTC](https://discuss.rubyonrails.org/t/gem-install-mysql-error-with-xampp/39017 "2009-02-04T12:32:03Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![11175](https://avatars.discourse-cdn.com/v4/letter/1/8edcca/32.png) [@11175](https://discuss.rubyonrails.org/u/11175)\
**Post date:** [February 4, 2009, 12:32pm UTC](https://discuss.rubyonrails.org/t/gem-install-mysql-error-with-xampp/39017/1 "2009-02-04T12:32:03Z")

</div>

Hello,

I'm trying to install mysql (to use it with Rails 2.2), without any success. After browsing the web, I found some tips (I need to target the xampp files), but it's still not working finally.

My command line is the following : sudo gem install mysql -- --with-mysql-dir=/Applications/xampp/xamppfiles/ --with-mysql-config=/Applications/xampp/xamppfiles/bin/mysql\_config

Results : Building native extensions. This could take a while... ERROR: Error installing mysql: &nbsp;&nbsp;ERROR: Failed to build gem native extension.

/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb install mysql -- --with-mysql-dir=/Applications/xampp/xamppfiles/ --with-mysql-config=/Applications/xampp/xamppfiles/bin/mysql\_config checking for mysql\_ssl\_set()... yes checking for mysql.h... no checking for mysql/mysql.h... no \*\*\* 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: &nbsp;&nbsp;--with-opt-dir &nbsp;&nbsp;--without-opt-dir &nbsp;&nbsp;--with-opt-include &nbsp;&nbsp;--without-opt-include=${opt-dir}/include &nbsp;&nbsp;--with-opt-lib &nbsp;&nbsp;--without-opt-lib=${opt-dir}/lib &nbsp;&nbsp;--with-make-prog &nbsp;&nbsp;--without-make-prog &nbsp;&nbsp;--srcdir=. &nbsp;&nbsp;--curdir &nbsp;&nbsp;--ruby=/System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby &nbsp;&nbsp;--with-mysql-config

Gem files will remain installed in /Library/Ruby/Gems/1.8/gems/mysql-2.7 for inspection. Results logged to /Library/Ruby/Gems/1.8/gems/mysql-2.7/gem\_make.out

Do I have to install something else ? I found a developer package in Xampp website, but I don't know if I have to use it and how to use it... [http://www.apachefriends.org/en/xampp-macosx.html#849](http://www.apachefriends.org/en/xampp-macosx.html#849)

Anyone could help me?

Thank you very much. Vincent
