Install ruby memcached on MacOSX 3 comments

Posted by stephane Tue, 12 Feb 2008 21:13:00 GMT

Classical way, download following archives and compile it in the order. Xcode has to be installed.

tar xzf *.tar.gz
cd 
./configure
make 
sudo make install
  1. lib need for server: lib event. download
  2. the server: memcached. download
  3. the client lib written in c: libmemcached. download
  4. the ruby binding:
    sudo gem install memcached
    or with leopard:
    sudo env ARCHFLAGS="-arch i386" gem install memcached
Comments

Leave a response

  1. Sam 2 months later:

    Just tried this on 10.5.2 and it fails to install the gem:

    Building native extensions. This could take a while… ERROR: Error installing memcached: ERROR: Failed to build gem native extension.

    /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby extconf.rb install memcached checking for memcached_server_add() in -lmemcached… yes checking for #include ... yes checking for #include ... 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.

    I’m a bit stuck now.

  2. LDC 3 months later:

    The link above for libmemcached points to version .15 but the gem seems to need .19. You can download .19 from http://tangent.org/552/libmemcached.html

  3. Tobi 7 months later:

    I think best way is to install via macports.. give it a try..

Comments