require 'formula' require 'hardware' # Install script heavily borrowed from Fink package: # http://pdb.finkproject.org/pdb/package.php/dosbox class Dosbox = 10.6 and Hardware.is_64_bit? which_cpu = 'x86_64' else which_cpu = 'i386' end system "./configure", "--disable-debug", "--disable-dependency-tracking", "--prefix=#{prefix}", "--mandir=#{man}", "--disable-sdltest", "--enable-core-inline", "--build=#{which_cpu}-apple-darwin#{which_darwin}" # This should be a patch - add missing header. inreplace "src/gui/midi_coreaudio.h", "#include ", "#include \n#include " system "make" bin.install 'src/dosbox' man1.install gzip('docs/dosbox.1') end end