groovyserv: fix for build errors

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
This commit is contained in:
Yasuharu NAKANO 2011-03-22 09:52:13 +09:00 committed by Adam Vandenberg
parent b94ac1c132
commit 4f49dee837

View file

@ -7,15 +7,22 @@ class Groovyserv < Formula
head 'http://github.com/kobo/groovyserv.git', :using => :git
depends_on 'groovy'
depends_on 'maven'
def install
# Build
system 'mvn package -Dmaven.test.skip=true'
# Install executables in libexec to avoid conflicts
Dir::chdir Dir['target/groovyserv-*/groovyserv-*/'].first do
prefix.install %w{LICENSE README}
libexec.install %w{bin lib}
end
prefix.install %w{LICENSE.txt README.txt NOTICE.txt}
# Remove windows files
rm_f Dir["#{libexec}/bin/*.bat"]
# Symlink binaries
bin.mkpath
Dir["#{libexec}/bin/*"].each do |f|
ln_s f, bin + File.basename(f)