homebrew-core/Formula/vrpn.rb
Brett Koonce f3f88cb542 vrpn 07.30
Closes Homebrew/homebrew#13710.

Signed-off-by: Adam Vandenberg <flangy@gmail.com>
2012-07-29 09:31:22 -07:00

37 lines
837 B
Ruby

require 'formula'
class Vrpn < Formula
homepage 'http://vrpn.org'
url 'ftp://ftp.cs.unc.edu/pub/packages/GRIP/vrpn/vrpn_07_30.zip'
sha1 '474f45d524ba959e93630f19666fd03d8f337d90'
head 'git://git.cs.unc.edu/vrpn.git'
depends_on 'libusb' # for HID support
depends_on 'cmake' => :build
depends_on 'doxygen' if ARGV.include? '--docs'
def options
[
['--clients', 'Build client apps and tests.'],
['--docs', 'Build doxygen-based API documentation']
]
end
def install
args = std_cmake_args
if ARGV.include? '--clients'
args << "-DVRPN_BUILD_CLIENTS:BOOL=ON"
else
args << "-DVRPN_BUILD_CLIENTS:BOOL=OFF"
end
args << ".."
mkdir "build" do
system "cmake", *args
system "make doc" if ARGV.include? '--docs'
system "make install"
end
end
end