2009-11-08 07:08:07 +00:00
|
|
|
require 'formula'
|
|
|
|
|
2011-03-10 05:11:03 +00:00
|
|
|
class Adamem < Formula
|
2011-05-27 05:02:55 +00:00
|
|
|
head 'https://github.com/adamv/adamem-osx.git', :branch => 'osx-brew'
|
2009-11-08 07:08:07 +00:00
|
|
|
homepage 'http://www.komkon.org/~dekogel/adamem.html'
|
|
|
|
|
|
|
|
def startup_script app
|
|
|
|
# The executables expect to find system roms in the same directory.
|
|
|
|
# We create shim sripts in bin/ that invoke the emulators w/ the full
|
|
|
|
# paths to the system roms.
|
|
|
|
return <<-END
|
|
|
|
#!/bin/bash
|
|
|
|
#{libexec}/#{app} -os7 "#{libexec}/OS7.rom" -eos "#{libexec}/EOS.rom" -wp "#{libexec}/WP.rom" $*
|
|
|
|
END
|
|
|
|
end
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2009-11-08 07:08:07 +00:00
|
|
|
def install
|
|
|
|
Dir.chdir 'src' do
|
|
|
|
system "make -f Makefile.osx dist"
|
|
|
|
end
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2009-11-08 07:08:07 +00:00
|
|
|
libexec.install Dir["dist/*"]
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2009-11-08 07:08:07 +00:00
|
|
|
(bin+'adamem').write startup_script('adamem')
|
|
|
|
(bin+'cvem').write startup_script('cvem')
|
|
|
|
end
|
2010-04-07 05:58:35 +00:00
|
|
|
|
2009-11-08 07:08:07 +00:00
|
|
|
def caveats
|
|
|
|
"Note that AdamEm is an X11 app, and does not support sound."
|
|
|
|
end
|
|
|
|
end
|