require 'formula' class Exodriver :git depends_on 'libusb' def options [["--universal", "Build a universal binary."]] end def install cd 'liblabjackusb' mv 'Makefile.MacOSX', 'Makefile' inreplace 'Makefile' do |s| s.change_make_var! 'DESTINATION', lib s.change_make_var! 'HEADER_DESTINATION', include end ENV.universal_binary if ARGV.include? "--universal" system "make" system "make install" end end