2010-08-11 21:06:11 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Antlr < Formula
|
|
|
|
homepage 'http://www.antlr.org/'
|
2014-04-20 16:31:18 +00:00
|
|
|
url 'http://www.antlr.org/download/antlr-4.2.2-complete.jar'
|
|
|
|
sha1 '97b3117463b6beda300ee7a297a31b71db9aea2b'
|
2010-08-11 21:06:11 +00:00
|
|
|
|
|
|
|
def install
|
2013-07-17 00:44:03 +00:00
|
|
|
prefix.install "antlr-#{version}-complete.jar"
|
|
|
|
bin.write_jar_script prefix/"antlr-#{version}-complete.jar", "antlr4"
|
2014-05-19 16:57:37 +00:00
|
|
|
(bin+"grun").write <<-EOS.undent
|
|
|
|
#!/bin/bash
|
|
|
|
java -classpath #{prefix}/antlr-#{version}-complete.jar:. org.antlr.v4.runtime.misc.TestRig "$@"
|
|
|
|
EOS
|
2010-08-11 21:06:11 +00:00
|
|
|
end
|
2011-03-10 05:11:03 +00:00
|
|
|
end
|