homebrew-core/Formula/henplus.rb
Volker Fritzsch 8aa231ada1 henplus 0.9.8 (new formula)
Closes Homebrew/homebrew#14831.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
2013-02-18 12:00:33 +00:00

32 lines
833 B
Ruby

require 'formula'
class Henplus < Formula
homepage 'https://github.com/neurolabs/henplus'
url 'https://github.com/downloads/neurolabs/henplus/henplus-0.9.8.tar.gz'
sha1 'ab1fc3a2ec5a6c8f434d2965d9bbe2121030ffd1'
depends_on 'libreadline-java'
def install
ENV['JAVA_HOME'] = `/usr/libexec/java_home`.chomp!
inreplace 'bin/henplus' do |s|
s.gsub! "LD_LIBRARY_PATH", "DYLD_LIBRARY_PATH"
s.gsub! "$THISDIR/..", HOMEBREW_PREFIX
s.gsub! "share/java/libreadline-java.jar",
"share/libreadline-java/libreadline-java.jar"
end
system 'ant', 'install' "-Dprefix=#{prefix}"
end
def caveats; <<-EOS.undent
You may need to set JAVA_HOME:
export JAVA_HOME="$(/usr/libexec/java_home)"
EOS
end
test do
system "echo exit | henplus | grep -v Exception"
end
end