2009-11-23 05:30:48 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class OpenTyrianData < Formula
|
2009-11-23 05:30:48 +00:00
|
|
|
url 'http://sites.google.com/a/camanis.net/opentyrian/tyrian/tyrian21.zip'
|
|
|
|
md5 '2a3b206a6de25ed4b771af073f8ca904'
|
|
|
|
end
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class OpenTyrian < Formula
|
2010-04-07 05:58:35 +00:00
|
|
|
url 'http://opentyrian.googlecode.com/hg/', :revision => '9ddcd06e48'
|
2009-11-23 05:30:48 +00:00
|
|
|
homepage 'http://code.google.com/p/opentyrian/'
|
2011-02-20 22:02:36 +00:00
|
|
|
version '20091122'
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2009-11-23 05:30:48 +00:00
|
|
|
depends_on 'sdl'
|
|
|
|
depends_on 'sdl_net'
|
|
|
|
|
|
|
|
def install
|
2010-04-07 05:58:35 +00:00
|
|
|
OpenTyrianData.new.brew { libexec.install Dir['*'] }
|
2009-11-23 05:30:48 +00:00
|
|
|
|
|
|
|
system "make release"
|
|
|
|
libexec.install "opentyrian"
|
|
|
|
# Use a startup script to find the game data
|
|
|
|
(bin+'opentyrian').write startup_script
|
|
|
|
end
|
|
|
|
|
|
|
|
def startup_script
|
2010-04-07 05:58:35 +00:00
|
|
|
<<-END
|
2009-11-23 05:30:48 +00:00
|
|
|
#!/bin/bash
|
|
|
|
#{libexec}/opentyrian --data=#{libexec} $*
|
|
|
|
END
|
|
|
|
end
|
|
|
|
|
|
|
|
def caveats
|
|
|
|
"Save games will be put in ~/.opentyrian"
|
|
|
|
end
|
|
|
|
end
|