2011-12-25 05:24:17 +00:00
|
|
|
require 'formula'
|
|
|
|
|
|
|
|
class Konoha < Formula
|
2012-06-14 11:54:42 +00:00
|
|
|
homepage 'http://www.konohascript.org/'
|
2013-08-27 12:39:22 +00:00
|
|
|
url 'https://github.com/konoha-project/konoha3/archive/v0.1.tar.gz'
|
|
|
|
sha1 '85ee3527c9a2db2874280e506c09aab8809a6ad5'
|
2012-10-20 05:11:57 +00:00
|
|
|
|
2013-08-27 13:17:54 +00:00
|
|
|
head 'https://github.com/konoha-project/konoha3.git'
|
|
|
|
|
2012-10-20 05:11:57 +00:00
|
|
|
option 'tests', 'Verify the build with make test (1 min)'
|
2012-06-14 11:54:42 +00:00
|
|
|
|
|
|
|
depends_on 'cmake' => :build
|
2013-06-27 03:08:54 +00:00
|
|
|
depends_on :mpi => [:cc, :cxx]
|
2012-06-14 11:54:42 +00:00
|
|
|
depends_on 'pcre'
|
|
|
|
depends_on 'json-c'
|
|
|
|
depends_on 'sqlite'
|
2013-08-27 13:17:54 +00:00
|
|
|
depends_on 'mecab' if MacOS.version >= :mountain_lion
|
2013-08-27 12:39:22 +00:00
|
|
|
depends_on :python # for python glue code
|
2011-12-25 05:24:17 +00:00
|
|
|
|
|
|
|
def install
|
2012-06-14 11:54:42 +00:00
|
|
|
args = std_cmake_args + ['..']
|
2012-10-20 05:11:57 +00:00
|
|
|
mkdir 'build' do
|
2012-06-14 11:54:42 +00:00
|
|
|
system 'cmake', *args
|
|
|
|
system 'make'
|
2013-08-27 12:39:22 +00:00
|
|
|
system 'make', 'test' if build.include? 'tests'
|
|
|
|
system 'make', 'install'
|
2012-06-14 11:54:42 +00:00
|
|
|
end
|
2011-12-25 05:24:17 +00:00
|
|
|
end
|
|
|
|
end
|