homebrew-core/Formula/memcached-php.rb
Thomas Bouve ac5aa39fdc memcached-php: fix for non-/usr/local installs
Closes Homebrew/homebrew#9975.

Signed-off-by: Jack Nagel <jacknagel@gmail.com>
2012-02-04 13:46:31 -06:00

27 lines
723 B
Ruby

require 'formula'
class MemcachedPhp < Formula
url 'http://pecl.php.net/get/memcached-1.0.2.tgz'
homepage 'http://pecl.php.net/package/memcached'
md5 'b91f815ad59086d0c3564cce022b5c4f'
depends_on 'libmemcached'
def install
Dir.chdir "memcached-#{version}" do
system "phpize"
system "./configure", "--prefix=#{prefix}",
"--with-libmemcached-dir=#{Formula.factory('libmemcached').prefix}"
system "make"
prefix.install 'modules/memcached.so'
end
end
def caveats; <<-EOS.undent
To finish installing memcached:
* Add the following line to php.ini:
extension="#{prefix}/memcached.so"
* Restart your webserver
EOS
end
end