
Seeing something like this while compiling libmemcached or trying to install the memcached gem?
checking for style of include used by make... GNU
checking for gcc... gcc
checking for C compiler default output file name...
configure: error: in `/opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems/memcached-1.0.2/ext/libmemcached-0.32':
configure: error: C compiler cannot create executables
See `config.log' for more details.
*** 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.
Turns out this error is quite misleading: what I was actually missing was the SASL development headers. This was all easily fixed with:
sudo aptitude install libsasl2-dev
sudo rm -rf /opt/ruby-enterprise-1.8.7-2010.02/lib/ruby/gems/1.8/gems/memcached-1.0.2/ext/libmemcached-0.32
sudo gem install memcached
(Your path to the gem that failed to install properly could well be different, so double check in your error output from the failed install.)
