2014-10-27 16:29:01 +00:00
|
|
|
class Fibjs < Formula
|
2015-05-19 00:00:59 +00:00
|
|
|
desc "JavaScript on Fiber"
|
2014-10-27 16:29:01 +00:00
|
|
|
homepage "http://fibjs.org"
|
2015-08-20 08:20:21 +00:00
|
|
|
url "https://github.com/xicilion/fibjs/releases/download/v0.1.5/fibjs-0.1.5-fullsrc.zip"
|
|
|
|
sha256 "ef9484c743446581a4f0aa34fe1cc520d80b70a3218fbbe4dfcfe292756e340f"
|
2014-10-27 16:29:01 +00:00
|
|
|
|
|
|
|
head "https://github.com/xicilion/fibjs.git"
|
|
|
|
|
2014-10-27 17:46:11 +00:00
|
|
|
bottle do
|
|
|
|
cellar :any
|
2015-08-20 09:43:21 +00:00
|
|
|
sha256 "41f6eeb1f5f81f6d151647c3cbe01358a6d099dacf05e245b2317ff1a722faa8" => :yosemite
|
|
|
|
sha256 "e298976f55cc51c772da3d256867d1f071199b09c906ead9eeb3613da938d7dd" => :mavericks
|
|
|
|
sha256 "fec11a40de8afdecda385fefb6cb96763522c895cc01a18d3e796b48f9584fca" => :mountain_lion
|
2014-10-27 17:46:11 +00:00
|
|
|
end
|
|
|
|
|
2014-10-27 16:29:01 +00:00
|
|
|
depends_on "cmake" => :build
|
|
|
|
|
|
|
|
def install
|
2015-01-14 01:11:22 +00:00
|
|
|
system "./build", "Release", "-j#{ENV.make_jobs}"
|
2014-10-27 16:29:01 +00:00
|
|
|
bin.install "bin/Darwin_Release/fibjs"
|
|
|
|
end
|
|
|
|
|
|
|
|
test do
|
|
|
|
path = testpath/"test.js"
|
|
|
|
path.write "console.log('hello');"
|
|
|
|
|
|
|
|
output = `#{bin}/fibjs #{path}`.strip
|
|
|
|
assert_equal "hello", output
|
|
|
|
assert_equal 0, $?.exitstatus
|
|
|
|
end
|
|
|
|
end
|