2010-10-13 15:27:00 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class RiakSearch < Formula
|
2010-10-13 15:27:00 +00:00
|
|
|
homepage 'http://riak.basho.com'
|
2012-02-12 23:32:42 +00:00
|
|
|
url 'http://downloads.basho.com/riak-search/riak-search-0.14/riak_search-0.14.2.tar.gz'
|
2011-06-02 10:50:40 +00:00
|
|
|
md5 '4dc7cfbd2c985fcb1b73fc5ac8864031'
|
|
|
|
|
|
|
|
head 'https://github.com/basho/riak_search.git'
|
2010-10-13 15:27:00 +00:00
|
|
|
|
|
|
|
skip_clean 'libexec/log'
|
|
|
|
skip_clean 'libexec/log/sasl'
|
|
|
|
skip_clean 'libexec/data'
|
|
|
|
skip_clean 'libexec/data/dets'
|
|
|
|
skip_clean 'libexec/data/ring'
|
|
|
|
|
|
|
|
depends_on 'erlang'
|
|
|
|
|
|
|
|
def install
|
|
|
|
ENV.deparallelize
|
2011-06-02 10:50:40 +00:00
|
|
|
system "make all rel"
|
2010-10-13 15:27:00 +00:00
|
|
|
%w(riaksearch riaksearch-admin search-cmd).each do |file|
|
2011-06-02 10:50:40 +00:00
|
|
|
inreplace "rel/riaksearch/bin/#{file}", /^RUNNER_BASE_DIR=.+$/, "RUNNER_BASE_DIR=#{libexec}"
|
2010-10-13 15:27:00 +00:00
|
|
|
end
|
|
|
|
|
|
|
|
# Install most files to private libexec, and link in the binaries.
|
2011-06-02 10:50:40 +00:00
|
|
|
libexec.install Dir["rel/riaksearch/*"]
|
2012-02-12 23:32:42 +00:00
|
|
|
bin.install_symlink Dir["#{libexec}/bin/*"]
|
2010-10-13 15:27:00 +00:00
|
|
|
|
|
|
|
(prefix + 'data/ring').mkpath
|
|
|
|
(prefix + 'data/dets').mkpath
|
2011-06-02 10:50:40 +00:00
|
|
|
|
|
|
|
# Install man pages
|
|
|
|
man1.install Dir["doc/man/man1/*"]
|
2010-10-13 15:27:00 +00:00
|
|
|
end
|
|
|
|
end
|