e2bec5d516
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
31 lines
590 B
Ruby
31 lines
590 B
Ruby
require 'formula'
|
|
|
|
class Vrpn < Formula
|
|
url 'git://git.cs.unc.edu/vrpn.git', :tag => 'version_07.28'
|
|
version '07.28'
|
|
homepage 'http://vrpn.org'
|
|
|
|
depends_on 'cmake' => :build
|
|
|
|
def options
|
|
[['--clients', 'Build client apps and tests.']]
|
|
end
|
|
|
|
def install
|
|
args = std_cmake_parameters.split
|
|
|
|
if ARGV.include? '--clients'
|
|
args << "-DVRPN_BUILD_CLIENTS:BOOL=ON"
|
|
else
|
|
args << "-DVRPN_BUILD_CLIENTS:BOOL=OFF"
|
|
end
|
|
|
|
args << ".."
|
|
|
|
Dir.mkdir "build"
|
|
Dir.chdir "build" do
|
|
system "cmake", *args
|
|
system "make install"
|
|
end
|
|
end
|
|
end
|